commit b9891d2f81509e180276ccda59f86ff05c039185 Author: meusinfirmary Date: Tue Apr 22 14:33:37 2025 +0700 Initial commit diff --git a/.editorconfig b/.editorconfig new file mode 100755 index 0000000..6537ca4 --- /dev/null +++ b/.editorconfig @@ -0,0 +1,15 @@ +root = true + +[*] +charset = utf-8 +end_of_line = lf +insert_final_newline = true +indent_style = space +indent_size = 4 +trim_trailing_whitespace = true + +[*.md] +trim_trailing_whitespace = false + +[*.{yml,yaml}] +indent_size = 2 diff --git a/.gitattributes b/.gitattributes new file mode 100755 index 0000000..967315d --- /dev/null +++ b/.gitattributes @@ -0,0 +1,5 @@ +* text=auto +*.css linguist-vendored +*.scss linguist-vendored +*.js linguist-vendored +CHANGELOG.md export-ignore diff --git a/.gitignore b/.gitignore new file mode 100755 index 0000000..2e06f01 --- /dev/null +++ b/.gitignore @@ -0,0 +1,15 @@ +/node_modules +/public/hot +/public/storage +storage/*.key +/vendor +/storage/fonts +.env +.env.* +.phpunit.result.cache +Homestead.json +Homestead.yaml +npm-debug.log +yarn-error.log +.vscode +.DS_Store diff --git a/.prettierrc b/.prettierrc new file mode 100644 index 0000000..0b1b2ec --- /dev/null +++ b/.prettierrc @@ -0,0 +1,31 @@ +{ + "plugins": ["@prettier/plugin-php"], + "overrides": [ + { + "files": ["*.php"], + "options": { + "trailingComma": "none", + "printWidth": 110, + "proseWrap": "always", + "singleQuote": false + } + }, + { + "files": ["*.blade.php"], + "options": { + "parser": "blade", + "tabWidth": 1, + "useTabs": true + } + }, + { + "files": ["*.js"], + "options": { + "trailingComma": "none", + "printWidth": 110, + "proseWrap": "always", + "tabWidth": 4 + } + } + ] +} diff --git a/.styleci.yml b/.styleci.yml new file mode 100755 index 0000000..1db61d9 --- /dev/null +++ b/.styleci.yml @@ -0,0 +1,13 @@ +php: + preset: laravel + disabled: + - unused_use + finder: + not-name: + - index.php + - server.php +js: + finder: + not-name: + - webpack.mix.js +css: true diff --git a/Dockerfile b/Dockerfile new file mode 100755 index 0000000..e300876 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,39 @@ +#stage 0 +FROM php:7.2-fpm-alpine + +WORKDIR /var/www/html/trucking + +# Install system dependencies +RUN apk --update add \ + curl \ + openssl \ + libpng-dev \ + libxml2-dev \ + libzip-dev \ + curl-dev \ + oniguruma-dev + +# Clear cache +RUN apk del gcc g++ +RUN rm -rf /var/cache/apk/* + +# Install PHP extensions +RUN docker-php-ext-install bcmath curl gd exif mbstring mysqli pdo pdo_mysql pcntl xml zip + +# Get latest Composer +COPY --from=composer:latest /usr/bin/composer /usr/bin/composer + +COPY ./ /var/www/html/trucking + +RUN composer install \ + --ignore-platform-reqs \ + --no-interaction \ + --no-plugins \ + --no-scripts \ + --prefer-dist + +RUN chmod -R 777 storage/logs/ && chmod -R 777 storage/framework/ + +RUN cp -R vendor /vendor + +# BELOM SUPPORT KIRIM EMAIL \ No newline at end of file diff --git a/README.md b/README.md new file mode 100755 index 0000000..e69de29 diff --git a/app/Console/Kernel.php b/app/Console/Kernel.php new file mode 100755 index 0000000..69914e9 --- /dev/null +++ b/app/Console/Kernel.php @@ -0,0 +1,41 @@ +command('inspire')->hourly(); + } + + /** + * Register the commands for the application. + * + * @return void + */ + protected function commands() + { + $this->load(__DIR__.'/Commands'); + + require base_path('routes/console.php'); + } +} diff --git a/app/Exceptions/Handler.php b/app/Exceptions/Handler.php new file mode 100755 index 0000000..5a53cd3 --- /dev/null +++ b/app/Exceptions/Handler.php @@ -0,0 +1,55 @@ + $val) { + if (is_array($val)) { + self::createPayload($val); + continue; + } + $string .= $key . '=' . $val . '&'; + } + + return $string; + } + + static function req_post($url, $headers, $payload) + { + $ch = curl_init(); + + $options = [ + CURLOPT_URL => $url, + CURLOPT_HEADER => false, + CURLOPT_HTTPHEADER => $headers, + CURLOPT_POST => 1, + CURLOPT_POSTFIELDS => $payload, + CURLOPT_FOLLOWLOCATION => true, + CURLOPT_RETURNTRANSFER => true, + // CURLOPT_FAILONERROR => true, + ]; + curl_setopt_array($ch, $options); + + $resp = curl_exec($ch); + + if (curl_errno($ch)) { + + $result = [ + 'type' => 'error', + 'message' => curl_error($ch) + ]; + return $result; + } else { + + $result = ['type' => 'success']; + try { + $data = json_decode($resp); + + if (json_last_error() == JSON_ERROR_NONE) { + $result['data'] = $data; + } else { + $result['data'] = $resp; + } + + return $result; + } catch (\Exception $e) { + $result['data'] = $resp; + return $result; + } + } + } + + static function req_get($url, $headers) + { + $ch = curl_init(); + + $options = [ + CURLOPT_URL => $url, + CURLOPT_HTTPHEADER => $headers, + CURLOPT_FOLLOWLOCATION => true, + CURLOPT_RETURNTRANSFER => true, + // CURLOPT_FAILONERROR => true, + ]; + curl_setopt_array($ch, $options); + + $resp = curl_exec($ch); + + if (curl_errno($ch)) { + $result = [ + 'type' => 'error', + 'message' => curl_error($ch) + ]; + return $result; + } else { + $result = ['type' => 'success']; + try { + $data = json_decode($resp); + + if (json_last_error() == JSON_ERROR_NONE) { + $result['data'] = $data; + } else { + $result['data'] = $resp; + } + + return $result; + } catch (\Exception $e) { + $result['data'] = $resp; + return $result; + } + } + } + + public static function listBloods() + { + return [ + [ + 'id' => 'A', + 'name' => 'A', + ], + [ + 'id' => 'A+', + 'name' => 'A+', + ], + [ + 'id' => 'B', + 'name' => 'B', + ], + [ + 'id' => 'B+', + 'name' => 'B+', + ], + [ + 'id' => 'O', + 'name' => 'O', + ], + [ + 'id' => 'O+', + 'name' => 'O+', + ], + [ + 'id' => 'AB', + 'name' => 'AB', + ], + [ + 'id' => 'AB+', + 'name' => 'AB+', + ], + ]; + } + + public static function countAge($date_ymd) + { + $then = date('Ymd', strtotime($date_ymd)); + $diff = date('Ymd') - $then; + return (int) substr($diff, 0, -4); + } + + public static function terbilang($nilai) + { + function penyebut($nilai) { + $nilai = abs($nilai); + $huruf = array("", "satu", "dua", "tiga", "empat", "lima", "enam", "tujuh", "delapan", "sembilan", "sepuluh", "sebelas"); + $temp = ""; + if ($nilai < 12) { + $temp = " ". $huruf[$nilai]; + } else if ($nilai <20) { + $temp = penyebut($nilai - 10). " belas"; + } else if ($nilai < 100) { + $temp = penyebut($nilai/10)." puluh". penyebut($nilai % 10); + } else if ($nilai < 200) { + $temp = " seratus" . penyebut($nilai - 100); + } else if ($nilai < 1000) { + $temp = penyebut($nilai/100) . " ratus" . penyebut($nilai % 100); + } else if ($nilai < 2000) { + $temp = " seribu" . penyebut($nilai - 1000); + } else if ($nilai < 1000000) { + $temp = penyebut($nilai/1000) . " ribu" . penyebut($nilai % 1000); + } else if ($nilai < 1000000000) { + $temp = penyebut($nilai/1000000) . " juta" . penyebut($nilai % 1000000); + } else if ($nilai < 1000000000000) { + $temp = penyebut($nilai/1000000000) . " milyar" . penyebut(fmod($nilai,1000000000)); + } else if ($nilai < 1000000000000000) { + $temp = penyebut($nilai/1000000000000) . " trilyun" . penyebut(fmod($nilai,1000000000000)); + } + return $temp; + } + + if ($nilai < 0) { + $hasil = "minus " . trim(penyebut($nilai)); + } else { + $hasil = trim(penyebut($nilai)); + } + return $hasil; + } + + public static function lastDigitYear() + { + // 2023 => 3 + return substr(date('Y'), -1); + } + + public static function weekNumOfYear() + { + // 27 jul 2022 => 30 + return date('W'); + } + + public static function dayOfWeek() + { + // monday => 01, sunday => 07 + return date('N'); + } + + public static function gnrtOrdCode($type) { + $ord_code = ''; + $ord_code .= $type; + $ord_code .= Helper::lastDigitYear() . Helper::weekNumOfYear() . Helper::dayOfWeek(); + // above before running number + $likeCode = \App\Models\Orders::getOrderLikeCode($ord_code); + // below after running number + if (count($likeCode) < 1 || $likeCode === false) { + $ord_code .= '001'; + } else { + if ($likeCode[0]->total < 1) { + $ord_code .= '001'; + } else { + $ord_code .= str_pad($likeCode[0]->total + 1, 3, '0', STR_PAD_LEFT); + } + } + return $ord_code; + } + + public static function gnrtInvcCode($ord_code) { + $invc_code = ''; + $type = substr($ord_code, 0, 1); + $invc_code .= Helper::lastDigitYear() . Helper::weekNumOfYear() . $type; + $first_invc_code = $invc_code; + // above before running number + $likeCode = \App\Models\OrdersInvoices::getLikeCode($invc_code); + // below after running number + if (count($likeCode) < 1 || $likeCode === false) { + $invc_code .= '001'; + } else { + if ($likeCode[0]->total < 1) { + $invc_code .= '001'; + } else { + $invc_code .= str_pad($likeCode[0]->total + 1, 3, '0', STR_PAD_LEFT); + $checkCode = OrdersInvoices::getByCode($invc_code); + if (count($checkCode) > 0) { + $invc_code = $first_invc_code; + $lastRN = OrdersInvoices::getLikeCodeLastRunningNumber($invc_code); + $newRN = (int)substr($lastRN[0]->code, -3); + $invc_code .= str_pad($newRN + 1, 3, '0', STR_PAD_LEFT); + } + } + } + return $invc_code; + } + + public static function viewBillFncIsEnableBtn($prev_termin, $curr_termin) + { + if ($curr_termin->termin_ddln_type === \App\Models\OrdersTermins::DDLN_TERMIN_TYPE_ORD_FINISH) { + if ($curr_termin->drop_chk_at === 0) { + // Menunggu Pengantaran Selesai + // return 0; + if ($prev_termin->termin_is_paid === \App\Models\OrdersTermins::IS_PAID_YES) { + // Termin sebelumnya selesai dan show btn invoice + return 1; + } else { + // Menunggu Pengantaran Selesai + return 0; + } + } else { + if ($curr_termin->termin_is_paid === \App\Models\OrdersTermins::IS_PAID_YES) { + // invoice close + return 4; + } else { + if ($prev_termin !== 0 && $prev_termin->termin_is_paid === \App\Models\OrdersTermins::IS_PAID_NO) { + // Termin sebelumnya belum terkonfirmasi selesai + return 3; + } + // Pengantaran Selesai pada and show btn invoice + return 2; + } + } + } else { + if ($curr_termin->termin_is_paid === \App\Models\OrdersTermins::IS_PAID_YES) { + // invoice close + return 4; + } else { + if ($prev_termin !== 0 && $prev_termin->termin_is_paid === \App\Models\OrdersTermins::IS_PAID_NO) { + // Termin sebelumnya belum terkonfirmasi selesai + return 3; + } + // show btn invoice + return 1; + } + } + } + + public static function changeIpToDomain($fullurl) + { + $replace = $fullurl; + if (!strpos($fullurl, env('ORI_IP')) === false) { + $replace = str_replace(env('ORI_IP'), env('ORI_DOMAIN'), $replace); + } + return $replace; + } +} diff --git a/app/Http/Controllers/AItemsController.php b/app/Http/Controllers/AItemsController.php new file mode 100755 index 0000000..c2345df --- /dev/null +++ b/app/Http/Controllers/AItemsController.php @@ -0,0 +1,289 @@ + UnitTypes::IS_ACTIVE, 'is_publish' => UnitTypes::IS_PUBLISH]); + $data = [ + 'unitTypes' => $unitTypes, + 'user' => $req->auth, + ]; + return view('menu_v2.Finance.adtItems', $data); + } + + /** + * API + */ + + public function api_list_a_items(Request $req) + { + try { + $now = time(); + $input = []; + $rulesInput = []; + + // validasi input + // $isValidInput = Validator::make($input, $rulesInput); + // if (!$isValidInput->passes()) { + // $apiResp = Responses::bad_input($isValidInput->messages()->first()); + // return new Response($apiResp, $apiResp['meta']['code']); + // } + $filter = []; + + if ($req->auth->role === Users::ROLE_ADMIN) { + $filter['crt_type'] = AItems::CRT_TYPE_ADMIN; + } else if ($req->auth->role === Users::ROLE_FINANCE) { + $filter['crt_type'] = AItems::CRT_TYPE_FINANCE; + } else { + $filter['crt_type'] = 99; + } + + $list = AItems::listAItems($filter); + foreach ($list as $key => $row) { + $list[$key]->DT_RowIndex = $key + 1; + $list[$key]->action = '-'; + } + + $apiResp = Responses::success('success list a_items'); + $apiResp['count'] = count($list); + $apiResp['data'] = $list; + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_show_a_items(Request $req, $id) + { + try { + $now = time(); + + $input = [ + 'id' => $id, + ]; + $rulesInput = [ + 'id' => 'required|integer|not_in:0', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $a_item = AItems::showAItemsById($id); + if (count($a_item) < 1) { + $apiResp = Responses::not_found('a_item not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + $apiResp = Responses::success('success get detail a_item'); + $apiResp['data'] = $a_item[0]; + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_add_a_items(Request $req) + { + try { + $now = time(); + + $input = [ + 'name' => $req->name, + 'type' => $req->type, + 'price' => $req->price, + 'status' => $req->status, + 'is_adm_price' => $req->is_adm_price, + ]; + $rulesInput = [ + 'name' => 'required|string', + 'type' => 'required|integer|not_in:0', + 'price' => 'required|numeric', + 'status' => 'required|integer|min:0', + 'is_adm_price' => 'required|numeric|min:0', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $uniqName = AItems::getByName($req->name); + if (count($uniqName) > 0) { + $apiResp = Responses::bad_request('nama additional item sudah terdata'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + if ($req->auth->role === Users::ROLE_ADMIN) { + $crt_type = AItems::CRT_TYPE_ADMIN; + } else if ($req->auth->role === Users::ROLE_FINANCE) { + $crt_type = AItems::CRT_TYPE_FINANCE; + } else { + $crt_type = 99; + } + + DB::beginTransaction(); + + $insAItems = [ + 'name' => $req->name, + 'type' => $req->type, + 'price' => $req->price, + 'is_active' => $req->status, + 'is_adm_price' => $req->is_adm_price, + 'crt' => $now, + 'crt_by' => $req->auth->uid, + 'crt_type' => $crt_type, + 'updt' => $now, + 'updt_by' => $req->auth->uid, + ]; + $id = AItems::add($insAItems); + + $apiResp = Responses::created('success add new additional item'); + + DB::commit(); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_updt_a_items(Request $req, $id) + { + try { + $now = time(); + + $input = [ + 'id' => $id, + 'name' => $req->name, + 'type' => $req->type, + 'price' => $req->price, + 'status' => $req->status, + 'is_adm_price' => $req->is_adm_price, + ]; + $rulesInput = [ + 'id' => 'required|integer|not_in:0', + 'name' => 'required|string', + 'type' => 'required|integer|not_in:0', + 'price' => 'required|numeric', + 'status' => 'required|integer|min:0', + 'is_adm_price' => 'required|numeric|min:0', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $a_item = AItems::showAItemsById($id); + if (count($a_item) < 1) { + $apiResp = Responses::not_found('additional item not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + $uniqName = AItems::getByName($req->name); + if (count($uniqName) > 0) { + $notSameUser = 1; + foreach ($uniqName as $key => $row) { + if ($row->id == $id) { + $notSameUser = 0; + } + } + if ($notSameUser) { + $apiResp = Responses::bad_request('nama additional item sudah terdata'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + DB::beginTransaction(); + + $updtAItems = [ + 'name' => $req->name, + 'type' => $req->type, + 'price' => $req->price, + 'is_active' => $req->status, + 'is_adm_price' => $req->is_adm_price, + 'updt' => $now, + 'updt_by' => $req->auth->uid, + ]; + AItems::updt($id, $updtAItems); + + $apiResp = Responses::created('success update additional item'); + + DB::commit(); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_del_a_items(Request $req, $id) + { + try { + $now = time(); + + $input = [ + 'id' => $id, + ]; + $rulesInput = [ + 'id' => 'required|integer|not_in:0', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $a_item = AItems::showAItemsById($id); + if (count($a_item) < 1) { + $apiResp = Responses::not_found('additional item not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + DB::beginTransaction(); + + AItems::updt($id, [ + 'dlt' => $now, + 'dlt_by' => $req->auth->uid, + ]); + + DB::commit(); + + $apiResp = Responses::success('success delete additional item'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } +} diff --git a/app/Http/Controllers/Api/AuthController.php b/app/Http/Controllers/Api/AuthController.php new file mode 100644 index 0000000..63e8a5d --- /dev/null +++ b/app/Http/Controllers/Api/AuthController.php @@ -0,0 +1,51 @@ +all()); + $response = ["success" => false]; + try { + $data = [ + "email" => $request->email, + "password" => $request->password, + ]; + + Auth::attempt($data); + + if (Auth::check() && Auth::user()->status != 1) { + Auth::logout(); + $response = [ + "success" => false, + "code" => 400, + "msg" => + "Your account is inactive, please contact the Administrator.", + ]; + } + + $response = [ + "code" => 200, + "success" => true, + "data" => [ + "id" => Auth::user()->id, + ], + ]; + } catch (\Throwable $th) { + $response["error"] = $th->getMessage(); + } + + return $response; + } +} diff --git a/app/Http/Controllers/Auth/ConfirmPasswordController.php b/app/Http/Controllers/Auth/ConfirmPasswordController.php new file mode 100755 index 0000000..138c1f0 --- /dev/null +++ b/app/Http/Controllers/Auth/ConfirmPasswordController.php @@ -0,0 +1,40 @@ +middleware('auth'); + } +} diff --git a/app/Http/Controllers/Auth/ForgotPasswordController.php b/app/Http/Controllers/Auth/ForgotPasswordController.php new file mode 100755 index 0000000..465c39c --- /dev/null +++ b/app/Http/Controllers/Auth/ForgotPasswordController.php @@ -0,0 +1,22 @@ +middleware("guest")->except("logout"); + } + + public function username() + { + return "email"; + } + + public function login(Request $req) + { + $this->validateLogin($req); + + // If the class is using the ThrottlesLogins trait, we can automatically throttle + // the login attempts for this application. We'll key this by the username and + // the IP address of the client making these requests into this application. + if ( + method_exists($this, "hasTooManyLoginAttempts") && + $this->hasTooManyLoginAttempts($req) + ) { + $this->fireLockoutEvent($req); + + return $this->sendLockoutResponse($req); + } + + if ($this->guard()->validate($this->credentials($req))) { + $user = $this->guard()->getLastAttempted(); + if ($user->dlt != null) { + $this->incrementLoginAttempts($req); + throw ValidationException::withMessages([ + $this->username() => [trans("auth.failed")], + ]); + } + if ($user->status != Users::STATUS_ACTIVE) { + // Increment the failed login attempts and redirect back to the + // login form with an error message. + $this->incrementLoginAttempts($req); + // return redirect() + // ->back() + // ->withInput($req->only($this->username(), 'remember')) + // ->withErrors(['active' => 'You must be active to login.']); + throw ValidationException::withMessages([ + $this->username() => __( + "Your account not active, please contact admin." + ), + ]); + } + + if ($this->attemptLogin($req)) { + return $this->sendLoginResponse($req); + } + } + + // If the login attempt was unsuccessful we will increment the number of attempts + // to login and redirect the user back to the login form. Of course, when this + // user surpasses their maximum number of attempts they will get locked out. + $this->incrementLoginAttempts($req); + + return $this->sendFailedLoginResponse($req); + } + + protected function validateLogin(Request $req) + { + $this->validate($req, [ + $this->username() => "required|string|email", + "password" => "required|string", + ]); + } + + protected function sendLoginResponse(Request $req) + { + $req->session()->regenerate(); + + $this->clearLoginAttempts($req); + + if ($response = $this->authenticated($req, $this->guard()->user())) { + return $response; + } + + // return $req->wantsJson() + // ? new JsonResponse([], 204) + // : redirect()->intended($this->redirectPath()); + // return $req->wantsJson() + // ? new JsonResponse([], 204) + // : redirect(route('view_dashboard')); + + if ($req->wantsJson()) { + return new JsonResponse([], 204); + } else { + $user = Auth::user(); + if ($user->role == Users::ROLE_ADMIN) { + return redirect(route("view_dashboard")); + } elseif ($user->role == Users::ROLE_VENDOR) { + return redirect(route("view_dashboard")); + } elseif ($user->role == Users::ROLE_CHECKER) { + return redirect(route("view_user_checker")); + } elseif ($user->role == Users::ROLE_CLIENT_ADMIN) { + return redirect( + route("view_user_client_transaction_add") . "?rdl=1" + ); + } elseif ($user->role == Users::ROLE_SPECIAL_TRACKING) { + return redirect(route("view_dashboard")); + } elseif ($user->role == Users::ROLE_FINANCE) { + return redirect(route("view_keuangan_payment")); + } else { + $this->guard()->logout(); + $req->session()->invalidate(); + $req->session()->regenerateToken(); + // return redirect(route('login')); + return redirect(route("login")); + } + } + } + + public function logout(Request $req) + { + $user = Auth::user(); + if ($user->role == Users::ROLE_ADMIN) { + $this->guard()->logout(); + $req->session()->invalidate(); + $req->session()->regenerateToken(); + if ($response = $this->loggedOut($req)) { + return $response; + } + return $req->wantsJson() + ? new JsonResponse([], 204) + : redirect(route("login_admin")); + } elseif ($user->role == Users::ROLE_FINANCE) { + $this->guard()->logout(); + $req->session()->invalidate(); + $req->session()->regenerateToken(); + if ($response = $this->loggedOut($req)) { + return $response; + } + return $req->wantsJson() + ? new JsonResponse([], 204) + : redirect(route("login_admin")); + } elseif ($user->role == Users::ROLE_VENDOR) { + $this->guard()->logout(); + $req->session()->invalidate(); + $req->session()->regenerateToken(); + if ($response = $this->loggedOut($req)) { + return $response; + } + return $req->wantsJson() + ? new JsonResponse([], 204) + : redirect(route("login_vendor")); + } elseif ($user->role == Users::ROLE_CHECKER) { + $this->guard()->logout(); + $req->session()->invalidate(); + $req->session()->regenerateToken(); + if ($response = $this->loggedOut($req)) { + return $response; + } + return $req->wantsJson() + ? new JsonResponse([], 204) + : redirect(route("login_checker")); + } elseif ($user->role == Users::ROLE_CLIENT_ADMIN) { + $this->guard()->logout(); + $req->session()->invalidate(); + $req->session()->regenerateToken(); + if ($response = $this->loggedOut($req)) { + return $response; + } + return $req->wantsJson() + ? new JsonResponse([], 204) + : redirect(route("login_client")); + } elseif ($user->role == Users::ROLE_SPECIAL_TRACKING) { + $this->guard()->logout(); + $req->session()->invalidate(); + $req->session()->regenerateToken(); + if ($response = $this->loggedOut($req)) { + return $response; + } + return $req->wantsJson() + ? new JsonResponse([], 204) + : redirect(route("login_admin")); + } + } +} diff --git a/app/Http/Controllers/Auth/RegisterController.php b/app/Http/Controllers/Auth/RegisterController.php new file mode 100755 index 0000000..c6a6de6 --- /dev/null +++ b/app/Http/Controllers/Auth/RegisterController.php @@ -0,0 +1,73 @@ +middleware('guest'); + } + + /** + * Get a validator for an incoming registration request. + * + * @param array $data + * @return \Illuminate\Contracts\Validation\Validator + */ + protected function validator(array $data) + { + return Validator::make($data, [ + 'name' => ['required', 'string', 'max:255'], + 'email' => ['required', 'string', 'email', 'max:255', 'unique:users'], + 'password' => ['required', 'string', 'min:8', 'confirmed'], + ]); + } + + /** + * Create a new user instance after a valid registration. + * + * @param array $data + * @return \App\User + */ + protected function create(array $data) + { + return User::create([ + 'name' => $data['name'], + 'email' => $data['email'], + 'password' => Hash::make($data['password']), + ]); + } +} diff --git a/app/Http/Controllers/Auth/ResetPasswordController.php b/app/Http/Controllers/Auth/ResetPasswordController.php new file mode 100755 index 0000000..b1726a3 --- /dev/null +++ b/app/Http/Controllers/Auth/ResetPasswordController.php @@ -0,0 +1,30 @@ +middleware('auth'); + $this->middleware('signed')->only('verify'); + $this->middleware('throttle:6,1')->only('verify', 'resend'); + } +} diff --git a/app/Http/Controllers/AuthController.php b/app/Http/Controllers/AuthController.php new file mode 100755 index 0000000..4c61c6a --- /dev/null +++ b/app/Http/Controllers/AuthController.php @@ -0,0 +1,81 @@ + $req->password, + ]; + $rulesInput = [ + 'password' => 'required|string', + ]; + + if ($req->email) { + $input['email'] = $req->email; + $rulesInput['email'] = 'required|email'; + } + if ($req->phone) { + $input['phone'] = $req->phone; + $rulesInput['phone'] = 'required|integer'; + } + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $getUser = Users::getUserByEmail($req->email); + if (count($getUser) < 1) { + $getUser = Users::getUserByPhone($req->phone); + if (count($getUser) < 1) { + $apiResp = Responses::not_found('akun tidak ditemukan'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + $apiResp = Responses::success('sukses login'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } +} diff --git a/app/Http/Controllers/ChecklistController.php b/app/Http/Controllers/ChecklistController.php new file mode 100644 index 0000000..0ea433e --- /dev/null +++ b/app/Http/Controllers/ChecklistController.php @@ -0,0 +1,57 @@ +leftJoin("t_clients as tc", "tc.id", "tcc.client_id") + ->leftJoin("t_users as tu", "tu.id", "tcc.crt_by") + ->select("tcc.*", "tu.first_name as crt_name", "tc.c_name as company_name") + ->whereNull("tcc.dlt") + ->where("tcc.client_id", Auth::user()->client_id); + + // dd($table); + + return DataTables::of($table) + ->addIndexColumn() + ->make(); + } + public function create() + { + return view("menu_v1._addChecklist"); + } + + public function store(Request $request) + { + $now = time(); + $_dtPost = [ + "name" => $request->name, + "client_id" => Auth::user()->client_id, + "desc" => $request->desc, + "status" => $request->status, + "crt" => $now, + "updt" => $now, + "crt_by" => Auth::user()->id, + "updt_by" => Auth::user()->id, + ]; + + $dtPost = DB::table("t_conf_checklists")->insert($_dtPost); + if ($dtPost) { + return redirect("checklist"); + } + } +} diff --git a/app/Http/Controllers/ClientController.php b/app/Http/Controllers/ClientController.php new file mode 100755 index 0000000..4619582 --- /dev/null +++ b/app/Http/Controllers/ClientController.php @@ -0,0 +1,591 @@ + Clients::select2DiscountTypes(), + ]; + return view("menu_v1.clients", $data); + } + + /** + * API + */ + + public function api_list_clients(Request $req) + { + try { + $now = time(); + $input = []; + $rulesInput = []; + + // validasi input + // $isValidInput = Validator::make($input, $rulesInput); + // if (!$isValidInput->passes()) { + // $apiResp = Responses::bad_input($isValidInput->messages()->first()); + // return new Response($apiResp, $apiResp['meta']['code']); + // } + + $filter = []; + if ($req->cptid) { + $filter["company"] = $req->cptid; + } + $list = Clients::listClients($filter); + foreach ($list as $key => $row) { + $list[$key]->DT_RowIndex = $key + 1; + // $list[$key]->count_trx = 0; + } + + $apiResp = Responses::success("success list clients"); + $apiResp["data"] = $list; + $apiResp["count"] = count($list); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_show_client(Request $req, $cid) + { + try { + $now = time(); + + $input = [ + "cid" => $cid, + ]; + $rulesInput = [ + "cid" => "required|integer|not_in:0", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $client = Clients::showClientById($cid); + if (count($client) < 1) { + $apiResp = Responses::not_found("client not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + if ($client[0]->user_id) { + $client[0]->c_credentials = Clients::CCREDENTIALS_CREATE; + } else { + $client[0]->c_credentials = Clients::CCREDENTIALS_NOT; + } + + $apiResp = Responses::success("success get detail client"); + $apiResp["data"] = $client[0]; + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_add_client(Request $req) + { + //dd($req->all()); + $url_clogo = ""; + + try { + $now = time(); + + $input = [ + "client_logo" => $req->clogo_base64, + "client_name" => $req->cname, + "client_office_address" => $req->caddress_office, + "client_phone" => $req->cphone, + "client_email" => $req->cmail, + "pic_name" => $req->picname, + "pic_phone" => $req->picphone, + "pic_email" => $req->picmail, + // "disc_type" => $req->disc_type, + // "disc_amount" => $req->disc_amount, + "client_status" => $req->cstatus, + "is_create_login_credentials" => $req->ccredentials, + ]; + $rulesInput = [ + "client_logo" => "required|string", + "client_name" => "required|string|max:255", + "client_office_address" => "required|string|min:45|max:300", + "client_phone" => "required|integer|not_in:0", + "client_email" => "required|string|email", + "pic_name" => "required|string|max:255", + "pic_phone" => "required|integer|not_in:0", + "pic_email" => "required|string|email", + // "disc_type" => "required|numeric|min:0", + // "disc_amount" => "required|numeric|min:0", + "client_status" => "required|numeric", + "is_create_login_credentials" => "required|numeric", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $uniqCPhone = Clients::getClientByPhone($req->cphone); + if (count($uniqCPhone) > 0) { + $apiResp = Responses::bad_request("client phone has been used"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + $uniqCMail = Clients::getClientByEmail($req->cmail); + if (count($uniqCMail) > 0) { + $apiResp = Responses::bad_request("client email has been used"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $uniqPicPhone = Clients::getPicByPhone($req->picphone); + if (count($uniqPicPhone) > 0) { + $apiResp = Responses::bad_request("pic phone has been used"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + $uniqPicMail = Clients::getPicByEmail($req->picmail); + if (count($uniqPicMail) > 0) { + $apiResp = Responses::bad_request("pic email has been used"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $uniqUserPhone = Users::getUserByPhone($req->cphone); + if (count($uniqUserPhone) > 0) { + $apiResp = Responses::bad_request("client phone has been used"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + $uniqUserMail = Users::getUserByEmail($req->cmail); + if (count($uniqUserMail) > 0) { + $apiResp = Responses::bad_request("client email has been used"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + if ($req->disc_type == Clients::DISC_TYPE_PERCENT && $req->disc_amount > 100) { + $apiResp = Responses::bad_request("maximum percent is 100%"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + DB::beginTransaction(); + + $insClient = [ + "c_name" => $req->cname, + "c_addr_office" => $req->caddress_office, + "c_phone" => $req->cphone, + "c_phone_code" => Clients::DEFAULT_PHONE_CODE, + "c_mail" => $req->cmail, + "c_logo" => $url_clogo, + "pic_name" => $req->picname, + "pic_phone" => $req->picphone, + "pic_phone_code" => Clients::DEFAULT_PHONE_CODE, + "pic_mail" => $req->picmail, + "disc_type" => 0, + "disc_amount" => 0, + "c_status" => $req->cstatus, + "crt" => $now, + "crt_by" => $req->auth->uid, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]; + $clientId = Clients::addClient($insClient); + + $url_clogo = "clients/$clientId/logo_$now.jpeg"; + if (!Storage::disk("public")->put($url_clogo, base64_decode($req->clogo_base64))) { + DB::rollBack(); + $apiResp = Responses::bad_request("fail upload client logo"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + $updtClient = [ + "c_logo" => $url_clogo, + ]; + Clients::updateClient($clientId, $updtClient); + + if ($req->ccredentials == Clients::CCREDENTIALS_CREATE) { + $status = Users::STATUS_ACTIVE; + if ($req->cstatus == Clients::CSTTS_INACTIVE) { + $status = Users::STATUS_NOT_ACTIVE; + } + $insAccount = [ + "client_id" => $clientId, + "client_group_id" => $clientId, + "first_name" => $req->cname, + "last_name" => null, + "email" => $req->cmail, + "phone" => $req->cphone, + "phone_code" => Users::DEFAULT_PHONE_CODE, + "fulladdress" => $req->caddress_office, + "password" => Hash::make($req->cphone), + "role" => Users::ROLE_VENDOR, + "status" => $status, + "crt" => $now, + "crt_by" => $req->auth->uid, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]; + Users::addUser($insAccount); + } + + $apiResp = Responses::created("success add new client"); + + DB::commit(); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + Storage::disk("public")->delete($url_clogo); + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_edit_client(Request $req, $cid) + { + $url_clogo = ""; + + try { + $now = time(); + + $input = [ + "cid" => $cid, + "client_logo" => $req->clogo_base64, + "client_name" => $req->cname, + "client_office_address" => $req->caddress_office, + "client_phone" => $req->cphone, + "client_email" => $req->cmail, + "pic_name" => $req->picname, + "pic_phone" => $req->picphone, + "pic_email" => $req->picmail, + "disc_type" => $req->disc_type, + "disc_amount" => $req->disc_amount, + "client_status" => $req->cstatus, + "is_create_login_credentials" => $req->ccredentials, + ]; + $rulesInput = [ + "cid" => "required|integer|not_in:0", + "client_logo" => "required|string", + "client_name" => "required|string|max:255", + "client_office_address" => "required|string|min:45|max:300", + "client_phone" => "required|integer|not_in:0", + "client_email" => "required|string|email", + "pic_name" => "required|string|max:255", + "pic_phone" => "required|integer|not_in:0", + "pic_email" => "required|string|email", + // "disc_type" => "required|numeric|min:0", + // "disc_amount" => "required|numeric|min:0", + "client_status" => "required|numeric", + "is_create_login_credentials" => "required|numeric", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $client = Clients::showClientById($cid); + if (count($client) < 1) { + $apiResp = Responses::not_found("client not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $uniqCPhone = Clients::getClientByPhone($req->cphone); + if (count($uniqCPhone) > 0) { + $notSameUser = 1; + foreach ($uniqCPhone as $key => $row) { + if ($row->id == $cid) { + $notSameUser = 0; + } + } + if ($notSameUser) { + $apiResp = Responses::bad_request("client phone has been used"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + $uniqCMail = Clients::getClientByEmail($req->cmail); + if (count($uniqCMail) > 0) { + $notSameUser = 1; + foreach ($uniqCMail as $key => $row) { + if ($row->id == $cid) { + $notSameUser = 0; + } + } + if ($notSameUser) { + $apiResp = Responses::bad_request("client email has been used"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + $uniqPicPhone = Clients::getPicByPhone($req->picphone); + if (count($uniqPicPhone) > 0) { + $notSameUser = 1; + foreach ($uniqPicPhone as $key => $row) { + if ($row->id == $cid) { + $notSameUser = 0; + } + } + if ($notSameUser) { + $apiResp = Responses::bad_request("pic phone has been used"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + $uniqPicMail = Clients::getPicByEmail($req->picmail); + if (count($uniqPicMail) > 0) { + $notSameUser = 1; + foreach ($uniqPicMail as $key => $row) { + if ($row->id == $cid) { + $notSameUser = 0; + } + } + if ($notSameUser) { + $apiResp = Responses::bad_request("pic email has been used"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + $uniqUserPhone = Users::getUserByPhone($req->cphone); + if (count($uniqUserPhone) > 0) { + $notSameUser = 1; + foreach ($uniqUserPhone as $key => $row) { + if ($row->client_group_id == $cid) { + $notSameUser = 0; + } + } + if ($notSameUser) { + $apiResp = Responses::bad_request("client phone has been used"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + $uniqUserMail = Users::getUserByEmail($req->cmail); + if (count($uniqUserMail) > 0) { + $notSameUser = 1; + foreach ($uniqUserMail as $key => $row) { + if ($row->client_group_id == $cid) { + $notSameUser = 0; + } + } + if ($notSameUser) { + $apiResp = Responses::bad_request("client email has been used"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + if ($req->disc_type == Clients::DISC_TYPE_PERCENT && $req->disc_amount > 100) { + $apiResp = Responses::bad_request("maximum percent is 100%"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $user = Users::getUserByClientId($cid); + + DB::beginTransaction(); + + $url_clogo = $client[0]->c_logo; + if ($req->clogo_base64 && $req->clogo_base64 != "noupdate") { + $url_clogo = "clients/$cid/logo_$now.jpeg"; + if (!Storage::disk("public")->put($url_clogo, base64_decode($req->clogo_base64))) { + DB::rollBack(); + $apiResp = Responses::bad_request("fail upload client logo"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + Storage::disk("public")->delete($client[0]->c_logo); + } + + $updtClient = [ + "c_name" => $req->cname, + "c_addr_office" => $req->caddress_office, + "c_phone" => $req->cphone, + "c_phone_code" => Clients::DEFAULT_PHONE_CODE, + "c_mail" => $req->cmail, + "c_logo" => $url_clogo, + "pic_name" => $req->picname, + "pic_phone" => $req->picphone, + "pic_phone_code" => Clients::DEFAULT_PHONE_CODE, + "pic_mail" => $req->picmail, + "disc_type" => $req->disc_type, + "disc_amount" => $req->disc_amount, + "c_status" => $req->cstatus, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]; + Clients::updateClient($cid, $updtClient); + + if ($req->ccredentials == Clients::CCREDENTIALS_CREATE && count($user) < 1) { + $status = Users::STATUS_ACTIVE; + if ($req->cstatus == Clients::CSTTS_INACTIVE) { + $status = Users::STATUS_NOT_ACTIVE; + } + $insAccount = [ + "client_id" => $cid, + "client_group_id" => $cid, + "first_name" => $req->cname, + "last_name" => null, + "email" => $req->cmail, + "phone" => $req->cphone, + "phone_code" => Users::DEFAULT_PHONE_CODE, + "fulladdress" => $req->caddress_office, + "password" => Hash::make($req->cphone), + "role" => Users::ROLE_CLIENT_ADMIN, + "status" => $status, + "crt" => $now, + "crt_by" => $req->auth->uid, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]; + Users::addUser($insAccount); + } + + $status = Users::STATUS_ACTIVE; + if ($req->cstatus == Clients::CSTTS_INACTIVE) { + $status = Users::STATUS_NOT_ACTIVE; + } + + // update the client credentials only + if (count($user) > 0) { + $updtAccount = [ + "status" => $status, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]; + Users::UpdateUser($user[0]->id, $updtAccount); + } + + // update user group by this client + $updtGroupAccount = [ + "status" => $status, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]; + Users::updateUsersByGroupClientId($client[0]->id, $updtGroupAccount); + + DB::commit(); + + $apiResp = Responses::success("success update client"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + Storage::disk("public")->delete($url_clogo); + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_del_client(Request $req, $cid) + { + try { + $now = time(); + + $input = [ + "cid" => $cid, + ]; + $rulesInput = [ + "cid" => "required|integer|not_in:0", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $client = Clients::showClientById($cid); + if (count($client) < 1) { + $apiResp = Responses::not_found("client not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $user = Users::getUserByClientId($cid); + + DB::beginTransaction(); + + Clients::updateClient($cid, [ + "dlt" => $now, + "dlt_by" => $req->auth->uid, + ]); + + // delete the client credentials only + if (count($user) > 0) { + // Users::updateUser($user[0]->id, [ + // 'dlt' => $now, + // 'dlt_by' => $req->auth->uid, + // ]); + } + + // delete user group by this client + Users::updateUsersByGroupClientId($client[0]->id, [ + "dlt" => $now, + "dlt_by" => $req->auth->uid, + ]); + + DB::commit(); + + $apiResp = Responses::success("success delete client"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_universal_show_client_pt(Request $req) + { + try { + $now = time(); + + $input = [ + "cptid" => $req->cptid, + ]; + $rulesInput = [ + "cptid" => "required|integer|not_in:0", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $client = Clients::showClientById($req->cptid); + if (count($client) < 1) { + $apiResp = Responses::not_found("client not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + if ($client[0]->user_id) { + $client[0]->c_credentials = Clients::CCREDENTIALS_CREATE; + } else { + $client[0]->c_credentials = Clients::CCREDENTIALS_NOT; + } + + $apiResp = Responses::success("success get detail client"); + $apiResp["data"] = $client[0]; + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } +} diff --git a/app/Http/Controllers/ConfRateController.php b/app/Http/Controllers/ConfRateController.php new file mode 100755 index 0000000..36cdb2d --- /dev/null +++ b/app/Http/Controllers/ConfRateController.php @@ -0,0 +1,387 @@ + ConfRates::getLanesActive(), + 'provs' => Region::listProv(), + 'vendors' => Users::getUsersActiveByRole(Users::ROLE_VENDOR), + 'truck_types' => ConfTruckTypes::listTruckTypes(ConfTruckTypes::IS_ACTIVE), + ]; + + return view('menu_v1.configs.pricing', $data); + } + + + /** + * API + */ + + public function api_list_rates(Request $req) + { + try { + $now = time(); + $input = []; + $rulesInput = []; + + // validasi input + // $isValidInput = Validator::make($input, $rulesInput); + // if (!$isValidInput->passes()) { + // $apiResp = Responses::bad_input($isValidInput->messages()->first()); + // return new Response($apiResp, $apiResp['meta']['code']); + // } + + $list = ConfRates::listRates(); + foreach ($list as $key => $row) { + $list[$key]->DT_RowIndex = $key + 1; + $list[$key]->action = '-'; + } + + $apiResp = Responses::success('success list rates'); + $apiResp['count'] = count($list); + $apiResp['data'] = $list; + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_show_rate(Request $req, $rid) + { + try { + $now = time(); + + $input = [ + 'rid' => $rid, + ]; + $rulesInput = [ + 'rid' => 'required|integer|not_in:0', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $rate = ConfRates::showRateById($rid); + if (count($rate) < 1) { + $apiResp = Responses::not_found('rate not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + $apiResp = Responses::success('success get detail rate'); + $apiResp['data'] = $rate[0]; + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_add_rate(Request $req) + { + try { + $now = time(); + + $input = [ + 'origin_prov' => $req->origin_prov, + // 'origin_city' => $req->origin_city, + 'via' => $req->via, + 'dest_prov' => $req->dest_prov, + 'dest_city' => $req->dest_city, + 'dest_district' => $req->dest_district, + 'vendor' => $req->vendor_id, + 'vehicle_type' => $req->vhc_type_id, + 'fast_time' => $req->fast_time, + 'long_time' => $req->long_time, + 'sell_kg' => $req->sell_kg, + 'buy_kg' => $req->buy_kg, + 'margin_kg' => $req->margin_kg, + 'percent_kg' => $req->percent_kg, + 'sell_cbm' => $req->sell_cbm, + 'buy_cbm' => $req->buy_cbm, + 'margin_cbm' => $req->margin_cbm, + 'percent_cbm' => $req->percent_cbm, + 'sell_ftl' => $req->sell_ftl, + 'buy_ftl' => $req->buy_ftl, + 'margin_ftl' => $req->margin_ftl, + 'percent_ftl' => $req->percent_ftl, + 'status' => $req->status, + ]; + $rulesInput = [ + 'origin_prov' => 'required|numeric|min:0', + // 'origin_city' => 'required|numeric|min:0', + 'via' => 'required|numeric|min:0', + 'dest_prov' => 'required|numeric|min:0', + 'dest_city' => 'required|numeric|min:0', + 'dest_district' => 'nullable|numeric|min:0', + 'vendor' => 'required|integer|not_in:0', + 'vehicle_type' => 'required|integer|not_in:0', + 'fast_time' => 'required|numeric|min:0', + 'long_time' => 'required|numeric|min:0', + 'sell_kg' => 'required|numeric|min:0', + 'buy_kg' => 'required|numeric|min:0', + 'margin_kg' => 'required|numeric|min:0', + 'percent_kg' => 'required|numeric|min:0', + 'sell_cbm' => 'required|numeric|min:0', + 'buy_cbm' => 'required|numeric|min:0', + 'margin_cbm' => 'required|numeric|min:0', + 'percent_cbm' => 'required|numeric|min:0', + 'sell_ftl' => 'required|numeric|min:0', + 'buy_ftl' => 'required|numeric|min:0', + 'margin_ftl' => 'required|numeric|min:0', + 'percent_ftl' => 'required|numeric|min:0', + 'status' => 'required|numeric|min:0', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $nanoid = new Nanoid(); + $code = $nanoid->formattedId('123456789', 6); + + $uniqCode = ConfRates::getRateByCode($code); + if (count($uniqCode) > 0) { + $apiResp = Responses::bad_request('code has been used, try again'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + DB::beginTransaction(); + + $insRate = [ + 'code' => $code, + 'origin_prov' => $req->origin_prov, + // 'origin_city' => $req->origin_city, + 'lane' => $req->via, + 'dest_prov' => $req->dest_prov, + 'dest_city' => $req->dest_city, + 'vdr_id' => $req->vendor_id, + 'vhc_type' => $req->vhc_type_id, + 'fast_time' => $req->fast_time, + 'long_time' => $req->long_time, + 'unit_time' => ConfRates::UNIT_DAY, + 'sell_kg' => $req->sell_kg, + 'buy_kg' => $req->buy_kg, + 'margin_kg' => $req->margin_kg, + 'percent_kg' => $req->percent_kg, + 'sell_cbm' => $req->sell_cbm, + 'buy_cbm' => $req->buy_cbm, + 'margin_cbm' => $req->margin_cbm, + 'percent_cbm' => $req->percent_cbm, + 'sell_ftl' => $req->sell_ftl, + 'buy_ftl' => $req->buy_ftl, + 'margin_ftl' => $req->margin_ftl, + 'percent_ftl' => $req->percent_ftl, + 'is_active' => $req->status, + 'crt' => $now, + 'crt_by' => $req->auth->uid, + 'updt' => $now, + 'updt_by' => $req->auth->uid, + ]; + if ($req->dest_district) { + $insRate['dest_district'] = $req->dest_district; + } + $rid = ConfRates::addRate($insRate); + + $apiResp = Responses::created('success add new rate'); + + DB::commit(); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_edit_rate(Request $req, $rid) + { + try { + $now = time(); + + $input = [ + 'rid' => $rid, + 'origin_prov' => $req->origin_prov, + // 'origin_city' => $req->origin_city, + 'via' => $req->via, + 'dest_prov' => $req->dest_prov, + 'dest_city' => $req->dest_city, + 'dest_district' => $req->dest_district, + 'vendor' => $req->vendor_id, + 'vehicle_type' => $req->vhc_type_id, + 'fast_time' => $req->fast_time, + 'long_time' => $req->long_time, + 'sell_kg' => $req->sell_kg, + 'buy_kg' => $req->buy_kg, + 'margin_kg' => $req->margin_kg, + 'percent_kg' => $req->percent_kg, + 'sell_cbm' => $req->sell_cbm, + 'buy_cbm' => $req->buy_cbm, + 'margin_cbm' => $req->margin_cbm, + 'percent_cbm' => $req->percent_cbm, + 'sell_ftl' => $req->sell_ftl, + 'buy_ftl' => $req->buy_ftl, + 'margin_ftl' => $req->margin_ftl, + 'percent_ftl' => $req->percent_ftl, + 'status' => $req->status, + ]; + $rulesInput = [ + 'rid' => 'required|integer|not_in:0', + 'origin_prov' => 'required|numeric|min:0', + // 'origin_city' => 'required|numeric|min:0', + 'via' => 'required|numeric|min:0', + 'dest_prov' => 'required|numeric|min:0', + 'dest_city' => 'required|numeric|min:0', + 'dest_district' => 'nullable|numeric|min:0', + 'vendor' => 'required|integer|not_in:0', + 'vehicle_type' => 'required|integer|not_in:0', + 'fast_time' => 'required|numeric|min:0', + 'long_time' => 'required|numeric|min:0', + 'sell_kg' => 'required|numeric|min:0', + 'buy_kg' => 'required|numeric|min:0', + 'margin_kg' => 'required|numeric|min:0', + 'percent_kg' => 'required|numeric|min:0', + 'sell_cbm' => 'required|numeric|min:0', + 'buy_cbm' => 'required|numeric|min:0', + 'margin_cbm' => 'required|numeric|min:0', + 'percent_cbm' => 'required|numeric|min:0', + 'sell_ftl' => 'required|numeric|min:0', + 'buy_ftl' => 'required|numeric|min:0', + 'margin_ftl' => 'required|numeric|min:0', + 'percent_ftl' => 'required|numeric|min:0', + 'status' => 'required|numeric|min:0', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $rate = ConfRates::showRateById($rid); + if (count($rate) < 1) { + $apiResp = Responses::not_found('rate not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + DB::beginTransaction(); + + $insRate = [ + 'origin_prov' => $req->origin_prov, + // 'origin_city' => $req->origin_city, + 'lane' => $req->via, + 'dest_prov' => $req->dest_prov, + 'dest_city' => $req->dest_city, + 'vdr_id' => $req->vendor_id, + 'vhc_type' => $req->vhc_type_id, + 'fast_time' => $req->fast_time, + 'long_time' => $req->long_time, + 'unit_time' => ConfRates::UNIT_DAY, + 'sell_kg' => $req->sell_kg, + 'buy_kg' => $req->buy_kg, + 'margin_kg' => $req->margin_kg, + 'percent_kg' => $req->percent_kg, + 'sell_cbm' => $req->sell_cbm, + 'buy_cbm' => $req->buy_cbm, + 'margin_cbm' => $req->margin_cbm, + 'percent_cbm' => $req->percent_cbm, + 'sell_ftl' => $req->sell_ftl, + 'buy_ftl' => $req->buy_ftl, + 'margin_ftl' => $req->margin_ftl, + 'percent_ftl' => $req->percent_ftl, + 'is_active' => $req->status, + 'crt' => $now, + 'crt_by' => $req->auth->uid, + 'updt' => $now, + 'updt_by' => $req->auth->uid, + ]; + if ($req->dest_district) { + $insRate['dest_district'] = $req->dest_district; + } + $rid = ConfRates::updateRate($rid, $insRate); + + $apiResp = Responses::created('success add new rate'); + + DB::commit(); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_del_rate(Request $req, $rid) + { + try { + $now = time(); + + $input = [ + 'rid' => $rid, + ]; + $rulesInput = [ + 'rid' => 'required|integer|not_in:0', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $rate = ConfRates::showRateById($rid); + if (count($rate) < 1) { + $apiResp = Responses::not_found('rate not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + DB::beginTransaction(); + + ConfRates::updateRate($rid, [ + 'dlt' => $now, + 'dlt_by' => $req->auth->uid, + ]); + + DB::commit(); + + $apiResp = Responses::success('success delete rate'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } +} diff --git a/app/Http/Controllers/ConfTruckTypeController.php b/app/Http/Controllers/ConfTruckTypeController.php new file mode 100755 index 0000000..85598eb --- /dev/null +++ b/app/Http/Controllers/ConfTruckTypeController.php @@ -0,0 +1,321 @@ +passes()) { + // $apiResp = Responses::bad_input($isValidInput->messages()->first()); + // return new Response($apiResp, $apiResp['meta']['code']); + // } + + $list = ConfTruckTypes::listTruckTypes(); + foreach ($list as $key => $row) { + $list[$key]->DT_RowIndex = $key + 1; + $list[$key]->action = '-'; + } + + $apiResp = Responses::success('success list truck types'); + $apiResp['count'] = count($list); + $apiResp['data'] = $list; + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_show_truck_type(Request $req, $ttid) + { + try { + $now = time(); + + $input = [ + 'ttid' => $ttid, + ]; + $rulesInput = [ + 'ttid' => 'required|integer|not_in:0', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $truckType = ConfTruckTypes::showTruckTypeById($ttid); + if (count($truckType) < 1) { + $apiResp = Responses::not_found('truck type not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + $apiResp = Responses::success('success get detail truck type'); + $apiResp['data'] = $truckType[0]; + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_add_truck_type(Request $req) + { + try { + $now = time(); + + $input = [ + 'type_name' => $req->type_name, + 'max_kg' => $req->max_kg, + 'max_cbm' => $req->max_cbm, + 'max_koli' => $req->max_koli, + 'status' => $req->status, + 'publish' => $req->publish, + ]; + $rulesInput = [ + 'type_name' => 'required|string', + 'max_kg' => 'nullable|numeric|min:0', + 'max_cbm' => 'nullable|numeric|min:0', + 'max_koli' => 'nullable|numeric|min:0', + 'status' => 'required|numeric|min:0', + 'publish' => 'required|numeric|min:0', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $uniqName = ConfTruckTypes::getTruckTypeByName($req->type_name); + if (count($uniqName) > 0) { + $apiResp = Responses::bad_request('type name has been used'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + DB::beginTransaction(); + + $type_id = ConfTruckTypes::addTypes([ + 'cat_id' => Vehicles::DEFAULT_CAT_ID, + 'name' => $req->type_name, + 'desc' => $req->type_name, + 'is_active' => $req->status, + 'is_publish' => $req->publish, + 'crt' => $now, + 'crt_by' => $req->auth->uid, + 'updt' => $now, + 'updt_by' => $req->auth->uid, + ]); + + $insTruckType = [ + 'type_id' => $type_id, + 'max_kg' => $req->max_kg ?? 0, + 'max_cbm' => $req->max_cbm ?? 0, + 'max_koli' => $req->max_koli ?? 0, + 'is_active' => $req->status, + 'is_publish' => $req->publish, + 'crt' => $now, + 'crt_by' => $req->auth->uid, + 'updt' => $now, + 'updt_by' => $req->auth->uid, + ]; + $ttid = ConfTruckTypes::addTruckType($insTruckType); + + $apiResp = Responses::created('success add new truck type'); + + DB::commit(); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_edit_truck_type(Request $req, $ttid) + { + try { + $now = time(); + + $input = [ + 'ttid' => $ttid, + 'type_name' => $req->type_name, + 'max_kg' => $req->max_kg, + 'max_cbm' => $req->max_cbm, + 'max_koli' => $req->max_koli, + 'status' => $req->status, + 'publish' => $req->publish, + ]; + $rulesInput = [ + 'ttid' => 'required|integer|not_in:0', + 'type_name' => 'required|string', + 'max_kg' => 'nullable|numeric|min:0', + 'max_cbm' => 'nullable|numeric|min:0', + 'max_koli' => 'nullable|numeric|min:0', + 'status' => 'required|numeric|min:0', + 'publish' => 'required|numeric|min:0', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $truckType = ConfTruckTypes::showTruckTypeById($ttid); + if (count($truckType) < 1) { + $apiResp = Responses::not_found('truck type not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + $uniqName = ConfTruckTypes::getTruckTypeByName($req->type_name); + if (count($uniqName) > 0) { + $notSameUser = 1; + foreach ($uniqName as $key => $row) { + if ($row->id == $ttid) { + $notSameUser = 0; + } + } + if ($notSameUser) { + $apiResp = Responses::bad_request('type name has been used'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + if ($req->status == ConfTruckTypes::IS_INACTIVE) { + $checkVhcType = ConfRates::checkVhcType($truckType[0]->type_id); + if (count($checkVhcType) > 0) { + $apiResp = Responses::bad_request('cannot change to inactive, still connected on rates'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + DB::beginTransaction(); + + ConfTruckTypes::updtTypes($truckType[0]->type_id, [ + 'name' => $req->type_name, + 'desc' => $req->type_name, + 'is_active' => $req->status, + 'is_publish' => $req->publish, + 'updt' => $now, + 'updt_by' => $req->auth->uid, + ]); + + $insTruckType = [ + 'type_id' => $truckType[0]->type_id, + 'max_kg' => $req->max_kg ?? 0, + 'max_cbm' => $req->max_cbm ?? 0, + 'max_koli' => $req->max_koli ?? 0, + 'is_active' => $req->status, + 'is_publish' => $req->publish, + 'updt' => $now, + 'updt_by' => $req->auth->uid, + ]; + $ttid = ConfTruckTypes::updateTruckType($ttid, $insTruckType); + + $apiResp = Responses::created('success update truck type'); + + DB::commit(); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_del_truck_type(Request $req, $ttid) + { + try { + $now = time(); + + $input = [ + 'ttid' => $ttid, + ]; + $rulesInput = [ + 'ttid' => 'required|integer|not_in:0', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $truckType = ConfTruckTypes::showTruckTypeById($ttid); + if (count($truckType) < 1) { + $apiResp = Responses::not_found('truck type not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + $checkVhcType = ConfRates::checkVhcType($truckType[0]->type_id); + if (count($checkVhcType) > 0) { + $apiResp = Responses::bad_request('cannot delete, still connected on rates'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + DB::beginTransaction(); + + ConfTruckTypes::updtTypes($truckType[0]->type_id, [ + 'dlt' => $now, + 'dlt_by' => $req->auth->uid, + ]); + + ConfTruckTypes::updateTruckType($ttid, [ + 'dlt' => $now, + 'dlt_by' => $req->auth->uid, + ]); + + DB::commit(); + + $apiResp = Responses::success('success delete truck type'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } +} diff --git a/app/Http/Controllers/Controller.php b/app/Http/Controllers/Controller.php new file mode 100755 index 0000000..a0a2a8a --- /dev/null +++ b/app/Http/Controllers/Controller.php @@ -0,0 +1,13 @@ + Dana::getDanaById(Dana::PK_ID)[0], + ]; + + $data['dana']->amt = number_format($data['dana']->amt, 0, ',', '.'); + + return view('menu_v2.Finance._dana', $data); + } + + + /** + * API + */ + + public function api_edit_dana(Request $req, $dana_id) + { + try { + $now = time(); + + $input = [ + 'dana_id' => $dana_id, + 'saldo' => $req->amt, + ]; + $rulesInput = [ + 'dana_id' => 'required|integer|not_in:0', + 'saldo' => 'required|numeric', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $dana = Dana::getDanaById(Dana::PK_ID); + if (count($dana) < 1) { + $apiResp = Responses::not_found('Dana not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + if ($input['saldo'] < Dana::MINIMUM_AMT) { + $apiResp = Responses::bad_request('Minimum saldo dana Rp'.number_format(Dana::MINIMUM_AMT, 0, ',', '.')); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + DB::beginTransaction(); + + $updtDana = [ + 'amt' => $input['saldo'], + ]; + Dana::updateDana($input['dana_id'], $updtDana); + + $apiResp = Responses::success('success update dana'); + + DB::commit(); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } +} diff --git a/app/Http/Controllers/DataTypesController.php b/app/Http/Controllers/DataTypesController.php new file mode 100755 index 0000000..f24ad1a --- /dev/null +++ b/app/Http/Controllers/DataTypesController.php @@ -0,0 +1,91 @@ + $req->is_active, + ]; + $rulesInput = [ + 'is_active' => 'nullable|numeric' + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + $filter = []; + if ($input['is_active'] != null && $input['is_active'] != 0) { + $filter['is_active'] = $input['is_active']; + } + + $list = DataTypes::listDataTypes($filter); + foreach ($list as $key => $row) { + $list[$key]->DT_RowIndex = $key + 1; + $list[$key]->action = '-'; + } + + $apiResp = Responses::success('success list data types'); + $apiResp['count'] = count($list); + $apiResp['data'] = $list; + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_show_dtypes(Request $req, $dtypes_id) + { + try { + $now = time(); + + $input = [ + 'dtypes_id' => $dtypes_id, + ]; + $rulesInput = [ + 'dtypes_id' => 'required|integer|not_in:0', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $lgb_key = DataTypes::showDataType(['dtypes_id' => $dtypes_id]); + if (count($lgb_key) < 1) { + $apiResp = Responses::not_found('data type key not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + $apiResp = Responses::success('success get detail data type key'); + $apiResp['data'] = $lgb_key[0]; + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } +} diff --git a/app/Http/Controllers/DevicesController.php b/app/Http/Controllers/DevicesController.php new file mode 100755 index 0000000..ff46800 --- /dev/null +++ b/app/Http/Controllers/DevicesController.php @@ -0,0 +1,407 @@ +auth); + $data = [ + 'vhcs' => $vhcs, + ]; + return view('menu_v1.configs.devices', $data); + } + + /** + * API + */ + + public function api_list_devices(Request $req) + { + try { + $now = time(); + $input = []; + $rulesInput = []; + + // validasi input + // $isValidInput = Validator::make($input, $rulesInput); + // if (!$isValidInput->passes()) { + // $apiResp = Responses::bad_input($isValidInput->messages()->first()); + // return new Response($apiResp, $apiResp['meta']['code']); + // } + + $list = Devices::listDevices(); + foreach ($list as $key => $row) { + $list[$key]->DT_RowIndex = $key + 1; + $list[$key]->action = '-'; + if ($row->vhc_id == null) { + $list[$key]->is_idle = 'yes'; + } else { + $list[$key]->is_idle = 'no'; + } + } + + $apiResp = Responses::success('success list devices'); + $apiResp['count'] = count($list); + $apiResp['data'] = $list; + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_show_device(Request $req, $id) + { + try { + $now = time(); + + $input = [ + 'id' => $id, + ]; + $rulesInput = [ + 'id' => 'required|integer|not_in:0', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $device = Devices::showDeviceById($id); + if (count($device) < 1) { + $apiResp = Responses::not_found('device not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + $apiResp = Responses::success('success get detail device'); + $apiResp['data'] = $device[0]; + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_add_device(Request $req) + { + try { + $now = time(); + + $input = [ + 'device_id' => $req->device_id, + 'name' => $req->name, + 'simcard' => $req->simcard, + 'type' => $req->type, + 'status' => $req->status, + 'assigned' => $req->assigned, + 'vid' => $req->vid, + 'available' => $req->available, + ]; + $rulesInput = [ + 'device_id' => 'required|numeric', + 'name' => 'required|string', + 'simcard' => 'required|numeric', + 'type' => 'required|integer|not_in:0', + 'status' => 'required|numeric|min:0', + 'assigned' => 'required|numeric', + 'vid' => 'nullable|numeric', + 'available' => 'required|numeric', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $device_id = str_pad($req->device_id, Devices::MAX_DEVICE_ID, '0', STR_PAD_LEFT); + if (strlen($device_id) > 16) { + $apiResp = Responses::bad_request('device id maksimal 16 digit'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + if (strlen($req->simcard) > 14) { + $apiResp = Responses::bad_request('simcard maksimal 14 digit'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + $uniqDeviceId = Devices::getDeviceByDeviceId($device_id); + if (count($uniqDeviceId) > 0) { + $apiResp = Responses::bad_request('device id has been used'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + $uniqSimcard = Devices::getDeviceBySimcard($req->simcard); + if (count($uniqSimcard) > 0) { + $apiResp = Responses::bad_request('simcard has been used'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + DB::beginTransaction(); + + $insDevice = [ + 'device_id' => $device_id, + 'name' => $req->name, + 'simcard' => (int)$req->simcard, + 'type' => $req->type, + 'is_active' => $req->status, + 'is_assigned' => $req->assigned, + 'is_available' => $req->available, + 'crt' => $now, + 'crt_by' => $req->auth->uid, + 'updt' => $now, + 'updt_by' => $req->auth->uid, + ]; + $id = Devices::addDevice($insDevice); + + if ($req->assigned == Devices::IS_ASSIGNED) { + if ($req->vid == null || $req->vid == "") { + DB::rollBack(); + $apiResp = Responses::bad_request('kendaraan belum dipilih'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + $vhc = Vehicles::getVehicleByDeviceId($device_id); + if (count($vhc) > 0) { + DB::rollBack(); + $apiResp = Responses::bad_request('kendaraan sudah dipasang oleh device id ' . $vhc[0]->device_id); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + $vhc = Vehicles::getVehicleById($req->vid); + if (count($vhc) > 0 && $vhc[0]->dvc_id !== 0 && $vhc[0]->device_id !== $device_id) { + DB::rollBack(); + $apiResp = Responses::bad_request('kendaraan sudah dipasang oleh device id ' . $vhc[0]->device_id); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + $vid = $req->vid; + Vehicles::updateVehicle($vid, [ + 'dvc_id' => $id, + 'device_id' => $device_id, + 'simcard' => (int)$req->simcard, + ]); + } else { + $vid = 0; + } + + $apiResp = Responses::created('success add new device'); + + DB::commit(); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_updt_device(Request $req, $id) + { + try { + $now = time(); + + $input = [ + 'id' => $id, + 'device_id' => $req->device_id, + 'name' => $req->name, + 'simcard' => $req->simcard, + 'type' => $req->type, + 'status' => $req->status, + 'assigned' => $req->assigned, + 'vid' => $req->vid, + 'available' => $req->available, + ]; + $rulesInput = [ + 'id' => 'required|integer|not_in:0', + 'device_id' => 'required|numeric', + 'name' => 'required|string', + 'simcard' => 'required|numeric', + 'type' => 'required|integer|not_in:0', + 'status' => 'required|numeric', + 'assigned' => 'required|numeric', + 'vid' => 'nullable|numeric', + 'available' => 'required|numeric', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $device = Devices::showDeviceById($id); + if (count($device) < 1) { + $apiResp = Responses::not_found('device not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + $device_id = str_pad($req->device_id, Devices::MAX_DEVICE_ID, '0', STR_PAD_LEFT); + if (strlen($device_id) > 16) { + $apiResp = Responses::bad_request('device id maksimal 16 digit'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + if (strlen($req->simcard) > 14) { + $apiResp = Responses::bad_request('simcard maksimal 14 digit'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + $uniqDeviceId = Devices::getDeviceByDeviceId($device_id); + if (count($uniqDeviceId) > 0) { + $notSameUser = 1; + foreach ($uniqDeviceId as $key => $row) { + if ($row->id == $id) { + $notSameUser = 0; + } + } + if ($notSameUser) { + $apiResp = Responses::bad_request('device id has been used'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + $uniqSimcard = Devices::getDeviceBySimcard($req->simcard); + if (count($uniqSimcard) > 0) { + $notSameUser = 1; + foreach ($uniqSimcard as $key => $row) { + if ($row->id == $id) { + $notSameUser = 0; + } + } + if ($notSameUser) { + $apiResp = Responses::bad_request('simcard has been used'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + if ($req->status == Devices::IS_INACTIVE) { + $isUsed = Vehicles::getVehicleByDeviceId($device_id); + if (count($isUsed) > 0) { + $apiResp = Responses::bad_request('tidak dapat mengubah menjadi nonaktif, device sedang digunakan'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + DB::beginTransaction(); + + if ($device[0]->vhc_id) { + Vehicles::updateVehicle($device[0]->vhc_id, [ + 'dvc_id' => 0, + 'device_id' => str_pad(0, Devices::MAX_DEVICE_ID, '0', STR_PAD_LEFT), + 'simcard' => 0, + ]); + } + + if ($req->assigned == Devices::IS_ASSIGNED) { + if ($req->vid == null || $req->vid == "") { + DB::rollBack(); + $apiResp = Responses::bad_request('kendaraan belum dipilih'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + $vhc = Vehicles::getVehicleById($req->vid); + if (count($vhc) > 0 && $vhc[0]->dvc_id !== 0 && $vhc[0]->device_id !== $device_id) { + DB::rollBack(); + $apiResp = Responses::bad_request('kendaraan sudah dipasang dengan device id ' . $vhc[0]->device_id); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + $vid = $req->vid; + Vehicles::updateVehicle($vid, [ + 'dvc_id' => $id, + 'device_id' => $device_id, + 'simcard' => (int)$req->simcard, + ]); + } else { + $vhc = Vehicles::getVehicleByDeviceId($device_id); + if (count($vhc) > 0) { + $vid = $vhc[0]->id; + Vehicles::updateVehicle($vid, [ + 'dvc_id' => 0, + 'device_id' => str_pad(0, Devices::MAX_DEVICE_ID, '0', STR_PAD_LEFT), + 'simcard' => 0, + ]); + } + } + + $updtDevice = [ + 'device_id' => $req->device_id, + 'name' => $req->name, + 'simcard' => (int)$req->simcard, + 'type' => $req->type, + 'is_active' => $req->status, + 'is_assigned' => $req->assigned, + 'is_available' => $req->available, + 'updt' => $now, + 'updt_by' => $req->auth->uid, + ]; + Devices::updateDevice($id, $updtDevice); + + $apiResp = Responses::created('success update device'); + + DB::commit(); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_del_device(Request $req, $id) + { + try { + $now = time(); + + $input = [ + 'id' => $id, + ]; + $rulesInput = [ + 'id' => 'required|integer|not_in:0', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $device = Devices::showDeviceById($id); + if (count($device) < 1) { + $apiResp = Responses::not_found('device not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + $isUsed = Vehicles::getVehicleByDeviceId($device[0]->device_id); + if (count($isUsed) > 0) { + $apiResp = Responses::bad_request('tidak dapat menghapus, device sedang digunakan'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + DB::beginTransaction(); + + Devices::updateDevice($id, [ + 'dlt' => $now, + 'dlt_by' => $req->auth->uid, + ]); + + DB::commit(); + + $apiResp = Responses::success('success delete device'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } +} diff --git a/app/Http/Controllers/DriversController.php b/app/Http/Controllers/DriversController.php new file mode 100755 index 0000000..f762968 --- /dev/null +++ b/app/Http/Controllers/DriversController.php @@ -0,0 +1,678 @@ +passes()) { + // $apiResp = Responses::bad_input($isValidInput->messages()->first()); + // return new Response($apiResp, $apiResp['meta']['code']); + // } + + $filter = []; + if ($req->cptid) { + $filter["company"] = $req->cptid; + } + $list = Drivers::listDrivers($req->auth, $filter); + foreach ($list as $key => $row) { + $list[$key]->DT_RowIndex = $key + 1; + $list[$key]->mileage_km = "-"; + $list[$key]->action = "-"; + } + + $apiResp = Responses::success("success list drivers"); + $apiResp["data"] = $list; + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_show_driver(Request $req, $did) + { + try { + $now = time(); + + $input = [ + "did" => $did, + ]; + $rulesInput = [ + "did" => "required|integer|not_in:0", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $driver = Drivers::showDriverById($did); + if (count($driver) < 1) { + $apiResp = Responses::not_found("driver not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $apiResp = Responses::success("success get detail driver"); + $apiResp["data"] = $driver[0]; + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_add_driver(Request $req) + { + $url_ktp = ""; + $url_npwp = ""; + $url_license = ""; + try { + $now = time(); + + $input = [ + "ktp_photo" => $req->ktp_base64, + "nik" => $req->nik, + "fullname" => $req->fullname, + "fullname2" => $req->fullname2, + "phone" => $req->phone, + "phone2" => $req->phone2, + "email" => $req->email, + "date_of_birth" => $req->dob, + "age" => $req->age, + "blood" => $req->blood, + "home_address" => $req->fulladdress, + "npwp_photo" => $req->npwp_base64, + "npwp_number" => $req->npwp_string, + "npwp_number_hidden" => $req->npwp_number, + "license_photo" => $req->license_base64, + "license_number" => $req->license_number, + "license_exp" => $req->license_exp, + "emergency_fullname" => $req->em_fullname, + "emergency_relationship" => $req->em_relationship, + "emergency_phone" => $req->em_phone, + "bank_id" => $req->bank_id, + "bank_code" => $req->bank_code, + "bank_short" => $req->bank_short, + "bank_name" => $req->bank_name, + "bank_kcp" => $req->bank_branch_name, + "bank_acc_number" => $req->bank_acc_number, + "bank_acc_name" => $req->bank_acc_name, + "vendor_id" => Auth::user()->id, + ]; + $rulesInput = [ + "ktp_photo" => "nullable|string", // required + "nik" => "nullable|integer", // required + "fullname" => "required|string|min:3|max:125", + "fullname2" => "nullable|string", + "phone" => "required|integer|not_in:0", + "phone2" => "nullable|integer|not_in:0", + "email" => "nullable|email", // required + "date_of_birth" => "nullable|date_format:Y-m-d", // required + "age" => "nullable|integer", // required + "blood" => "nullable|string|max:4", // required + "home_address" => "nullable|string|min:25", // required + "npwp_photo" => "nullable|string", // required + "npwp_number" => "nullable|string", // required + "npwp_number_hidden" => "nullable|numeric", // required + "license_photo" => "nullable|string", // required + "license_number" => "nullable|numeric", // required + "license_exp" => "nullable|date_format:Y-m-d", // required + "emergency_fullname" => "nullable|string|min:3", // required + "emergency_relationship" => "nullable|string", // required + "emergency_phone" => "nullable|integer|not_in:0", // required + "bank_id" => "required|integer|not_in:0", + "bank_code" => "required|numeric", + "bank_short" => "required|string", + "bank_name" => "required|string", + "bank_kcp" => "nullable|string", + "bank_acc_number" => "nullable|numeric", // required + "bank_acc_name" => "nullable|string|max:255", // required + "vendor_id" => "required|integer|not_in:0", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + if ($req->nik && strlen($req->nik) != 16) { + $apiResp = Responses::bad_input("nik must be 16 digit"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + if ($req->license_number && strlen($req->license_number) < 12) { + $apiResp = Responses::bad_input("license number must be at least 12 digit"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + if ($req->nik) { + $uniqNik = Drivers::getDriverByNik($req->nik); + if (count($uniqNik) > 0) { + $apiResp = Responses::bad_request("nik has been used"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + if ($req->phone) { + $uniqPhone = Drivers::getDriverByPhone($req->phone); + if (count($uniqPhone) > 0) { + $apiResp = Responses::bad_request("phone has been used"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + if ($req->email) { + $uniqEmail = Drivers::getDriverByEmail($req->email); + if (count($uniqEmail) > 0) { + $apiResp = Responses::bad_request("email has been used"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + DB::beginTransaction(); + + $insDriver = [ + "nik" => $req->nik ? $req->nik : 0, + "fullname" => $req->fullname, + "email" => $req->email, + "fullname2" => $req->fullname2, + "phone" => $req->phone, + "phone_code" => Drivers::DEFAULT_PHONE_CODE, + "phone2" => $req->phone2 ?? 0, + "phone2_code" => Drivers::DEFAULT_PHONE_CODE, + "dob" => $req->dob, + "age" => $req->age ? $req->age : 0, + "blood" => $req->blood, + "fulladdress" => $req->fulladdress, + "client_group_id" => $req->auth->client_group_id ?? null, + "crt" => $now, + "crt_by" => $req->auth->uid, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]; + if ($req->auth->role == Users::ROLE_VENDOR) { + $insDriver["vendor_id"] = $req->auth->uid; + } else { + $insDriver["vendor_id"] = Auth::user()->id ?? 0; + } + $did = Drivers::addDriver($insDriver); + + if ($req->ktp_base64) { + $url_ktp = "drivers/$did/ktp_$now.jpeg"; + if (!Storage::disk("public")->put($url_ktp, base64_decode($req->ktp_base64))) { + DB::rollBack(); + $apiResp = Responses::bad_request("fail upload ktp photo"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + if ($req->npwp_base64) { + $url_npwp = "drivers/$did/npwp_$now.jpeg"; + if (!Storage::disk("public")->put($url_npwp, base64_decode($req->npwp_base64))) { + Storage::disk("public")->delete($url_ktp); + DB::rollBack(); + $apiResp = Responses::bad_request("fail upload npwp photo"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + if ($req->license_base64) { + $url_license = "drivers/$did/license_$now.jpeg"; + if (!Storage::disk("public")->put($url_license, base64_decode($req->license_base64))) { + Storage::disk("public")->delete($url_ktp); + Storage::disk("public")->delete($url_npwp); + DB::rollBack(); + $apiResp = Responses::bad_request("fail upload license photo"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + $insDetail = [ + "did" => $did, + "ktp_img" => $url_ktp ? $url_ktp : "", + "npwp_img" => $url_npwp ? $url_npwp : "", + "npwp_string" => $req->npwp_string, + "npwp_number" => $req->npwp_number, + "license_img" => $url_license ? $url_license : "", + "license_number" => $req->license_number, + "license_exp" => $req->license_exp, + "em_fullname" => $req->em_fullname, + "em_phone" => $req->em_phone, + "em_relationship" => $req->em_relationship, + "bank_id" => $req->bank_id, + "bank_code" => $req->bank_code, + "bank_short_name" => $req->bank_short, + "bank_name" => $req->bank_name, + "bank_branch_name" => $req->bank_branch_name, + "bank_acc_number" => $req->bank_acc_number, + "bank_acc_name" => $req->bank_acc_name, + ]; + DriversDetail::addDetail($insDetail); + + $insAccount = [ + "client_id" => Auth::user()->client_id, + "client_group_id" => Auth::user()->client_group_id, + "first_name" => $req->fullname, + "last_name" => null, + "email" => $req->email, + "phone" => $req->phone, + "phone_code" => Users::DEFAULT_PHONE_CODE, + "fulladdress" => $req->fulladdress, + "password" => Hash::make("0" . $req->phone), + "role" => Users::ROLE_VENDOR_DRIVER, + "is_driver" => 1, + "status" => 1, + "crt" => $now, + "crt_by" => $req->auth->uid, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]; + Users::addUser($insAccount); + + $apiResp = Responses::created("success add new driver"); + + DB::commit(); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + Storage::disk("public")->delete($url_ktp); + Storage::disk("public")->delete($url_npwp); + Storage::disk("public")->delete($url_license); + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_edit_driver(Request $req, $did) + { + $url_ktp = ""; + $url_npwp = ""; + $url_license = ""; + try { + $now = time(); + + $input = [ + "did" => $did, + "ktp_photo" => $req->ktp_base64, + "nik" => $req->nik, + "fullname" => $req->fullname, + "fullname2" => $req->fullname2, + "phone" => $req->phone, + "phone2" => $req->phone2, + "email" => $req->email, + "date_of_birth" => $req->dob, + "age" => $req->age, + "blood" => $req->blood, + "home_address" => $req->fulladdress, + "npwp_photo" => $req->npwp_base64, + "npwp_number" => $req->npwp_string, + "npwp_number_hidden" => $req->npwp_number, + "license_photo" => $req->license_base64, + "license_number" => $req->license_number, + "license_exp" => $req->license_exp, + "emergency_fullname" => $req->em_fullname, + "emergency_relationship" => $req->em_relationship, + "emergency_phone" => $req->em_phone, + "bank_id" => $req->bank_id, + "bank_code" => $req->bank_code, + "bank_short" => $req->bank_short, + "bank_name" => $req->bank_name, + "bank_kcp" => $req->bank_branch_name, + "bank_acc_number" => $req->bank_acc_number, + "bank_acc_name" => $req->bank_acc_name, + "vendor_id" => Auth::user()->id, + ]; + $rulesInput = [ + "did" => "required|integer|not_in:0", + "ktp_photo" => "nullable|string", + "nik" => "required|integer", + "fullname" => "nullable|string|min:3|max:125", // required + "fullname2" => "nullable|string", + "phone" => "required|integer|not_in:0", + "phone2" => "nullable|integer|not_in:0", + "email" => "nullable|email", // required + "date_of_birth" => "nullable|date_format:Y-m-d", // required + "age" => "nullable|integer", // required + "blood" => "nullable|string|max:4", // required + "home_address" => "nullable|string|min:25", // required + "npwp_photo" => "nullable|string", + "npwp_number" => "nullable|string", // required + "npwp_number_hidden" => "nullable|numeric", // required + "license_photo" => "nullable|string", + "license_number" => "nullable|numeric", // required + "license_exp" => "nullable|date_format:Y-m-d", // required + "emergency_fullname" => "nullable|string|min:3", // required + "emergency_relationship" => "nullable|string", // required + "emergency_phone" => "nullable|integer|not_in:0", // required + "bank_id" => "required|integer|not_in:0", // required + "bank_code" => "required|numeric", + "bank_short" => "required|string", + "bank_name" => "required|string", + "bank_kcp" => "nullable|string", + "bank_acc_number" => "required|numeric", + "bank_acc_name" => "required|string|max:255", + "vendor_id" => "required|integer|not_in:0", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + if ($req->nik && strlen($req->nik) != 16) { + $apiResp = Responses::bad_input("nik must be 16 digit"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + if ($req->license_number && strlen($req->license_number) < 12) { + $apiResp = Responses::bad_input("license number must be at least 12 digit"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $driver = Drivers::showDriverById($did); + if (count($driver) < 1) { + $apiResp = Responses::not_found("driver not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + if ($req->nik) { + $uniqNik = Drivers::getDriverByNik($req->nik); + if (count($uniqNik) > 0) { + $notSameUser = 1; + foreach ($uniqNik as $key => $row) { + if ($row->id == $did) { + $notSameUser = 0; + } + } + if ($notSameUser) { + $apiResp = Responses::bad_request("nik has been used"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + } + if ($req->phone) { + $uniqPhone = Drivers::getDriverByPhone($req->phone); + if (count($uniqPhone) > 0) { + $notSameUser = 1; + foreach ($uniqPhone as $key => $row) { + if ($row->id == $did) { + $notSameUser = 0; + } + } + if ($notSameUser) { + $apiResp = Responses::bad_request("phone has been used"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + } + if ($req->email) { + $uniqEmail = Drivers::getDriverByEmail($req->email); + if (count($uniqEmail) > 0) { + $notSameUser = 1; + foreach ($uniqEmail as $key => $row) { + if ($row->id == $did) { + $notSameUser = 0; + } + } + if ($notSameUser) { + $apiResp = Responses::bad_request("email has been used"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + } + + DB::beginTransaction(); + + $updtDriver = [ + "nik" => $req->nik ? $req->nik : 0, + "fullname" => $req->fullname, + "email" => $req->email, + "fullname2" => $req->fullname2, + "phone" => $req->phone, + "phone_code" => Drivers::DEFAULT_PHONE_CODE, + "phone2" => $req->phone2 ?? 0, + "phone2_code" => Drivers::DEFAULT_PHONE_CODE, + "dob" => $req->dob, + "age" => $req->age ? $req->age : 0, + "blood" => $req->blood, + "fulladdress" => $req->fulladdress, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]; + if ($req->auth->role == Users::ROLE_VENDOR) { + $updtDriver["vendor_id"] = $req->auth->uid; + } else { + $updtDriver["vendor_id"] = Auth::user()->id ?? 0; + } + Drivers::updateDriver($did, $updtDriver); + + if ($req->ktp_base64) { + $url_ktp = "drivers/$did/ktp_$now.jpeg"; + if (!Storage::disk("public")->put($url_ktp, base64_decode($req->ktp_base64))) { + DB::rollBack(); + $apiResp = Responses::bad_request("fail upload ktp photo"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + Storage::disk("public")->delete($driver[0]->ktp_img); + } + if ($req->npwp_base64) { + $url_npwp = "drivers/$did/npwp_$now.jpeg"; + if (!Storage::disk("public")->put($url_npwp, base64_decode($req->npwp_base64))) { + Storage::disk("public")->delete($url_ktp); + DB::rollBack(); + $apiResp = Responses::bad_request("fail upload npwp photo"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + Storage::disk("public")->delete($driver[0]->npwp_img); + } + if ($req->license_base64) { + $url_license = "drivers/$did/license_$now.jpeg"; + if (!Storage::disk("public")->put($url_license, base64_decode($req->license_base64))) { + Storage::disk("public")->delete($url_ktp); + Storage::disk("public")->delete($url_npwp); + DB::rollBack(); + $apiResp = Responses::bad_request("fail upload license photo"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + Storage::disk("public")->delete($driver[0]->license_img); + } + + $updtDetail = [ + "npwp_string" => $req->npwp_string, + "npwp_number" => $req->npwp_number, + "license_number" => $req->license_number, + "license_exp" => $req->license_exp, + "em_fullname" => $req->em_fullname, + "em_phone" => $req->em_phone, + "em_relationship" => $req->em_relationship, + "bank_id" => $req->bank_id, + "bank_code" => $req->bank_code, + "bank_short_name" => $req->bank_short, + "bank_name" => $req->bank_name, + "bank_branch_name" => $req->bank_branch_name, + "bank_acc_number" => $req->bank_acc_number, + "bank_acc_name" => $req->bank_acc_name, + ]; + if ($req->ktp_base64) { + $updtDetail["ktp_img"] = $url_ktp; + } + if ($req->npwp_base64) { + $updtDetail["npwp_img"] = $url_npwp; + } + if ($req->license_base64) { + $updtDetail["license_img"] = $url_license; + } + DriversDetail::updateDetailByDid($did, $updtDetail); + DB::commit(); + + $apiResp = Responses::success("success update driver"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + Storage::disk("public")->delete($url_ktp); + Storage::disk("public")->delete($url_npwp); + Storage::disk("public")->delete($url_license); + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_del_driver(Request $req, $did) + { + try { + $now = time(); + + $input = [ + "did" => $did, + ]; + $rulesInput = [ + "did" => "required|integer|not_in:0", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $driver = Drivers::showDriverById($did); + if (count($driver) < 1) { + $apiResp = Responses::not_found("driver not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + DB::beginTransaction(); + + Drivers::updateDriver($did, [ + "dlt" => $now, + "dlt_by" => $req->auth->uid, + ]); + + // Storage::disk('public')->delete($driver[0]->ktp_img); + // Storage::disk('public')->delete($driver[0]->npwp_img); + // Storage::disk('public')->delete($driver[0]->license_img); + + DB::commit(); + + $apiResp = Responses::success("success delete driver"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_search_driver_name(Request $req) + { + try { + $now = time(); + + $input = [ + "name" => $req->name, + ]; + $rulesInput = [ + "name" => "required|string|max:125", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $drivers = Drivers::likeName($req->name); + + if (count($drivers) < 1) { + $apiResp = Responses::not_found("driver not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $apiResp = Responses::success("success search driver by name"); + $apiResp["data"] = $drivers; + + DB::commit(); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_reset_login_driver(Request $req, $did) + { + try { + $now = time(); + + $input = [ + "did" => $did, + ]; + $rulesInput = [ + "did" => "required|integer|not_in:0", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $driver = Drivers::showDriverById($did); + if (count($driver) < 1) { + $apiResp = Responses::not_found("driver not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + DB::beginTransaction(); + + DrvPhoneDevices::dltByOrdDrvId($did); + + $_dtUpdate = [ + "phone" => $driver[0]->phone, + "password" => Hash::make("0" . $driver[0]->phone), + "updt" => $now, + "updt_by" => Auth::user()->id, + ]; + DB::table("t_users") + ->where("email", $driver[0]->email) + ->where("status", 1) + ->whereNull("dlt") + ->update($_dtUpdate); + + DB::commit(); + + $apiResp = Responses::success("success reset login driver"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } +} diff --git a/app/Http/Controllers/DummyController.php b/app/Http/Controllers/DummyController.php new file mode 100755 index 0000000..8c8955e --- /dev/null +++ b/app/Http/Controllers/DummyController.php @@ -0,0 +1,233 @@ +start_lat, $req->start_lng, $req->end_lat, $req->end_lng, Helper::EARTH_RADIUS_MILES); + // $apiResp['data']['distance_in_km'] = round($distance*1.609, 4); + // $apiResp['data']['distance_in_miles'] = round($distance, 4); + // $apiResp['data']['distance_in_meters'] = round($distance*1609, 4); + + // $distance == km + // $distance = Helper::haversineGreatCircleDistance($req->start_lat, $req->start_lng, $req->end_lat, $req->end_lng, Helper::EARTH_RADIUS_KM); + // $apiResp['data']['distance_in_km'] = round($distance, 4); + // $apiResp['data']['distance_in_miles'] = round($distance/1.609, 4); + // $apiResp['data']['distance_in_meters'] = round($distance*1000, 4); + + // $distance == meters + $distance = Helper::haversineGreatCircleDistance($req->start_lat, $req->start_lng, $req->end_lat, $req->end_lng, Helper::EARTH_RADIUS_M); + $apiResp['data']['distance_in_km'] = round($distance / 1000, 4); + $apiResp['data']['distance_in_miles'] = round($distance / 1609, 4); + $apiResp['data']['distance_in_meters'] = round($distance, 4); + + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_addBatchDummyTracks(Request $req) + { + try { + $now = time(); + $apiResp = Responses::success(); + $batch_tracks = $req->batch_tracks; + DB::beginTransaction(); + + foreach ($batch_tracks as $key => $val) { + $batch_tracks[$key]['crt'] = $now; + $now = strtotime('+2 seconds', $now); + Dummy::addDummyTrack($batch_tracks[$key]); + } + $apiResp['data'] = $batch_tracks; + + DB::commit(); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_getTracksBySeconds(Request $req) + { + try { + $routes = Dummy::getByGpsId($req->gps_id); + if (!isset($routes[0])) { + $apiResp = Responses::not_found(); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + /** + * ngebandingin dari row yg belum berbeda ke row berikutnya + * jika data: 2,4,6,8,10 + * diff_sec: 2 + * results: 2,6,... + * diff_sec: 4 + * results: 2,8,... + * diff_sec: 6 + * results: 2,10,... + */ + // $start_now = strtotime('+'.$req->sec.' seconds', $routes[0]->crt); + // $init_per_chunk = 0; + // foreach ($routes as $key => $val) { + // if ($init_per_chunk == 1) { + // if ($val->crt >= $start_now) { + // $start_now = strtotime('+'.$req->sec.' seconds', $routes[$key-1]->crt); + // $init_per_chunk = 0; + // } + // continue; + // } + // $init_per_chunk = 1; + // $chunk_by_sec[] = $val; + // } + + /** + * ngebandingin dari row yg belum berbeda ke row berikutnya + * jika data: 2,4,6,8,10,12,14 + * diff_sec: 2 + * results: 2,4,6,8 + * diff_sec: 4 + * results: 2,6,10 + * diff_sec: 6 + * results: 2,8,14 + */ + $chunk_by_sec = []; + $chunk_by_sec[] = $routes[0]; + foreach ($routes as $key => $val) { + $diffSec = $val->crt - end($chunk_by_sec)->crt; + if ($diffSec >= $req->sec) { + $chunk_by_sec[] = $val; + } + } + + $apiResp = Responses::success(); + $apiResp['total'] = count($chunk_by_sec); + $apiResp['data'] = $chunk_by_sec; + + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_addDummyHub(Request $req) + { + try { + $now = time(); + DB::beginTransaction(); + + $input = [ + 'name' => $req->name, + 'lat' => $req->lat, + 'lng' => $req->lng, + 'polygon' => $req->polygon, + ]; + $rulesInput = [ + 'name' => 'required|string|max:45', + 'lat' => 'required', + 'lng' => 'required', + 'polygon' => 'required|array', + 'polygon.*.lat' => 'required', + 'polygon.*.lng' => 'required', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + DB::rollBack(); + return new Response($apiResp, $apiResp['meta']['code']); + } + + /** + * The axis order for coordinates in WKT is Cartesian, so (X Y) or (longitude latitude). + * https://stackoverflow.com/questions/29315117/what-is-the-correct-mysql-polygon-format-for-latitude-and-longitude + * https://stackoverflow.com/questions/5756232/moving-lat-lon-text-columns-into-a-point-type-column + */ + + $ins = [ + 'name' => $req->name, + 'lat' => $req->lat, + 'lng' => $req->lng, + 'lnglat' => DB::raw("ST_GeomFromText('POINT($req->lng $req->lat)')"), + 'shape' => "ST_GeomFromText('MULTIPOINT(", + ]; + foreach ($req->polygon as $key => $val) { + $ins['shape'] .= $val['lng'] . " " . $val['lat'].", "; + } + $ins['shape'] = substr($ins['shape'], 0, -2); + $ins['shape'] .= ")')"; + $ins['shape'] = DB::raw($ins['shape']); + // return (new Response($ins['shape'], 200)); + Dummy::addDummyHub($ins); + + $apiResp = Responses::success(); + DB::commit(); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_nearestHub(Request $req) + { + try { + $now = time(); + + $input = [ + 'lat' => $req->lat, + 'lng' => $req->lng, + ]; + $rulesInput = [ + 'lat' => 'required', + 'lng' => 'required', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $apiResp = Responses::success(); + /** + * The axis order for coordinates in WKT is Cartesian, so (X Y) or (longitude latitude). + * https://stackoverflow.com/questions/29315117/what-is-the-correct-mysql-polygon-format-for-latitude-and-longitude + * https://stackoverflow.com/questions/5756232/moving-lat-lon-text-columns-into-a-point-type-column + */ + + $apiResp['data'] = Dummy::nearestHubInCircle($req->lat, $req->lng); + + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } +} diff --git a/app/Http/Controllers/FinanceController.php b/app/Http/Controllers/FinanceController.php new file mode 100755 index 0000000..8e64036 --- /dev/null +++ b/app/Http/Controllers/FinanceController.php @@ -0,0 +1,3599 @@ + $req->code, + ]; + $rulesInput = [ + 'code' => 'required|numeric', + ]; + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + return abort(403, $isValidInput->messages()->first()); + } + + $ord_invc = OrdersInvoices::getByCode($req->code); + if (count($ord_invc) < 1) { + return abort(404, 'invoice not found'); + } + if ($ord_invc[0]->is_gnrt_invc !== OrdersInvoices::IS_GNRT_INVC_YES) return abort(404, 'invoice not found'); + + $filter = [ + 'id' => $ord_invc[0]->ord_id, + 'get_checker_data' => 1, + 'get_prefer_type_truck' => 1, + 'get_additional_vehicles_info' => 1, + 'get_client_pt' => 1, + 'select_region_pck_drop' => 1, + 'get_pic_zone' => 1, + 'couple_pck_drop' => 1, + ]; + $order = Orders::showOrder($filter); + if (count($order) < 1) { + return abort(404, 'order not found'); + } + + if ($ord_invc[0]->ord_a_item_ids == null) { + return abort(404, 'items not found'); + } + // dd(implode(str_split($order[0]->c_pt_pic_phone_val, 4), ' ')); + + $drvs_ups = OrdersDriversUploads::list([ + 'ord_id' => $order[0]->ord_id, + 'pck_id' => $order[0]->ord_pck_id, + 'drop_id' => $order[0]->ord_drop_id, + 'ord_pck_drop_id' => $order[0]->ord_pck_drop_id, + ]); + + $data = [ + 'ord_invc' => $ord_invc[0], + 'order' => $order[0], + 'drvs_ups' => $drvs_ups, + 'items' => OrdersAItems::showAItemByIds(explode(',', $ord_invc[0]->ord_a_item_ids)), + ]; + + $pdf = PDF::loadView("menu_v2.Finance._printInvoice", $data); + return $pdf->setPaper('a4', 'potrait')->stream('invoice.pdf'); + // return view("menu_v2.Finance._printInvoice", $data); + // } catch (\Exception $e) { + // $apiResp = Responses::error($e->getMessage()); + // return abort(500, $apiResp['meta']['message']); + // } + } + + public function view_ledger_balance(Request $req) + { + return view('menu_v2.Finance.ledgerBalance'); + } + + public function view_pocket_tf_history(Request $req) + { + $data = []; + + return view('menu_v2.Finance.pocket_tf_history', $data); + } + + + /** + * API + */ + public function api_finance_list_billings(Request $req) + { + try { + $now = time(); + $input = []; + $rulesInput = []; + + // validasi input + // $isValidInput = Validator::make($input, $rulesInput); + // if (!$isValidInput->passes()) { + // $apiResp = Responses::bad_input($isValidInput->messages()->first()); + // return new Response($apiResp, $apiResp['meta']['code']); + // } + + $filter = [ + 'group_by' => 'ord_id', + ]; + if (($req->start_date != null && $req->start_date != '') && ($req->end_date != null && $req->end_date != '')) { + $filter['start_date'] = $req->start_date; + $filter['end_date'] = $req->end_date; + } + $list = Finance::listBillings($filter); + $summary = Finance::summaryBillings($filter)[0] ?? new \StdClass(); + foreach ($list as $key => $row) { + $list[$key]->DT_RowIndex = $key + 1; + $list[$key]->action = '-'; + $list[$key]->main_item = "Pengantaran Logistik
" . ucwords(strtolower($row->pck_prid_name)) . " - " . ucwords(strtolower($row->drop_prid_name)) . "
" . date('d F Y', $row->set_pck_at); + } + + $apiResp = Responses::success('success list billings'); + $apiResp['count'] = count($list); + $apiResp['summary'] = [ + 'total_billing' => $summary->total_billing ?? 0, + 'total_payed' => $summary->total_payed ?? 0, + 'total_remaining' => $summary->total_remaining ?? 0, + ]; + $apiResp['data'] = $list; + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_finance_list_payments(Request $req) + { + try { + $now = time(); + $input = []; + $rulesInput = []; + + // validasi input + // $isValidInput = Validator::make($input, $rulesInput); + // if (!$isValidInput->passes()) { + // $apiResp = Responses::bad_input($isValidInput->messages()->first()); + // return new Response($apiResp, $apiResp['meta']['code']); + // } + + $filter = [ + 'group_by' => 'ord_id', + ]; + if (($req->start_date != null && $req->start_date != '') && ($req->end_date != null && $req->end_date != '')) { + $filter['start_date'] = $req->start_date; + $filter['end_date'] = $req->end_date; + } + $list = Finance::listPayments($filter); + $summary = Finance::summaryPayments($filter)[0] ?? new \StdClass(); + + $newList = []; + $cntK = 0; + foreach ($list as $key => $row) { + $list[$key]->action = '-'; + $list[$key]->main_item = "Pengantaran Logistik
" . ucwords(strtolower($row->pck_prid_name)) . " - " . ucwords(strtolower($row->drop_prid_name)) . "
" . date('d F Y', $row->set_pck_at); + $isSame = 0; + foreach ($newList as $nlK => $rowL) { + if (!$row->ord_group_code) continue; + if ($row->ord_group_code === $rowL->ord_group_code) { + $isSame = 1; + $newList[$nlK]->childs[] = clone $list[$key]; + } + } + if ($isSame) continue; + $list[$key]->DT_RowIndex = ++$cntK; + $list[$key]->childs = []; + $newList[] = clone $list[$key]; + } + + $apiResp = Responses::success('success list payments'); + $apiResp['count'] = count($newList); + $apiResp['summary'] = [ + 'total_payment' => $summary->total_payment ?? 0, + 'total_payed' => $summary->total_payed ?? 0, + 'total_remaining' => $summary->total_remaining ?? 0, + ]; + $apiResp['data'] = $newList; + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_finance_list_ledger_balances(Request $req) + { + try { + $now = time(); + $input = []; + $rulesInput = []; + + // validasi input + // $isValidInput = Validator::make($input, $rulesInput); + // if (!$isValidInput->passes()) { + // $apiResp = Responses::bad_input($isValidInput->messages()->first()); + // return new Response($apiResp, $apiResp['meta']['code']); + // } + + $filterList = [ + 'with_items' => 1, + 'group_by' => 'ord_a_item.id', + ]; + $filterSum = []; + if (($req->start_date != null && $req->start_date != '') && ($req->end_date != null && $req->end_date != '')) { + $filterList['start_date'] = $req->start_date; + $filterList['end_date'] = $req->end_date; + $filterSum['start_date'] = $req->start_date; + $filterSum['end_date'] = $req->end_date; + } + $list = Finance::listLedgerBl($filterList); + $summary = Finance::summaryLedgerBl($filterSum)[0]; + + // grouping & formatting v1 + $group_by_order_id = []; + foreach ($list as $key => $row) { + $row->amt_in = 0; + $row->amt_out = 0; + if ($row->a_item_type === OrdersAItems::A_TYPE_PRIMARY) { + $row->item_desc = "Pengantaran Logistik
" . ucwords(strtolower($row->pck_prid_name)) . " - " . ucwords(strtolower($row->drop_prid_name)) . "
" . date('d F Y', $row->set_pck_at); + } + if ($row->calc_to_vdr === OrdersAItems::CALC_TO_VDR_YES) { + $row->amt_out = $row->amt_total_flat; + } + if ($row->invc_to_client === OrdersAItems::INVC_TO_CLIENT_YES) { + $row->amt_in = $row->amt_bill_total_flat; + } + $row->amt_bl = $row->amt_in - $row->amt_out; + + if (!isset($group_by_order_id[$row->ord_id])) { + $group_by_order_id[$row->ord_id] = clone $row; + $group_by_order_id[$row->ord_id]->a_items = []; + } + $group_by_order_id[$row->ord_id]->a_items[] = clone $row; + } + + // grouping & formatting v2 + $new_group_by_order_id = []; + $i = 0; + foreach ($group_by_order_id as $key => $row) { + $row->DT_RowIndex = ++$i; + $row->action = '-'; + $new_group_by_order_id[] = clone $row; + } + + $apiResp = Responses::success('success list ledger balance'); + $apiResp['count'] = count($new_group_by_order_id); + $apiResp['summary'] = [ + 'total_bl' => $summary->total_bl ?? 0, + 'total_in' => $summary->total_in ?? 0, + 'total_out' => $summary->total_out ?? 0, + ]; + // $apiResp['summary']['total_bl'] = $apiResp['summary']['total_in'] - $apiResp['summary']['total_out']; + $apiResp['data'] = $new_group_by_order_id; + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_finance_list_adt_items_payments(Request $req) + { + try { + $now = time(); + $input = [ + 'ord_id' => $req->ord_id, + ]; + $rulesInput = [ + // 'ord_id' => 'required|integer|not_in:0', // single + 'ord_id' => 'required|string', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $ord_ids = explode(',', $req->ord_id); + + $filter = [ + 'group_by' => 'ord_a_item.id', + 'get_user_crt' => 1, + 'get_user_rjct' => 1, + ]; + if ($req->is_access_by_admin == 1) { + $filter['is_access_by_admin'] = 1; + } + if ($ord_ids) { + // $filter['ord_id'] = $ord_ids[0]; // single + $filter['ord_ids'] = $ord_ids; + } + if ($req->is_aprv || $req->is_aprv == 0) { + $filter['is_aprv'] = $req->is_aprv; + } + + $list = Finance::listAdtItemsPayments($filter); + // foreach ($list as $key => $row) { + // $list[$key]->DT_RowIndex = $key + 1; + // $list[$key]->action = '-'; + // // $list[$key]->main_item = "Pengantaran Logistik
" . ucwords(strtolower($row->pck_prid_name)) . " - " . ucwords(strtolower($row->drop_prid_name)) . "
" . date('d F Y', $row->set_pck_at); + // } + $newList = []; + $cntK = 0; + foreach ($list as $key => $row) { + $list[$key]->action = '-'; + $isSame = 0; + foreach ($newList as $nlK => $rowL) { + // if ($req->is_access_by_admin == 1) continue; + if (!$row->group_merge_code) continue; + if ($row->group_merge_code === $rowL->group_merge_code) { + $isSame = 1; + $newList[$nlK]->childs[] = clone $list[$key]; + } + } + if ($isSame) continue; + $list[$key]->DT_RowIndex = ++$cntK; + $list[$key]->childs = []; + if ($list[$key]->a_item_type === OrdersAItems::A_TYPE_PRIMARY && $list[$key]->stts_merge !== OrdersAItems::STTS_MERGE_RESULT) { + $list[$key]->previous_termin = OrdersAItems::showAItem([ + 'ord_id' => $list[$key]->ord_id, + 'is_active' => OrdersAItems::IS_ACTIVE_YES, + 'a_item_type' => OrdersAItems::A_TYPE_PRIMARY, + 'prev_main_item_id' => $list[$key]->ord_a_item_id, + 'v_termin_id_not_zero' => 1, + 'limit' => 1, + ]); + } + $newList[] = clone $list[$key]; + } + + $apiResp = Responses::success('success list adt items payments'); + $apiResp['count'] = count($newList); + $apiResp['data'] = $newList; + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_finance_add_a_items(Request $req) + { + /** + * Case + * Jika new item => a_id == "00" + * Jika without add new master item => a_id == "0" + * Jika is adm price == yes => no input tenggat pembayaran, bukti pengajuan, tujuan pembayaran(receiver) + * Jika slc_pay_purpose == fill => input tujuan pembayaran(receiver)n + * Jika status pembayaran == lunas => upload bukti pembayaran + */ + + $url_submission_proof_base64 = []; + $url_is_paid_proof_base64 = []; + try { + $now = time(); + + $input = [ + 'ord_id' => $req->ord_id, + 'flow_type' => $req->flow_type, + 'cash_type' => $req->cash_type, + 'a_id' => $req->a_id, // 0 => without add new and master, 00 => new + 'a_name' => $req->a_name, + 'a_type' => $req->a_type, // flag + 'a_price' => $req->a_price, + 'a_price_tax_type' => $req->a_price_tax_type, + 'a_price_tax_ppn_percent' => $req->a_price_tax_ppn_percent, + 'a_price_tax_ppn_flat' => $req->a_price_tax_ppn_flat, + 'a_price_tax_pph_percent' => $req->a_price_tax_pph_percent, + 'a_price_tax_pph_flat' => $req->a_price_tax_pph_flat, + 'a_price_total_tax' => $req->a_price_total_tax, + 'a_qty' => $req->a_qty, + 'a_invc_price' => $req->a_invc_price, + 'a_invc_price_tax_type' => $req->a_invc_price_tax_type, + 'a_invc_price_tax_ppn_percent' => $req->a_invc_price_tax_ppn_percent, + 'a_invc_price_tax_ppn_flat' => $req->a_invc_price_tax_ppn_flat, + 'a_invc_price_tax_pph_percent' => $req->a_invc_price_tax_pph_percent, + 'a_invc_price_tax_pph_flat' => $req->a_invc_price_tax_pph_flat, + 'a_invc_price_total_tax' => $req->a_invc_price_total_tax, + 'is_adm_price' => $req->is_adm_price, + 'ddln_pay_at' => $req->ddln_pay_at, + 'ddln_pay_type' => $req->ddln_pay_type, // flag + 'submission_proof_base64' => $req->submission_proof_base64, + 'slc_pay_purpose' => $req->slc_pay_purpose, // fill,none + 'bank_id' => $req->bank_id, + 'bank_code' => $req->bank_code, + 'bank_short' => $req->bank_short, + 'bank_name' => $req->bank_name, + 'bank_acc_number' => $req->bank_acc_number, + 'bank_acc_name' => $req->bank_acc_name, + 'is_paid' => $req->is_paid, // flag + 'paid_proof_ref_no' => $req->paid_proof_ref_no, + 'is_paid_proof_base64' => $req->is_paid_proof_base64, + 'is_paid_at' => $req->is_paid_at, + 'is_invc_to_client' => $req->is_invc_to_client, // flag + 'is_calc_to_vdr' => $req->is_calc_to_vdr, // flag + 'crt_type' => $req->crt_type, // flag + ]; + $rulesInput = [ + 'ord_id' => 'required|integer|not_in:0', + 'flow_type' => 'required|integer|not_in:0', + 'cash_type' => 'required|integer|not_in:0', + 'a_id' => 'nullable|numeric', // 0 => without add new and master, 00 => new + 'a_name' => 'nullable|string', + 'a_type' => 'nullable|integer|min:0', + 'a_price' => 'nullable|numeric|min:0', + 'a_price_tax_type' => 'nullable|numeric|min:0', + 'a_price_tax_ppn_percent' => 'nullable|numeric|min:0', + 'a_price_tax_ppn_flat' => 'nullable|numeric|min:0', + 'a_price_tax_pph_percent' => 'nullable|numeric|min:0', + 'a_price_tax_pph_flat' => 'nullable|numeric', + 'a_price_total_tax' => 'nullable|numeric|min:0', + 'a_qty' => 'nullable|numeric|min:0', + 'a_invc_price' => 'nullable|numeric|min:0', + 'a_invc_price_tax_type' => 'nullable|numeric|min:0', + 'a_invc_price_tax_ppn_percent' => 'nullable|numeric|min:0', + 'a_invc_price_tax_ppn_flat' => 'nullable|numeric|min:0', + 'a_invc_price_tax_pph_percent' => 'nullable|numeric|min:0', + 'a_invc_price_tax_pph_flat' => 'nullable|numeric|min:0', + 'a_invc_price_total_tax' => 'nullable|numeric|min:0', + 'is_adm_price' => 'nullable|numeric', + 'ddln_pay_at' => 'nullable|numeric', + 'ddln_pay_type' => 'nullable|numeric', // flag + 'submission_proof_base64' => 'nullable|array', + 'slc_pay_purpose' => 'nullable|string', // fill,none + 'bank_id' => 'nullable|numeric', + 'bank_code' => 'nullable|numeric', + 'bank_short' => 'nullable|string', + 'bank_name' => 'nullable|string', + 'bank_acc_number' => 'nullable|numeric', + 'bank_acc_name' => 'nullable|string', + 'is_paid' => 'nullable|numeric', // flag + 'paid_proof_ref_no' => 'nullable|numeric', + 'is_paid_proof_base64' => 'nullable|array', + 'is_paid_at' => 'nullable|numeric', + 'is_invc_to_client' => 'nullable|numeric', // flag + 'is_calc_to_vdr' => 'nullable|numeric', // flag + 'crt_type' => 'nullable|numeric', // flag + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + if ($req->slc_pay_purpose == 'fill' && !$req->bank_id) { + $apiResp = Responses::bad_input('informasi penerima wajib diisi'); + return new Response($apiResp, $apiResp['meta']['code']); + } + + if ($req->is_paid == OrdersAItems::IS_PAID_YES) { + if ($req->is_paid_proof_base64 && count($req->is_paid_proof_base64) < 1) { + $apiResp = Responses::bad_input('bukti pembayaran wajib diisi'); + return new Response($apiResp, $apiResp['meta']['code']); + } + } + + if ($req->submission_proof_base64 && count($req->submission_proof_base64) < 1) { + $apiResp = Responses::bad_input('bukti pengajuan wajib diisi'); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $order = Orders::showOrder([ + 'id' => $req->ord_id, + // 'get_prefer_type_truck' => 1, + 'get_pic_zone' => 1, + // 'get_stts_checker' => 1, + // 'get_checker_data' => 1, + // 'get_checker_user' => 1, + // 'get_accidents' => 1, + 'get_client_pt' => 1, + ]); + if (count($order) < 1) { + $apiResp = Responses::not_found('order not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + if ($req->auth->role === Users::ROLE_ADMIN) { + $crt_type = AItems::CRT_TYPE_ADMIN; + } else if ($req->auth->role === Users::ROLE_FINANCE) { + $crt_type = AItems::CRT_TYPE_FINANCE; + } else { + $crt_type = 99; + } + + if ($req->a_id === "00") { + $uniqName = AItems::getByName($req->a_name, ['crt_type' => $crt_type]); + if (count($uniqName) > 0) { + $apiResp = Responses::bad_request('nama additional item sudah terdata'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + DB::beginTransaction(); + + $a_id = $req->a_id; + if ($req->a_id === "00") { + $insAItems = [ + 'name' => $req->a_name, + 'type' => $req->a_type, + 'price' => $req->a_price, + 'is_adm_price' => ($req->is_adm_price == OrdersAItems::IS_ADM_PRICE_YES) ? OrdersAItems::IS_ADM_PRICE_YES : OrdersAItems::IS_ADM_PRICE_NO, + 'is_active' => AItems::IS_ACTIVE, + 'crt' => $now, + 'crt_by' => $req->auth->uid, + 'crt_type' => $crt_type, + 'updt' => $now, + 'updt_by' => $req->auth->uid, + ]; + $a_id = AItems::add($insAItems); + $a_item = AItems::getById($a_id); + } else if ($req->a_id === "0") { + $insAItems = [ + 'name' => $req->a_name, + 'type' => $req->a_type, + 'price' => $req->a_price, + 'is_adm_price' => ($req->is_adm_price == OrdersAItems::IS_ADM_PRICE_YES) ? OrdersAItems::IS_ADM_PRICE_YES : OrdersAItems::IS_ADM_PRICE_NO, + 'is_active' => AItems::IS_ACTIVE, + 'crt' => $now, + 'crt_by' => $req->auth->uid, + 'crt_type' => $crt_type, + 'updt' => $now, + 'updt_by' => $req->auth->uid, + ]; + } else { + $a_item = AItems::getById($a_id); + } + + $insOrdersAItems = [ + 'ord_id' => $order[0]->ord_id, + 'ord_code' => $order[0]->ord_code, + 'flow_type' => $req->flow_type, + 'cash_type' => $req->cash_type, + 'a_item_type' => OrdersAItems::A_TYPE_SECONDARY, + 'ref_ord_id' => $order[0]->ord_id, + 'ref_ord_code' => $order[0]->ord_code, + 'crt' => $now, + 'crt_by' => $req->auth->uid, + 'updt' => $now, + 'updt_by' => $req->auth->uid, + ]; + // $insOrdersAItemsInvc = []; + + if ($req->a_id == "0") { + $insOrdersAItems['desc'] = $insAItems['name']; + $insOrdersAItems['unit_id'] = $a_id; + $insOrdersAItems['unit_type'] = $insAItems['type']; + $insOrdersAItems['amt_base_flat'] = $insAItems['price']; + $insOrdersAItems['unit_qty'] = $req->a_qty; + } else { + $insOrdersAItems['desc'] = $a_item[0]->name; + $insOrdersAItems['unit_id'] = $a_id; + $insOrdersAItems['unit_type'] = $a_item[0]->type; + $insOrdersAItems['amt_base_flat'] = $a_item[0]->price; + $insOrdersAItems['unit_qty'] = $req->a_qty; + } + if (isset($req->a_price_tax_type)) { + $insOrdersAItems['amt_tax_type'] = $req->a_price_tax_type; + $insOrdersAItems['amt_tax_ppn_percent'] = $req->a_price_tax_ppn_percent ?? 0; + $insOrdersAItems['amt_tax_ppn_flat'] = $req->a_price_tax_ppn_flat ?? 0; + $insOrdersAItems['amt_tax_pph_percent'] = $req->a_price_tax_pph_percent ?? 0; + $insOrdersAItems['amt_tax_pph_flat'] = $req->a_price_tax_pph_flat ?? 0; + $insOrdersAItems['amt_total_tax_flat'] = $req->a_price_total_tax ?? 0; + } + if ($req->a_price_tax_type == OrdersAItems::AMT_TAX_TYPE_INCLUDE) { + $insOrdersAItems['amt_result_flat'] = $req->a_price_total_tax; + $insOrdersAItems['amt_total_flat'] = $req->a_price_total_tax * $req->a_qty; + } else if ($req->a_price_tax_type == OrdersAItems::AMT_TAX_TYPE_WITHOUT) { + $insOrdersAItems['amt_result_flat'] = $insOrdersAItems['amt_base_flat']; + $insOrdersAItems['amt_total_flat'] = $insOrdersAItems['amt_base_flat'] * $req->a_qty; + } else { + $insOrdersAItems['amt_result_flat'] = $req->a_price_total_tax; + $insOrdersAItems['amt_total_flat'] = $req->a_price_total_tax * $req->a_qty; + } + + $req->a_invc_price = $req->a_invc_price ?? 0; + $insOrdersAItems['amt_bill_base_flat'] = $req->a_invc_price; + if (isset($req->a_invc_price_tax_type)) { + $insOrdersAItems['amt_bill_tax_type'] = $req->a_invc_price_tax_type; + $insOrdersAItems['amt_bill_tax_ppn_percent'] = $req->a_invc_price_tax_ppn_percent ?? 0; + $insOrdersAItems['amt_bill_tax_ppn_flat'] = $req->a_invc_price_tax_ppn_flat ?? 0; + $insOrdersAItems['amt_bill_tax_pph_percent'] = $req->a_invc_price_tax_pph_percent ?? 0; + $insOrdersAItems['amt_bill_tax_pph_flat'] = $req->a_invc_price_tax_pph_flat ?? 0; + $insOrdersAItems['amt_bill_total_tax_flat'] = $req->a_invc_price_total_tax ?? 0; + } + if ($req->a_invc_price_tax_type == OrdersAItems::AMT_TAX_TYPE_INCLUDE) { + $insOrdersAItems['amt_bill_result_flat'] = $insOrdersAItems['amt_bill_base_flat']; + $insOrdersAItems['amt_bill_total_flat'] = $insOrdersAItems['amt_bill_base_flat'] * $req->a_qty; + } else if ($req->a_invc_price_tax_type == OrdersAItems::AMT_TAX_TYPE_WITHOUT) { + $insOrdersAItems['amt_bill_result_flat'] = $insOrdersAItems['amt_bill_base_flat']; + $insOrdersAItems['amt_bill_total_flat'] = $insOrdersAItems['amt_bill_base_flat'] * $req->a_qty; + } else { + $insOrdersAItems['amt_bill_result_flat'] = $req->a_invc_price_total_tax; + $insOrdersAItems['amt_bill_total_flat'] = $req->a_invc_price_total_tax * $req->a_qty; + } + + $insOrdersAItems['calc_to_vdr'] = OrdersAItems::CALC_TO_VDR_NO; + if ($req->is_calc_to_vdr == OrdersAItems::CALC_TO_VDR_YES) { + $insOrdersAItems['calc_to_vdr'] = OrdersAItems::CALC_TO_VDR_YES; + $termins = OrdersTermins::listWithFilter([ + 'ord_id' => $order[0]->ord_id, + 'termin_for' => OrdersTermins::TERMIN_FOR_VENDOR, + 'termin_is_paid' => OrdersTermins::IS_PAID_NO, + 'in_stts_merge' => [ + OrdersAItems::STTS_MERGE_NO, + OrdersAItems::STTS_MERGE_RESULT, + ], + ]); + $insOrdersAItems['v_termin_id'] = 0; + $insOrdersAItems['ref_v_termin_id'] = 0; + if (count($termins) > 0) { + $insOrdersAItems['v_termin_id'] = $termins[0]->id; + $insOrdersAItems['ref_v_termin_id'] = $termins[0]->id; + } + if ($insOrdersAItems['v_termin_id'] === 0) { + $termins = OrdersTermins::listWithFilter([ + 'ord_id' => $order[0]->ord_id, + 'termin_for' => OrdersTermins::TERMIN_FOR_VENDOR, + 'in_stts_merge' => [ + OrdersAItems::STTS_MERGE_NO, + OrdersAItems::STTS_MERGE_RESULT, + ], + ]); + $insOrdersAItems['v_termin_id'] = $termins[count($termins) - 1]->id; + $insOrdersAItems['ref_v_termin_id'] = $termins[count($termins) - 1]->id; + } + $buy_price = $order[0]->buy_price + $insOrdersAItems['amt_total_flat']; + Orders::updateOrder($order[0]->ord_id, [ + 'buy_price' => $buy_price, + ]); + } + + $insOrdersAItems['invc_to_client'] = OrdersAItems::INVC_TO_CLIENT_NO; + if ($req->is_invc_to_client == OrdersAItems::INVC_TO_CLIENT_YES) { + $insOrdersAItems['invc_to_client'] = OrdersAItems::INVC_TO_CLIENT_YES; + $termins = OrdersTermins::listWithFilter([ + 'ord_id' => $order[0]->ord_id, + 'termin_for' => OrdersTermins::TERMIN_FOR_CLIENT, + 'termin_is_paid' => OrdersTermins::IS_PAID_NO, + 'in_stts_merge' => [ + OrdersAItems::STTS_MERGE_NO, + OrdersAItems::STTS_MERGE_RESULT, + ], + ]); + $insOrdersAItems['c_termin_id'] = 0; + $insOrdersAItems['ref_c_termin_id'] = 0; + if (count($termins) > 0) { + $insOrdersAItems['c_termin_id'] = $termins[0]->id; + $insOrdersAItems['ref_c_termin_id'] = $termins[0]->id; + } + if ($insOrdersAItems['c_termin_id'] === 0) { + DB::rollBack(); + $apiResp = Responses::bad_request('tidak dapat melakukan tagihan ke client, karena semua penagihan sudah close'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + // calc perpajakan + if ($termins[0]->termin_tax_type == OrdersAItems::AMT_TAX_TYPE_INCLUDE) { + $before_ppn = round($insOrdersAItems['amt_bill_base_flat'] / OrdersAItems::PPN_PERCENT_INCLUDE); + $ppn = round($insOrdersAItems['amt_bill_base_flat'] - $before_ppn); + $amt_bill_base_tax_flat = round($before_ppn); + $amt_bill_total_flat = round($amt_bill_base_tax_flat * $insOrdersAItems['unit_qty']); + + $insOrdersAItems['amt_bill_tax_type'] = $termins[0]->termin_tax_type; + $insOrdersAItems['amt_bill_tax_ppn_percent'] = OrdersAItems::PPN_PERCENT; + $insOrdersAItems['amt_bill_tax_ppn_flat'] = $ppn; + $insOrdersAItems['amt_bill_tax_pph_percent'] = 0; + $insOrdersAItems['amt_bill_tax_pph_flat'] = 0; + $insOrdersAItems['amt_bill_total_tax_flat'] = $amt_bill_base_tax_flat; + $insOrdersAItems['amt_bill_result_flat'] = $amt_bill_base_tax_flat; + $insOrdersAItems['amt_bill_total_flat'] = $amt_bill_total_flat; + } + + // if ($req->a_invc_price > 0) { + // $insOrdersAItemsInvc = [ + // 'ord_id' => $order[0]->ord_id, + // 'ord_code' => $order[0]->ord_code, + // 'flow_type' => $req->flow_type, + // 'cash_type' => $req->cash_type, + // 'a_item_type' => OrdersAItems::A_TYPE_SECONDARY, + // 'ref_ord_id' => $order[0]->ord_id, + // 'ref_ord_code' => $order[0]->ord_code, + // 'desc' => $insOrdersAItems['desc'], + // 'unit_id' => $insOrdersAItems['unit_id'], + // 'unit_type' => $insOrdersAItems['unit_type'], + // 'amt_base_flat' => $req->a_invc_price, + // 'unit_qty' => $insOrdersAItems['unit_qty'], + // 'amt_result_flat' => $req->a_invc_price, + // 'amt_total_flat' => $req->a_invc_price * $insOrdersAItems['unit_qty'], + // 'calc_to_vdr' => OrdersAItems::CALC_TO_VDR_NO, + // 'v_termin_id' => 0, + // 'ref_v_termin_id' => 0, + // 'invc_to_client' => OrdersAItems::INVC_TO_CLIENT_YES, + // 'c_termin_id' => $insOrdersAItems['c_termin_id'], + // 'ref_c_termin_id' => $insOrdersAItems['ref_c_termin_id'], + // 'crt' => $now, + // 'crt_by' => $req->auth->uid, + // 'updt' => $now, + // 'updt_by' => $req->auth->uid, + // ]; + // $insOrdersAItems['c_termin_id'] = 0; + // $insOrdersAItems['ref_c_termin_id'] = 0; + // $sell_price = $order[0]->price + $insOrdersAItemsInvc['amt_total_flat']; + // } else { + // $sell_price = $order[0]->price + $insOrdersAItems['amt_total_flat']; + // } + // cara lama sebelum perpajakan + // $sell_price = $order[0]->price + $insOrdersAItems['amt_bill_total_flat']; + // cara baru sebelum perpajakan + $sell_price = $order[0]->price + $insOrdersAItems['amt_bill_base_flat'] * $insOrdersAItems['unit_qty']; + + Orders::updateOrder($order[0]->ord_id, [ + 'price' => $sell_price, + ]); + Finance::updtChangeInvc($insOrdersAItems['c_termin_id']); + } + + $insOrdersAItems['only_client'] = OrdersAItems::ONLY_CLIENT_NO; + // $insOrdersAItemsInvc['only_client'] = OrdersAItems::ONLY_CLIENT_NO; + if ($req->only_client == OrdersAItems::ONLY_CLIENT_YES) { + $insOrdersAItems['only_client'] = OrdersAItems::ONLY_CLIENT_YES; + // $insOrdersAItemsInvc['only_client'] = OrdersAItems::ONLY_CLIENT_YES; + } + + if ($req->is_adm_price == OrdersAItems::IS_ADM_PRICE_YES) { + $insOrdersAItems['is_adm_price'] = OrdersAItems::IS_ADM_PRICE_YES; + } else { + $insOrdersAItems['ddln_pay_at'] = $req->ddln_pay_at ?? 0; + $insOrdersAItems['ddln_pay_type'] = $req->ddln_pay_type ?? OrdersAItems::DDLN_PAY_TYPE_TIME; + if ($req->slc_pay_purpose == 'fill' && $req->bank_id) { + $insOrdersAItems['bank_id'] = $req->bank_id; + $insOrdersAItems['bank_code'] = $req->bank_code; + $insOrdersAItems['bank_short_name'] = $req->bank_short; + $insOrdersAItems['bank_name'] = $req->bank_name; + $insOrdersAItems['bank_acc_name'] = $req->bank_acc_name; + $insOrdersAItems['bank_acc_number'] = $req->bank_acc_number; + } + } + + if ($req->is_paid == OrdersAItems::IS_PAID_YES) { + $insOrdersAItems['is_paid'] = OrdersAItems::IS_PAID_YES; + $insOrdersAItems['paid_ref_no'] = $req->paid_proof_ref_no; + $insOrdersAItems['paid_at'] = $now; + $insOrdersAItems['paid_by'] = $req->auth->uid; + } + + if ($req->crt_type == OrdersAItems::CRT_TYPE_SYSTEM) { + $insOrdersAItems['crt_type'] = OrdersAItems::CRT_TYPE_SYSTEM; + } else if ($req->crt_type == OrdersAItems::CRT_TYPE_FINANCE) { + $insOrdersAItems['crt_type'] = OrdersAItems::CRT_TYPE_FINANCE; + } else { + $insOrdersAItems['crt_type'] = OrdersAItems::CRT_TYPE_ADMIN; + } + // $insOrdersAItemsInvc['crt_type'] = $insOrdersAItems['crt_type']; + + $oa_id = OrdersAItems::add($insOrdersAItems); + // if (count($insOrdersAItemsInvc) > 0) { + // $insOrdersAItemsInvc['ref_ord_a_item_id'] = $oa_id; + // $oa_id2 = OrdersAItems::add($insOrdersAItemsInvc); + // } + + if ($req->is_adm_price == OrdersAItems::IS_ADM_PRICE_YES) {} else { + if ($req->submission_proof_base64 && count($req->submission_proof_base64) > 0) { + foreach ($req->submission_proof_base64 as $i => $img) { + $clearBase64 = preg_replace('/^data:(image|application)\/(png|jpg|jpeg|pdf);base64,/', '', $img); + $type = 'jpeg'; + if (strpos($img, 'application/pdf') !== false) $type = 'pdf'; + $url_submission_proof_base64[$i] = "orders/" . $order[0]->ord_id . "/a_items/" . $oa_id . "/submission/" . $req->auth->uid . "/submission_proof_img_$now" . "_" . "$i.$type"; + if (!Storage::disk('public')->put($url_submission_proof_base64[$i], base64_decode($clearBase64))) { + DB::rollBack(); + $apiResp = Responses::bad_request('gagal upload bukti pengajuan'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + } + } + + if ($req->is_paid == OrdersAItems::IS_PAID_YES) { + if ($req->is_paid_proof_base64 && count($req->is_paid_proof_base64) > 0) { + foreach ($req->is_paid_proof_base64 as $i => $img) { + $clearBase64 = preg_replace('/^data:(image|application)\/(png|jpg|jpeg|pdf);base64,/', '', $img); + $type = 'jpeg'; + if (strpos($img, 'application/pdf') !== false) $type = 'pdf'; + $url_is_paid_proof_base64[$i] = "orders/" . $order[0]->ord_id . "/a_items/" . $oa_id . "/payments/" . $req->auth->uid . "/payments_proof_img_$now" . "_" . "$i.$type"; + if (!Storage::disk('public')->put($url_is_paid_proof_base64[$i], base64_decode($clearBase64))) { + DB::rollBack(); + $apiResp = Responses::bad_request('gagal upload bukti pembayaran'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + } + } + + OrdersAItems::updt($oa_id, [ + 'img_proof_submission' => (count($url_submission_proof_base64) > 0) ? json_encode($url_submission_proof_base64) : null, + 'img_proof_payment' => (count($url_is_paid_proof_base64) > 0) ? json_encode($url_is_paid_proof_base64) : null, + ]); + // OrdersAItems::updt($oa_id2, [ + // 'img_proof_submission' => (count($url_submission_proof_base64) > 0) ? json_encode($url_submission_proof_base64) : null, + // 'img_proof_payment' => (count($url_is_paid_proof_base64) > 0) ? json_encode($url_is_paid_proof_base64) : null, + // ]); + + $apiResp = Responses::created('success add item'); + + DB::commit(); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + DB::rollBack(); + if (count($url_submission_proof_base64) > 0) { + foreach ($url_submission_proof_base64 as $path) { + Storage::disk('public')->delete($path); + } + } + if (count($url_is_paid_proof_base64) > 0) { + foreach ($url_is_paid_proof_base64 as $path) { + Storage::disk('public')->delete($path); + } + } + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_finance_show_a_item(Request $req, $ord_a_item_id) + { + try { + $now = time(); + + $input = [ + 'ord_a_item_id' => $ord_a_item_id, + ]; + $rulesInput = [ + 'ord_a_item_id' => 'required|integer|not_in:0', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $filter = [ + 'ord_a_item_id' => $ord_a_item_id, + 'get_user_crt' => 1, + 'get_user_rjct' => 1, + ]; + $item = OrdersAItems::showAItem($filter); + if (count($item) < 1) { + $apiResp = Responses::not_found('item not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + if ($item[0]->group_merge_code) { + $filter = [ + 'exclude_ord_a_item_id' => $ord_a_item_id, + 'group_merge_code' => $item[0]->group_merge_code, + 'get_user_crt' => 1, + 'get_user_rjct' => 1, + ]; + $childs = OrdersAItems::showAItem($filter); + $item[0]->childs = $childs; + } + + $apiResp = Responses::success('success get detail item'); + $apiResp['data'] = $item[0]; + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_finance_pay_a_items(Request $req, $ord_a_item_id) + { + $url_up_paid_proof_base64 = []; + try { + $now = time(); + + $input = [ + 'ord_a_item_id' => $ord_a_item_id, + // 'group_merge_code' => $req->group_merge_code, + 'up_paid_ref_no' => $req->up_paid_ref_no, + 'up_paid_proof_base64' => $req->up_paid_proof_base64, + ]; + $rulesInput = [ + 'ord_a_item_id' => 'required|integer|not_in:0', + // 'group_merge_code' => 'nullable|integer|not_in:0', + 'up_paid_ref_no' => 'required|numeric|min:0', + 'up_paid_proof_base64' => 'nullable|array', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + if (!$req->up_paid_proof_base64 || count($req->up_paid_proof_base64) < 1) { + $apiResp = Responses::bad_input('bukti pembayaran wajib diisi'); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $a_item = OrdersAItems::showAItemById($ord_a_item_id); + if (count($a_item) < 1) { + $apiResp = Responses::not_found('item not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + $order = Orders::showOrder(['id' => $a_item[0]->ord_id]); + + DB::beginTransaction(); + + $updtOrdersAItems = [ + 'paid_ref_no' => $req->up_paid_ref_no, + 'is_paid' => OrdersAItems::IS_PAID_YES, + 'updt' => $now, + 'updt_by' => $req->auth->uid, + 'paid_at' => $now, + 'paid_by' => $req->auth->uid, + ]; + + if ($a_item[0]->v_termin_id !== 0 && $a_item[0]->a_item_type === OrdersAItems::A_TYPE_PRIMARY) { + $termin = OrdersTermins::getById($a_item[0]->v_termin_id); + if ($termin[0]->termin_is_paid !== OrdersTermins::IS_PAID_YES) { + OrdersTermins::updt($a_item[0]->v_termin_id, [ + 'termin_is_paid' => OrdersTermins::IS_PAID_YES, + 'termin_paid_at' => $now, + 'termin_paid_by' => $req->auth->uid, + 'updt' => $now, + 'updt_by' => $req->auth->uid, + ]); + } + } + + if ($req->up_paid_proof_base64 && count($req->up_paid_proof_base64) > 0) { + foreach ($req->up_paid_proof_base64 as $i => $img) { + $clearBase64 = preg_replace('/^data:(image|application)\/(png|jpg|jpeg|pdf);base64,/', '', $img); + $type = 'jpeg'; + if (strpos($img, 'application/pdf') !== false) $type = 'pdf'; + $url_up_paid_proof_base64[$i] = "orders/" . $a_item[0]->ord_id . "/a_items/" . $ord_a_item_id . "/payments/" . $req->auth->uid . "/payments_proof_img_$now" . "_" . "$i.$type"; + if (!Storage::disk('public')->put($url_up_paid_proof_base64[$i], base64_decode($clearBase64))) { + DB::rollBack(); + $apiResp = Responses::bad_request('gagal upload bukti pembayaran'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + } + $updtOrdersAItems['img_proof_payment'] = (count($url_up_paid_proof_base64) > 0) ? json_encode($url_up_paid_proof_base64) : null; + + OrdersAItems::updt($ord_a_item_id, $updtOrdersAItems); + + $updtOrd = []; + + $checkPaidOff = Finance::checkJustPaidOff($a_item[0]->ord_id); + if ($checkPaidOff['invc_paid'] === 1) { + $updtOrd['is_invc_paid'] = Orders::IS_PAID_YES; + $updtOrd['invc_paid_at'] = $now; + } + if ($checkPaidOff['vdr_paid'] === 1) { + $updtOrd['is_vdr_paid'] = Orders::IS_PAID_YES; + $updtOrd['vdr_paid_at'] = $now; + // kalau vhc & driver bisa order lagi setelah pembayaran lunas + // Vehicles::updateVehicle($order[0]->vhc_id, [ + // 'is_in_ord' => Vehicles::IN_ORD_NO, + // 'ord_id' => 0, + // 'ord_code' => 0, + // ]); + // Drivers::updateDriver($order[0]->drv_id, [ + // 'is_in_ord' => Drivers::IN_ORD_NO, + // 'ord_id' => 0, + // 'ord_code' => 0, + // ]); + } + if ($checkPaidOff['invc_vdr_paid'] === 1 || $checkPaidOff['invc_vdr_paid'] === 2) { + if ($order[0]->status === Orders::STTS_DROP || $order[0]->status === Orders::STTS_CLIENT_PAY || $order[0]->status === Orders::STTS_VENDOR_PAYED) { + $updtOrd['status'] = Orders::STTS_CLOSE; + } + } + + if (count($updtOrd) > 0) { + Orders::updateOrder($a_item[0]->ord_id, $updtOrd); + } + + // $currentBill = Finance::listBillings(['ord_id' => $a_item[0]->ord_id]); + // $currentPay = Finance::listPayments(['ord_id' => $a_item[0]->ord_id]); + // if ($currentBill[0]->total_billing === $currentBill[0]->total_payed || $currentPay[0]->total_payment === $currentPay[0]->total_payed) { + // $updtOrd = []; + // if ($currentBill[0]->total_billing === $currentBill[0]->total_payed) { + // if ($order[0]->is_invc_paid !== Orders::IS_PAID_YES) { + // $updtOrd['is_invc_paid'] = Orders::IS_PAID_YES; + // $updtOrd['invc_paid_at'] = $now; + // } + // } + // if ($currentPay[0]->total_payment === $currentPay[0]->total_payed) { + // if ($order[0]->is_vdr_paid !== Orders::IS_PAID_YES) { + // $updtOrd['is_vdr_paid'] = Orders::IS_PAID_YES; + // $updtOrd['vdr_paid_at'] = $now; + // Vehicles::updateVehicle($order[0]->vhc_id, [ + // 'is_in_ord' => Vehicles::IN_ORD_NO, + // 'ord_id' => 0, + // 'ord_code' => 0, + // ]); + // Drivers::updateDriver($order[0]->drv_id, [ + // 'is_in_ord' => Drivers::IN_ORD_NO, + // 'ord_id' => 0, + // 'ord_code' => 0, + // ]); + // } + // } + // if ($currentBill[0]->total_billing === $currentBill[0]->total_payed && $currentPay[0]->total_payment === $currentPay[0]->total_payed) { + // $updtOrd['status'] = Orders::STTS_CLOSE; + // } + // if (count($updtOrd) > 0) { + // Orders::updateOrder($a_item[0]->ord_id, $updtOrd); + // } + // } + + $apiResp = Responses::success('success pay item'); + + DB::commit(); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + DB::rollBack(); + if (count($url_up_paid_proof_base64) > 0) { + foreach ($url_up_paid_proof_base64 as $path) { + Storage::disk('public')->delete($path); + } + } + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_finance_updt_a_items(Request $req, $ord_a_item_id) + { + /** + * Case + * Jika without add updt master item => a_id == "0" || "00" + * Jika is adm price == yes => no input tenggat pembayaran, bukti pengajuan, tujuan pembayaran(receiver) + * Jika slc_pay_purpose == fill => input tujuan pembayaran(receiver)n + * Jika status pembayaran == lunas => upload bukti pembayaran + */ + + $url_submission_proof_base64 = []; + $url_is_paid_proof_base64 = []; + try { + $now = time(); + + $input = [ + 'ord_a_item_id' => $req->ord_a_item_id, + 'flow_type' => $req->flow_type, + 'cash_type' => $req->cash_type, + 'a_id' => $req->a_id, // 0 => without update new and master, 00 => new + 'a_name' => $req->a_name, + 'a_type' => $req->a_type, // flag + 'a_price' => $req->a_price, + 'a_qty' => $req->a_qty, + 'a_invc_price' => $req->a_invc_price, + 'is_adm_price' => $req->is_adm_price, + 'ddln_pay_at' => $req->ddln_pay_at, + 'ddln_pay_type' => $req->ddln_pay_type, // flag + 'submission_proof_base64' => $req->submission_proof_base64, + 'slc_pay_purpose' => $req->slc_pay_purpose, // fill,none + 'bank_id' => $req->bank_id, + 'bank_code' => $req->bank_code, + 'bank_short' => $req->bank_short, + 'bank_name' => $req->bank_name, + 'bank_acc_number' => $req->bank_acc_number, + 'bank_acc_name' => $req->bank_acc_name, + 'is_paid' => $req->is_paid, // flag + 'is_paid_proof_base64' => $req->is_paid_proof_base64, + 'is_paid_at' => $req->is_paid_at, + 'is_invc_to_client' => $req->is_invc_to_client, // flag + 'is_calc_to_vdr' => $req->is_calc_to_vdr, // flag + 'crt_type' => $req->crt_type, // flag + ]; + $rulesInput = [ + 'ord_a_item_id' => 'required|integer|not_in:0', + 'flow_type' => 'required|integer|not_in:0', + 'cash_type' => 'required|integer|not_in:0', + 'a_id' => 'nullable|numeric', // 0 => without update new and master, 00 => new + 'a_name' => 'nullable|string', + 'a_type' => 'nullable|integer|min:0', + 'a_price' => 'nullable|numeric|min:0', + 'a_qty' => 'nullable|numeric|min:0', + 'a_invc_price' => 'nullable|numeric|min:0', + 'is_adm_price' => 'nullable|numeric', + 'ddln_pay_at' => 'nullable|numeric', + 'ddln_pay_type' => 'nullable|numeric', // flag + 'submission_proof_base64' => 'nullable|array', + 'slc_pay_purpose' => 'nullable|string', // fill,none + 'bank_id' => 'nullable|numeric', + 'bank_code' => 'nullable|numeric', + 'bank_short' => 'nullable|string', + 'bank_name' => 'nullable|string', + 'bank_acc_number' => 'nullable|numeric', + 'bank_acc_name' => 'nullable|string', + 'is_paid' => 'nullable|numeric', // flag + 'is_paid_proof_base64' => 'nullable|array', + 'is_paid_at' => 'nullable|numeric', + 'is_invc_to_client' => 'nullable|numeric', // flag + 'is_calc_to_vdr' => 'nullable|numeric', // flag + 'crt_type' => 'nullable|numeric', // flag + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + if ($req->slc_pay_purpose == 'fill' && !$req->bank_id) { + $apiResp = Responses::bad_input('informasi penerima wajib diisi'); + return new Response($apiResp, $apiResp['meta']['code']); + } + + if ($req->is_paid == OrdersAItems::IS_PAID_YES) { + if ($req->is_paid_proof_base64 && count($req->is_paid_proof_base64) < 1) { + $apiResp = Responses::bad_input('bukti pembayaran wajib diisi'); + return new Response($apiResp, $apiResp['meta']['code']); + } + } + + if ($req->submission_proof_base64 && count($req->submission_proof_base64) < 1) { + $apiResp = Responses::bad_input('bukti pengajuan wajib diisi'); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $orderAItem = OrdersAItems::getById($ord_a_item_id); + if (count($orderAItem) < 1) { + $apiResp = Responses::not_found('item not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + $order = Orders::showOrder([ + 'id' => $req->ord_id, + // 'get_prefer_type_truck' => 1, + 'get_pic_zone' => 1, + // 'get_stts_checker' => 1, + // 'get_checker_data' => 1, + // 'get_checker_user' => 1, + // 'get_accidents' => 1, + 'get_client_pt' => 1, + ]); + if (count($order) < 1) { + $apiResp = Responses::not_found('order not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + // if ($req->a_id === "00") { + // $filterUniqName = []; + // if ($req->auth->role === Users::ROLE_ADMIN) { + // $filterUniqName['crt_type'] = AItems::CRT_TYPE_ADMIN; + // } else if ($req->auth->role === Users::ROLE_FINANCE) { + // $filterUniqName['crt_type'] = AItems::CRT_TYPE_FINANCE; + // } else { + // $filterUniqName['crt_type'] = 99; + // } + + // $uniqName = AItems::getByName($req->a_name, $filterUniqName); + // if (count($uniqName) > 0) { + // $apiResp = Responses::bad_request('nama additional item sudah terdata'); + // return (new Response($apiResp, $apiResp['meta']['code'])); + // } + // } + + DB::beginTransaction(); + + $a_id = $req->a_id; + if ($req->a_id == "0" || $req->a_id == "00") { + $updtAItems = [ + 'name' => $req->a_name, + 'type' => $req->a_type, + 'price' => $req->a_price, + 'is_adm_price' => ($req->is_adm_price == OrdersAItems::IS_ADM_PRICE_YES) ? OrdersAItems::IS_ADM_PRICE_YES : OrdersAItems::IS_ADM_PRICE_NO, + 'is_active' => AItems::IS_ACTIVE, + 'updt' => $now, + 'updt_by' => $req->auth->uid, + ]; + } else { + $updtAItems = [ + 'name' => $req->a_name, + 'type' => $req->a_type, + 'price' => $req->a_price, + 'is_adm_price' => ($req->is_adm_price == OrdersAItems::IS_ADM_PRICE_YES) ? OrdersAItems::IS_ADM_PRICE_YES : OrdersAItems::IS_ADM_PRICE_NO, + 'is_active' => AItems::IS_ACTIVE, + 'updt' => $now, + 'updt_by' => $req->auth->uid, + ]; + AItems::updt($a_id, $updtAItems); + } + + $updtOrdersAItems = [ + 'ord_id' => $orderAItem[0]->ord_id, + 'ord_code' => $orderAItem[0]->ord_code, + 'flow_type' => $req->flow_type, + 'cash_type' => $req->cash_type, + 'a_item_type' => OrdersAItems::A_TYPE_SECONDARY, + 'desc' => $updtAItems['name'], + 'unit_id' => $a_id, + 'unit_type' => $updtAItems['type'], + 'amt_base_flat' => $updtAItems['price'], + 'unit_qty' => $req->a_qty, + 'amt_result_flat' => $updtAItems['price'], + 'amt_total_flat' => $updtAItems['price'] * $req->a_qty, + 'updt' => $now, + 'updt_by' => $req->auth->uid, + ]; + + $req->a_invc_price = $req->a_invc_price ?? 0; + $updtOrdersAItems['amt_bill_base_flat'] = $req->a_invc_price; + $updtOrdersAItems['amt_bill_result_flat'] = $req->a_invc_price; + $updtOrdersAItems['amt_bill_total_flat'] = $req->a_invc_price * $req->a_qty; + + $updtOrdersAItems['calc_to_vdr'] = OrdersAItems::CALC_TO_VDR_NO; + $updtOrdersAItems['v_termin_id'] = 0; + $updtOrdersAItems['ref_v_termin_id'] = 0; + if ($req->is_calc_to_vdr == OrdersAItems::CALC_TO_VDR_YES) { + $updtOrdersAItems['calc_to_vdr'] = OrdersAItems::CALC_TO_VDR_YES; + $updtOrdersAItems['v_termin_id'] = $orderAItem[0]->v_termin_id; + $updtOrdersAItems['ref_v_termin_id'] = $orderAItem[0]->ref_v_termin_id; + if ($orderAItem[0]->calc_to_vdr === OrdersAItems::CALC_TO_VDR_YES) { + $buy_price = $order[0]->buy_price - $orderAItem[0]->amt_total_flat + $updtOrdersAItems['amt_total_flat']; + Orders::updateOrder($order[0]->ord_id, [ + 'buy_price' => $buy_price, + ]); + } else { + $buy_price = $order[0]->buy_price + $updtOrdersAItems['amt_total_flat']; + Orders::updateOrder($order[0]->ord_id, [ + 'buy_price' => $buy_price, + ]); + } + } else { + if ($orderAItem[0]->calc_to_vdr === OrdersAItems::CALC_TO_VDR_YES) { + $buy_price = $order[0]->buy_price - $orderAItem[0]->amt_total_flat; + Orders::updateOrder($order[0]->ord_id, [ + 'buy_price' => $buy_price, + ]); + } + } + + $updtOrdersAItems['invc_to_client'] = OrdersAItems::INVC_TO_CLIENT_NO; + $updtOrdersAItems['c_termin_id'] = 0; + $updtOrdersAItems['ref_c_termin_id'] = 0; + if ($req->is_invc_to_client == OrdersAItems::INVC_TO_CLIENT_YES) { + $updtOrdersAItems['invc_to_client'] = OrdersAItems::INVC_TO_CLIENT_YES; + // $updtOrdersAItems['c_termin_id'] = $orderAItem[0]->c_termin_id; + // $updtOrdersAItems['ref_c_termin_id'] = $orderAItem[0]->ref_c_termin_id; + if ($orderAItem[0]->c_termin_id === 0) { + $termins = OrdersTermins::listWithFilter([ + 'termin_for' => OrdersTermins::TERMIN_FOR_CLIENT, + 'termin_is_paid' => OrdersTermins::IS_PAID_NO, + 'ord_id' => $order[0]->ord_id, + 'in_stts_merge' => [ + OrdersAItems::STTS_MERGE_NO, + OrdersAItems::STTS_MERGE_RESULT, + ], + ]); + $updtOrdersAItems['c_termin_id'] = 0; + $updtOrdersAItems['ref_c_termin_id'] = 0; + if (count($termins) > 0) { + $updtOrdersAItems['c_termin_id'] = $termins[0]->id; + $updtOrdersAItems['ref_c_termin_id'] = $termins[0]->id; + } + } else { + $updtOrdersAItems['c_termin_id'] = $orderAItem[0]->c_termin_id; + $updtOrdersAItems['ref_c_termin_id'] = $orderAItem[0]->ref_c_termin_id; + } + if ($updtOrdersAItems['c_termin_id'] === 0) { + DB::rollBack(); + $apiResp = Responses::bad_request('tidak dapat melakukan tagihan ke client, karena semua penagihan sudah close'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + if ($orderAItem[0]->invc_to_client === OrdersAItems::INVC_TO_CLIENT_YES) { + $sell_price = $order[0]->price - $orderAItem[0]->amt_bill_total_flat + $updtOrdersAItems['amt_bill_total_flat']; + Orders::updateOrder($order[0]->ord_id, [ + 'price' => $sell_price, + ]); + } else { + $sell_price = $order[0]->price + $updtOrdersAItems['amt_bill_total_flat']; + Orders::updateOrder($order[0]->ord_id, [ + 'price' => $sell_price, + ]); + } + Finance::updtChangeInvc($updtOrdersAItems['c_termin_id']); + } else { + if ($orderAItem[0]->invc_to_client === OrdersAItems::INVC_TO_CLIENT_YES) { + $sell_price = $order[0]->price - $orderAItem[0]->amt_bill_total_flat; + Orders::updateOrder($order[0]->ord_id, [ + 'price' => $sell_price, + ]); + Finance::updtChangeInvc($orderAItem[0]->c_termin_id); + } + } + + $updtOrdersAItems['only_client'] = OrdersAItems::ONLY_CLIENT_NO; + if ($req->only_client == OrdersAItems::ONLY_CLIENT_YES) { + $updtOrdersAItems['only_client'] = OrdersAItems::ONLY_CLIENT_YES; + } + + if ($req->is_adm_price == OrdersAItems::IS_ADM_PRICE_YES) { + $updtOrdersAItems['is_adm_price'] = OrdersAItems::IS_ADM_PRICE_YES; + } else { + $updtOrdersAItems['ddln_pay_at'] = $req->ddln_pay_at ?? 0; + $updtOrdersAItems['ddln_pay_type'] = $req->ddln_pay_type ?? OrdersAItems::DDLN_PAY_TYPE_TIME; + if ($req->slc_pay_purpose == 'fill' && $req->bank_id) { + $updtOrdersAItems['bank_id'] = $req->bank_id; + $updtOrdersAItems['bank_code'] = $req->bank_code; + $updtOrdersAItems['bank_short_name'] = $req->bank_short; + $updtOrdersAItems['bank_name'] = $req->bank_name; + $updtOrdersAItems['bank_acc_name'] = $req->bank_acc_name; + $updtOrdersAItems['bank_acc_number'] = $req->bank_acc_number; + } + } + + if ($req->is_paid == OrdersAItems::IS_PAID_YES) { + $updtOrdersAItems['is_paid'] = OrdersAItems::IS_PAID_YES; + $updtOrdersAItems['paid_at'] = $now; + $updtOrdersAItems['paid_by'] = $req->auth->uid; + } + + // if ($req->crt_type == OrdersAItems::CRT_TYPE_SYSTEM) { + // $updtOrdersAItems['crt_type'] = OrdersAItems::CRT_TYPE_SYSTEM; + // } else if ($req->crt_type == OrdersAItems::CRT_TYPE_FINANCE) { + // $updtOrdersAItems['crt_type'] = OrdersAItems::CRT_TYPE_FINANCE; + // } else { + // $updtOrdersAItems['crt_type'] = OrdersAItems::CRT_TYPE_ADMIN; + // } + + if ($req->is_adm_price == OrdersAItems::IS_ADM_PRICE_YES) {} else { + if ($req->submission_proof_base64 && count($req->submission_proof_base64) > 0) { + foreach ($req->submission_proof_base64 as $i => $img) { + $clearBase64 = preg_replace('/^data:(image|application)\/(png|jpg|jpeg|pdf);base64,/', '', $img); + $type = 'jpeg'; + if (strpos($img, 'application/pdf') !== false) $type = 'pdf'; + $url_submission_proof_base64[$i] = "orders/" . $orderAItem[0]->ord_id . "/a_items/" . $ord_a_item_id . "/submission/" . $req->auth->uid . "/submission_proof_img_$now" . "_" . "$i.$type"; + if (!Storage::disk('public')->put($url_submission_proof_base64[$i], base64_decode($clearBase64))) { + DB::rollBack(); + $apiResp = Responses::bad_request('gagal upload bukti pengajuan'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + } + } + + if ($req->is_paid == OrdersAItems::IS_PAID_YES) { + if ($req->is_paid_proof_base64 && count($req->is_paid_proof_base64) > 0) { + foreach ($req->is_paid_proof_base64 as $i => $img) { + $clearBase64 = preg_replace('/^data:(image|application)\/(png|jpg|jpeg|pdf);base64,/', '', $img); + $type = 'jpeg'; + if (strpos($img, 'application/pdf') !== false) $type = 'pdf'; + $url_is_paid_proof_base64[$i] = "orders/" . $orderAItem[0]->ord_id . "/a_items/" . $ord_a_item_id . "/payments/" . $req->auth->uid . "/payments_proof_img_$now" . "_" . "$i.$type"; + if (!Storage::disk('public')->put($url_is_paid_proof_base64[$i], base64_decode($clearBase64))) { + DB::rollBack(); + $apiResp = Responses::bad_request('gagal upload bukti pembayaran'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + } + } + + if (count($url_submission_proof_base64) > 0) { + $updtOrdersAItems['img_proof_submission'] = json_encode($url_submission_proof_base64); + } + if (count($url_is_paid_proof_base64) > 0) { + $updtOrdersAItems['img_proof_payment'] = json_encode($url_is_paid_proof_base64); + } + + OrdersAItems::updt($ord_a_item_id, $updtOrdersAItems); + + $apiResp = Responses::success('success update item'); + + DB::commit(); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + DB::rollBack(); + if (count($url_submission_proof_base64) > 0) { + foreach ($url_submission_proof_base64 as $path) { + Storage::disk('public')->delete($path); + } + } + if (count($url_is_paid_proof_base64) > 0) { + foreach ($url_is_paid_proof_base64 as $path) { + Storage::disk('public')->delete($path); + } + } + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_finance_del_a_items(Request $req, $ord_a_item_id) + { + /** + * $req->is_del => + * 1. delete submission item from admin + * 2. delete item from detail pembayaran menu finance + * 3. delete item from detail penagihan menu finance + */ + try { + $now = time(); + + $input = [ + 'ord_a_item_id' => $req->ord_a_item_id, + 'is_del' => $req->is_del, + ]; + $rulesInput = [ + 'ord_a_item_id' => 'required|integer|not_in:0', + 'is_del' => 'required|integer|not_in:0', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $orderAItem = OrdersAItems::getById($ord_a_item_id); + if (count($orderAItem) < 1) { + $apiResp = Responses::not_found('item not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + $order = Orders::showOrder([ + 'id' => $orderAItem[0]->ord_id, + // 'get_prefer_type_truck' => 1, + 'get_pic_zone' => 1, + // 'get_stts_checker' => 1, + // 'get_checker_data' => 1, + // 'get_checker_user' => 1, + // 'get_accidents' => 1, + 'get_client_pt' => 1, + ]); + if (count($order) < 1) { + $apiResp = Responses::not_found('order not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + if ($req->is_del == 1 || $req->is_del == 2) { + if ($orderAItem[0]->is_paid == OrdersAItems::IS_PAID_YES) { + $apiResp = Responses::bad_request('tidak bisa dihapus status pembayaran sudah lunas'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + // if $req->is_del == 3 + if ($orderAItem[0]->is_bill_paid == OrdersAItems::IS_PAID_YES) { + $apiResp = Responses::bad_request('tidak bisa dihapus status penagihan sudah lunas'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + DB::beginTransaction(); + + if ($req->is_del == 1 || $req->is_del == 2) { + $updtOrdersAItems = [ + 'dlt' => $now, + 'dlt_by' => $req->auth->uid, + ]; + if ($orderAItem[0]->invc_to_client === OrdersAItems::INVC_TO_CLIENT_YES) { + $sell_price = $order[0]->price - $orderAItem[0]->amt_bill_total_flat; + Orders::updateOrder($order[0]->ord_id, [ + 'price' => $sell_price, + ]); + Finance::updtChangeInvc($orderAItem[0]->c_termin_id); + } + if ($orderAItem[0]->calc_to_vdr === OrdersAItems::CALC_TO_VDR_YES) { + $buy_price = $order[0]->buy_price - $orderAItem[0]->amt_total_flat; + Orders::updateOrder($order[0]->ord_id, [ + 'buy_price' => $buy_price, + ]); + } + OrdersAItems::updt($ord_a_item_id, $updtOrdersAItems); + } else if ($req->is_del == 3) { + if ($orderAItem[0]->calc_to_vdr === OrdersAItems::CALC_TO_VDR_YES) { + $updtOrdersAItems = [ + 'invc_to_client' => OrdersAItems::INVC_TO_CLIENT_NO, + 'updt' => $now, + 'updt_by' => $req->auth->uid, + ]; + $updtOrdersAItems['c_termin_id'] = 0; + $updtOrdersAItems['ref_c_termin_id'] = 0; + } else { + $updtOrdersAItems = [ + 'dlt' => $now, + 'dlt_by' => $req->auth->uid, + ]; + $buy_price = $order[0]->buy_price - $orderAItem[0]->amt_total_flat; + Orders::updateOrder($order[0]->ord_id, [ + 'buy_price' => $buy_price, + ]); + } + $sell_price = $order[0]->price - $orderAItem[0]->amt_bill_total_flat; + Orders::updateOrder($order[0]->ord_id, [ + 'price' => $sell_price, + ]); + OrdersAItems::updt($ord_a_item_id, $updtOrdersAItems); + Finance::updtChangeInvc($orderAItem[0]->c_termin_id); + } + + $apiResp = Responses::success('success delete item'); + + DB::commit(); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_finance_reject_a_items(Request $req, $ord_a_item_id) + { + try { + $now = time(); + + $input = [ + 'ord_a_item_id' => $ord_a_item_id, + ]; + $rulesInput = [ + 'ord_a_item_id' => 'required|integer|not_in:0', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $orderAItem = OrdersAItems::getById($ord_a_item_id); + if (count($orderAItem) < 1) { + $apiResp = Responses::not_found('item not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + $order = Orders::showOrder([ + 'id' => $orderAItem[0]->ord_id, + // 'get_prefer_type_truck' => 1, + 'get_pic_zone' => 1, + // 'get_stts_checker' => 1, + // 'get_checker_data' => 1, + // 'get_checker_user' => 1, + // 'get_accidents' => 1, + 'get_client_pt' => 1, + ]); + if (count($order) < 1) { + $apiResp = Responses::not_found('order not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + if ($orderAItem[0]->is_paid == OrdersAItems::IS_PAID_YES) { + $apiResp = Responses::bad_request('tidak bisa ditolak status pembayaran sudah lunas'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + if ($orderAItem[0]->is_bill_paid == OrdersAItems::IS_PAID_YES) { + $apiResp = Responses::bad_request('tidak bisa ditolak status penagihan sudah lunas'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + DB::beginTransaction(); + + $updtOrdersAItems = []; + + if ($orderAItem[0]->invc_to_client === OrdersAItems::INVC_TO_CLIENT_YES) { + $updtOrdersAItems['is_bill_aprv'] = OrdersAItems::IS_APRV_NO; + $updtOrdersAItems['rjct_bill_at'] = $now; + $updtOrdersAItems['rjct_bill_by'] = $req->auth->uid; + $sell_price = $order[0]->price - $orderAItem[0]->amt_bill_total_flat; + Orders::updateOrder($order[0]->ord_id, [ + 'price' => $sell_price, + ]); + + Finance::updtChangeInvc($orderAItem[0]->c_termin_id); + } else { + $updtOrdersAItems['c_termin_id'] = 0; + $updtOrdersAItems['ref_c_termin_id'] = 0; + } + + if ($orderAItem[0]->calc_to_vdr === OrdersAItems::CALC_TO_VDR_YES) { + $updtOrdersAItems['is_aprv'] = OrdersAItems::IS_APRV_NO; + $updtOrdersAItems['rjct_at'] = $now; + $updtOrdersAItems['rjct_by'] = $req->auth->uid; + $buy_price = $order[0]->buy_price - $orderAItem[0]->amt_total_flat; + Orders::updateOrder($order[0]->ord_id, [ + 'buy_price' => $buy_price, + ]); + } else { + $updtOrdersAItems['v_termin_id'] = 0; + $updtOrdersAItems['ref_v_termin_id'] = 0; + } + + OrdersAItems::updt($ord_a_item_id, $updtOrdersAItems); + + $apiResp = Responses::success('success reject item'); + + DB::commit(); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + /** + * how merger work + * pembayaran yang bisa di merge: status lunas/tidak, belum pernah di merge, item additional(not main item) + * pembayaran yang tidak bisa di merge: diarsipkan, bekas merge dan selain dari syarat ditas + * jangan lupa dikurangin harganya dengan t_orders.buy_price / t_orders.price dan diupdate + * buat row t_orders_a_items baru dengan data yang sama, dengan kriteria berikut: + * - kecuali t_orders_a_items[ord_code/id,c_termin/v_termin] adalah baru, kolom ref order mereferensi ke item sebelumnya, namun ref termin adalah data baru + * - crt_type dibuat dari finance, begitupun dengan usernya + * - is_merge jadi 1, merge_to_a_items_id(item baru dari hasil merge) + * jika status pembayaran lunas maka tidak bisa dirubah + * setiap ada perubahan di merger yang baru, di arsip pembayaran(order lama,sebelum merger) tidak terubah/terkalulasi jika status pembayaran lunas + */ + public function api_finance_merger_a_items(Request $req, $ord_a_item_id) + { + try { + $now = time(); + + $input = [ + 'ord_a_item_id' => $ord_a_item_id, + 'mrg_to_ord_code' => $req->mrg_to_ord_code, + 'mrg_to_ord_id' => $req->mrg_to_ord_id, + ]; + $rulesInput = [ + 'ord_a_item_id' => 'required|integer|not_in:0', + 'mrg_to_ord_code' => 'required|string|min:5', + 'mrg_to_ord_id' => 'nullable|integer|not_in:0', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $mergeFromAItem = OrdersAItems::getById($ord_a_item_id); + if (count($mergeFromAItem) < 1) { + $apiResp = Responses::not_found('item not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + $mergeFromOrder = Orders::showOrder([ + 'id' => $mergeFromAItem[0]->ord_id, + // 'get_prefer_type_truck' => 1, + // 'get_pic_zone' => 1, + // 'get_stts_checker' => 1, + // 'get_checker_data' => 1, + // 'get_checker_user' => 1, + // 'get_accidents' => 1, + // 'get_client_pt' => 1, + ]); + if (count($mergeFromOrder) < 1) { + $apiResp = Responses::not_found('order not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + $mergeToOrder = Orders::showOrder([ + 'code' => $req->mrg_to_ord_code, + // 'get_prefer_type_truck' => 1, + // 'get_pic_zone' => 1, + // 'get_stts_checker' => 1, + // 'get_checker_data' => 1, + // 'get_checker_user' => 1, + // 'get_accidents' => 1, + // 'get_client_pt' => 1, + ]); + if (count($mergeToOrder) < 1) { + $apiResp = Responses::not_found('order not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + DB::beginTransaction(); + + $updtMergeFromAItems = [ + 'is_merge_to' => OrdersAItems::IS_MERGE_YES, + // 'merge_to_a_id' => 0, + 'merge_to_ord_id' => $mergeToOrder[0]->ord_id, + 'merge_to_ord_code' => $mergeToOrder[0]->ord_code, + 'merge_to_at' => $now, + 'merge_to_by' => $req->auth->uid, + ]; + $insMergeToAItem = [ + 'ord_id' => $mergeToOrder[0]->ord_id, + 'ord_code' => $mergeToOrder[0]->ord_code, + 'flow_type' => $mergeFromAItem[0]->flow_type, + 'cash_type' => $mergeFromAItem[0]->cash_type, + // 'v_termin_id' => $mergeFromAItem[0]->v_termin_id, + // 'c_termin_id' => $mergeFromAItem[0]->c_termin_id, + 'a_item_type' => $mergeFromAItem[0]->a_item_type, + 'desc' => $mergeFromAItem[0]->desc, + 'unit_id' => $mergeFromAItem[0]->unit_id, + 'unit_type' => $mergeFromAItem[0]->unit_type, + 'unit_qty' => $mergeFromAItem[0]->unit_qty, + 'amt_base_flat' => $mergeFromAItem[0]->amt_base_flat, + 'amt_disc_type' => $mergeFromAItem[0]->amt_disc_type, + 'amt_disc_percent' => $mergeFromAItem[0]->amt_disc_percent, + 'amt_disc_flat' => $mergeFromAItem[0]->amt_disc_flat, + 'amt_result_flat' => $mergeFromAItem[0]->amt_result_flat, + 'amt_total_flat' => $mergeFromAItem[0]->amt_total_flat, + 'ddln_pay_at' => $mergeFromAItem[0]->ddln_pay_at, + 'ddln_pay_type' => $mergeFromAItem[0]->ddln_pay_type, + 'img_proof_submission' => $mergeFromAItem[0]->img_proof_submission, + 'img_proof_payment' => $mergeFromAItem[0]->img_proof_payment, + 'bank_id' => $mergeFromAItem[0]->bank_id, + 'bank_code' => $mergeFromAItem[0]->bank_code, + 'bank_name' => $mergeFromAItem[0]->bank_name, + 'bank_short_name' => $mergeFromAItem[0]->bank_short_name, + 'bank_acc_number' => $mergeFromAItem[0]->bank_acc_number, + 'bank_acc_name' => $mergeFromAItem[0]->bank_acc_name, + 'amt_bill_base_flat' => $mergeFromAItem[0]->amt_bill_base_flat, + 'amt_bill_disc_type' => $mergeFromAItem[0]->amt_bill_disc_type, + 'amt_bill_disc_percent' => $mergeFromAItem[0]->amt_bill_disc_percent, + 'amt_bill_disc_flat' => $mergeFromAItem[0]->amt_bill_disc_flat, + 'amt_bill_result_flat' => $mergeFromAItem[0]->amt_bill_result_flat, + 'amt_bill_total_flat' => $mergeFromAItem[0]->amt_bill_total_flat, + 'invc_to_client' => $mergeFromAItem[0]->invc_to_client, + 'calc_to_vdr' => $mergeFromAItem[0]->calc_to_vdr, + 'is_adm_price' => $mergeFromAItem[0]->is_adm_price, + 'is_paid' => $mergeFromAItem[0]->is_paid, + 'paid_at' => $mergeFromAItem[0]->paid_at, + 'paid_by' => $mergeFromAItem[0]->paid_by, + 'paid_method' => $mergeFromAItem[0]->paid_method, + 'paid_ref_no' => $mergeFromAItem[0]->paid_ref_no, + 'is_bill_paid' => $mergeFromAItem[0]->is_bill_paid, + 'paid_bill_at' => $mergeFromAItem[0]->paid_bill_at, + 'paid_bill_by' => $mergeFromAItem[0]->paid_bill_by, + 'paid_bill_method' => $mergeFromAItem[0]->paid_bill_method, + 'only_client' => $mergeFromAItem[0]->only_client, + 'only_vdr' => $mergeFromAItem[0]->only_vdr, + 'is_hidden' => $mergeFromAItem[0]->is_hidden, + 'is_tax' => $mergeFromAItem[0]->is_tax, + 'is_disc' => $mergeFromAItem[0]->is_disc, + 'is_aprv' => $mergeFromAItem[0]->is_aprv, + 'rjct_at' => $mergeFromAItem[0]->rjct_at, + 'rjct_by' => $mergeFromAItem[0]->rjct_by, + 'is_bill_aprv' => $mergeFromAItem[0]->is_bill_aprv, + 'rjct_bill_at' => $mergeFromAItem[0]->rjct_bill_at, + 'rjct_bill_by' => $mergeFromAItem[0]->rjct_bill_by, + 'is_merge_from' => OrdersAItems::IS_MERGE_YES, + 'merge_from_a_id' => $mergeFromAItem[0]->id, + 'merge_from_ord_id' => $mergeFromAItem[0]->ord_id, + 'merge_from_ord_code' => $mergeFromAItem[0]->ord_code, + 'merge_from_at' => $now, + 'merge_from_by' => $req->auth->uid, + 'ref_ord_id' => $mergeFromAItem[0]->ord_id, + 'ref_ord_code' => $mergeFromAItem[0]->ord_code, + // 'ref_v_termin_id' => $mergeFromAItem[0]->v_termin_id, + // 'ref_c_termin_id' => $mergeFromAItem[0]->c_termin_id, + 'ref_ord_a_item_id' => $mergeFromAItem[0]->id, + 'crt' => $now, + 'crt_by' => $req->auth->uid, + 'crt_type' => OrdersAItems::CRT_TYPE_FINANCE, + 'updt' => $now, + 'updt_by' => $req->auth->uid, + ]; + + if ($insMergeToAItem['invc_to_client'] === OrdersAItems::INVC_TO_CLIENT_YES) { + $termins = OrdersTermins::listWithFilter([ + 'termin_for' => OrdersTermins::TERMIN_FOR_CLIENT, + 'termin_is_paid' => OrdersTermins::IS_PAID_NO, + 'ord_id' => $mergeToOrder[0]->ord_id, + 'in_stts_merge' => [ + OrdersAItems::STTS_MERGE_NO, + OrdersAItems::STTS_MERGE_RESULT, + ], + ]); + $insMergeToAItem['c_termin_id'] = 0; + $insMergeToAItem['ref_c_termin_id'] = 0; + if (count($termins) > 0) { + $insMergeToAItem['c_termin_id'] = $termins[0]->id; + $insMergeToAItem['ref_c_termin_id'] = $termins[0]->id; + } + if ($insMergeToAItem['c_termin_id'] === 0) { + DB::rollBack(); + $apiResp = Responses::bad_request('tidak dapat melakukan merge ke transaksi yang dituju, karena semua penagihan ke client sudah close'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + $sell_price = $mergeToOrder[0]->price + $insMergeToAItem['amt_bill_total_flat']; + Orders::updateOrder($mergeToOrder[0]->ord_id, [ + 'price' => $sell_price, + ]); + + Finance::updtChangeInvc($insMergeToAItem['c_termin_id']); + } else { + $insMergeToAItem['c_termin_id'] = 0; + $insMergeToAItem['ref_c_termin_id'] = 0; + } + + if ($insMergeToAItem['calc_to_vdr'] === OrdersAItems::CALC_TO_VDR_YES) { + $termins = OrdersTermins::listWithFilter([ + 'ord_id' => $mergeToOrder[0]->ord_id, + 'termin_for' => OrdersTermins::TERMIN_FOR_VENDOR, + 'termin_is_paid' => OrdersTermins::IS_PAID_NO, + 'in_stts_merge' => [ + OrdersAItems::STTS_MERGE_NO, + OrdersAItems::STTS_MERGE_RESULT, + ], + ]); + $insMergeToAItem['v_termin_id'] = 0; + $insMergeToAItem['ref_v_termin_id'] = 0; + if (count($termins) > 0) { + $insMergeToAItem['v_termin_id'] = $termins[0]->id; + $insMergeToAItem['ref_v_termin_id'] = $termins[0]->id; + } + if ($insMergeToAItem['v_termin_id'] === 0) { + $termins = OrdersTermins::listWithFilter([ + 'ord_id' => $mergeToOrder[0]->ord_id, + 'termin_for' => OrdersTermins::TERMIN_FOR_VENDOR, + 'in_stts_merge' => [ + OrdersAItems::STTS_MERGE_NO, + OrdersAItems::STTS_MERGE_RESULT, + ], + ]); + $insMergeToAItem['v_termin_id'] = $termins[count($termins) - 1]->id; + $insMergeToAItem['ref_v_termin_id'] = $termins[count($termins) - 1]->id; + } + + $buy_price = $mergeToOrder[0]->buy_price + $insMergeToAItem['amt_total_flat']; + Orders::updateOrder($mergeToOrder[0]->ord_id, [ + 'buy_price' => $buy_price, + ]); + } else { + $insMergeToAItem['v_termin_id'] = 0; + $insMergeToAItem['ref_v_termin_id'] = 0; + } + + $aid = OrdersAItems::add($insMergeToAItem); + $insMergeToAItem['id'] = $aid; + $updtMergeFromAItems['merge_to_a_id'] = $aid; + OrdersAItems::updt($ord_a_item_id, $updtMergeFromAItems); + + $apiResp = Responses::success('success merge item'); + + DB::commit(); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + /** + * merge ada 2 termin dari 1 trx ? jadi 1 termin + * merge ada 4 termin dari 2 trx ? masing2 jadi 1 termin + * merge kalau sudah ada adt items ? hanya termin yang di recreate, adt items tidak direcreate + * merge kalau ada yang sudah lunas baik main item / adt item ? gabisa + * saat recreate termin sisanya ngikut termin sebelumnya, saat ini belum ada diskon + */ + public function api_finance_merger_trx(Request $req) + { + try { + $now = time(); + + $input = [ + 'mrg_from_ord_code' => $req->mrg_from_ord_code, + 'mrg_from_ord_id' => $req->mrg_from_ord_id, + 'mrg_to_ord_code' => $req->mrg_to_ord_code, + 'mrg_to_ord_id' => $req->mrg_to_ord_id, + 'new_buy_price' => $req->new_buy_price, + 'note' => $req->note, + ]; + $rulesInput = [ + 'mrg_from_ord_code' => 'required|string|min:5', + 'mrg_from_ord_id' => 'nullable|integer|not_in:0', + 'mrg_to_ord_code' => 'required|string|min:5', + 'mrg_to_ord_id' => 'nullable|integer|not_in:0', + 'new_buy_price' => 'required|numeric|not_in:0', + 'note' => 'nullable|string', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + if ($req->mrg_from_ord_code == $req->mrg_to_ord_code) { + $apiResp = Responses::bad_input('tidak dapat merger pada transaksi yang sama'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + $mrgFromOrd = Orders::showOrder([ + 'code' => $req->mrg_from_ord_code, + 'get_zone_zonasi' => 1, + 'get_vdr_bank' => 1, + // 'get_prefer_type_truck' => 1, + // 'get_pic_zone' => 1, + // 'get_client_pt' => 1, + ]); + if (count($mrgFromOrd) < 1) { + $apiResp = Responses::not_found('order code not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + $mrgToOrd = Orders::showOrder([ + 'code' => $req->mrg_to_ord_code, + 'get_zone_zonasi' => 1, + 'get_vdr_bank' => 1, + // 'get_prefer_type_truck' => 1, + // 'get_pic_zone' => 1, + // 'get_client_pt' => 1, + ]); + if (count($mrgToOrd) < 1) { + $apiResp = Responses::not_found('order code not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + if ($mrgFromOrd[0]->vdr_id !== $mrgToOrd[0]->vdr_id) { + $apiResp = Responses::bad_request('merge hanya berlaku untuk vendor yang sama dikedua transaksi'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + if ($mrgFromOrd[0]->vhc_id !== $mrgToOrd[0]->vhc_id) { + $apiResp = Responses::bad_request('merge hanya berlaku untuk kendaraan yang sama dikedua transaksi'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + if ($mrgFromOrd[0]->drv_id !== $mrgToOrd[0]->drv_id) { + $apiResp = Responses::bad_request('merge hanya berlaku untuk pengemudi yang sama dikedua transaksi'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + // if ($req->new_buy_price > $mrgFromOrd[0]->price) { + // $apiResp = Responses::bad_request('biaya melebihi harga jual pada transaksi ' . $mrgFromOrd[0]->ord_code); + // return (new Response($apiResp, $apiResp['meta']['code'])); + // } + // if ($req->new_buy_price > $mrgToOrd[0]->price) { + // $apiResp = Responses::bad_request('biaya melebihi harga jual pada transaksi ' . $mrgToOrd[0]->ord_code); + // return (new Response($apiResp, $apiResp['meta']['code'])); + // } + + $updtBuyPriceFrom = 0; + $updtBuyPriceTo = 0; + + // pengurangan update buy price dari termin + $allTerminsVdrFrom = OrdersTermins::listWithFilter([ + 'ord_id' => $mrgFromOrd[0]->ord_id, + 'termin_for' => OrdersTermins::TERMIN_FOR_VENDOR, + 'in_stts_merge' => [ + OrdersAItems::STTS_MERGE_NO, + OrdersAItems::STTS_MERGE_RESULT, + ], + ]); + $tvids1 = []; + $totTerminV1 = 0; + foreach ($allTerminsVdrFrom as $terminVdr1) { + $updtBuyPriceFrom -= $terminVdr1->termin_result_flat; + if ($terminVdr1->termin_is_paid === OrdersTermins::IS_PAID_YES) { + $apiResp = Responses::bad_request('tidak dapat merger, ada item yang sudah terbayar pada transaksi ' . $mrgFromOrd[0]->ord_code); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + $tvids1[] = $terminVdr1->id; + $totTerminV1 += $terminVdr1->termin_result_flat; + } + $allTerminsVdrTo = OrdersTermins::listWithFilter([ + 'ord_id' => $mrgToOrd[0]->ord_id, + 'termin_for' => OrdersTermins::TERMIN_FOR_VENDOR, + 'in_stts_merge' => [ + OrdersAItems::STTS_MERGE_NO, + OrdersAItems::STTS_MERGE_RESULT, + ], + ]); + $tvids2 = []; + $totTerminV2 = 0; + foreach ($allTerminsVdrTo as $terminVdr2) { + $updtBuyPriceTo -= $terminVdr2->termin_result_flat; + if ($terminVdr2->termin_is_paid === OrdersTermins::IS_PAID_YES) { + $apiResp = Responses::bad_request('tidak dapat merger, ada item yang sudah terbayar pada order code ' . $mrgToOrd[0]->ord_code); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + $tvids2[] = $terminVdr2->id; + $totTerminV2 += $terminVdr2->termin_result_flat; + } + + $pembagi = $totTerminV1 + $totTerminV2; + $newTerminBuyPriceFrom = round($totTerminV1 / $pembagi * $req->new_buy_price); + $newTerminBuyPriceTo = round($totTerminV2 / $pembagi * $req->new_buy_price); + // round(2000/6000*5000); // 1666.6666666666665 -> round -> 1667.0 + + // penambahan update buy price dari buy_price sebelumnya(termasuk adt items) dan new termin, jadi tidak perlu kalkulasi ulang a_items + $updtBuyPriceFrom += $mrgFromOrd[0]->buy_price + $newTerminBuyPriceFrom; + $updtBuyPriceTo += $mrgToOrd[0]->buy_price + $newTerminBuyPriceTo; + + // get orders_a_items main_item with that termin + $mainItems1 = OrdersAItems::showAItemByVids($tvids1, ['a_item_type' => OrdersAItems::A_TYPE_PRIMARY]); + $mainItems2 = OrdersAItems::showAItemByVids($tvids2, ['a_item_type' => OrdersAItems::A_TYPE_PRIMARY]); + + $nanoid = new Nanoid(); + $merge_code = $nanoid->formattedId('0123456789', 9); + // $merge_code = $now; + $doWhile = true; + do { + if (substr($merge_code, 0, 1) == 0) { + $merge_code = $nanoid->formattedId('0123456789', 9); + } else { + $doWhile = false; + } + } while ($doWhile); + + DB::beginTransaction(); + + // new termin1 utk transaksi 1 + $v1_termin1_percent = 100; + $v1_termin1_calc_percent = $v1_termin1_percent / 100 * $newTerminBuyPriceFrom; + $insTermin1From = [ + 'ord_id' => $mrgFromOrd[0]->ord_id, + 'ord_code' => $mrgFromOrd[0]->ord_code, + 'flow_type' => OrdersTermins::FLOW_TYPE_PAYMENT, + 'cash_type' => OrdersTermins::TYPE_CASH_OUT, + 'sequence' => count($allTerminsVdrFrom) + 1, + 'termin_base_flat' => $newTerminBuyPriceFrom, + 'termin_amt_type' => OrdersTermins::AMT_TYPE_PERCENT, + 'termin_amt' => $v1_termin1_percent, + 'termin_calc_percent' => $v1_termin1_calc_percent, + 'termin_result_flat' => $v1_termin1_calc_percent, + 'termin_ddln_type' => $allTerminsVdrFrom[0]->termin_ddln_type, + 'termin_ddln_at' => $allTerminsVdrFrom[0]->termin_ddln_at, + 'termin_for' => OrdersTermins::TERMIN_FOR_VENDOR, + 'is_active' => OrdersTermins::IS_ACTIVE_YES, + 'stts_merge' => OrdersTermins::STTS_MERGE_RESULT, + 'group_merge_code' => $merge_code, + 'merge_at' => $now, + 'crt' => $now, + 'crt_by' => $req->auth->uid, + 'crt_type' => OrdersTermins::CRT_TYPE_ADMIN, + 'updt' => $now, + 'updt_by' => $req->auth->uid, + ]; + $v1_termin1_id = OrdersTermins::add($insTermin1From); + $unit_qty = 1; + $ddln_pay_type = ($insTermin1From['termin_ddln_at'] === OrdersTermins::DDLN_TERMIN_TYPE_TIME) ? OrdersAItems::DDLN_PAY_TYPE_TIME : OrdersAItems::DDLN_PAY_TYPE_ORD_FINISH; + OrdersAItems::add([ + 'ord_id' => $mrgFromOrd[0]->ord_id, + 'ord_code' => $mrgFromOrd[0]->ord_code, + 'flow_type' => OrdersAItems::FLOW_TYPE_PAYMENT, + 'cash_type' => OrdersAItems::TYPE_CASH_OUT, + 'v_termin_id' => $v1_termin1_id, + 'a_item_type' => OrdersAItems::A_TYPE_PRIMARY, + 'desc' => "Pengantaran Logistik
" . ucwords(strtolower($mrgFromOrd[0]->pck_prid_name)) . " - " . ucwords(strtolower($mrgFromOrd[0]->drop_prid_name)) . "
" . date('d F Y', $mrgFromOrd[0]->set_pck_at) . " WIB
Pembayaran termin 1", + 'unit_id' => 0, + 'unit_type' => UnitTypes::UNIT_TYPE_PAKET, + 'unit_qty' => $unit_qty, + 'amt_base_flat' => $insTermin1From['termin_result_flat'], + 'amt_result_flat' => $insTermin1From['termin_result_flat'], + 'amt_total_flat' => $insTermin1From['termin_result_flat'] * $unit_qty, + 'ddln_pay_at' => $insTermin1From['termin_ddln_at'], + 'ddln_pay_type' => $ddln_pay_type, + 'img_proof_submission' => null, + 'img_proof_payment' => null, + 'bank_id' => $mrgFromOrd[0]->vdr_bank_id, + 'bank_code' => $mrgFromOrd[0]->vdr_bank_code, + 'bank_name' => $mrgFromOrd[0]->vdr_bank_name, + 'bank_short_name' => $mrgFromOrd[0]->vdr_bank_short_name, + 'bank_acc_number' => $mrgFromOrd[0]->vdr_bank_acc_number, + 'bank_acc_name' => $mrgFromOrd[0]->vdr_bank_acc_name, + 'invc_to_client' => OrdersAItems::INVC_TO_CLIENT_NO, + 'calc_to_vdr' => OrdersAItems::CALC_TO_VDR_YES, + 'only_vdr' => OrdersAItems::ONLY_VDR_YES, + 'is_active' => OrdersAItems::IS_ACTIVE_YES, + 'stts_merge' => OrdersAItems::STTS_MERGE_RESULT, + 'group_merge_code' => $merge_code, + 'merge_at' => $now, + 'ref_ord_id' => $mrgFromOrd[0]->ord_id, + 'ref_ord_code' => $mrgFromOrd[0]->ord_code, + 'ref_v_termin_id' => $v1_termin1_id, + 'crt' => $now, + 'crt_by' => $req->auth->uid, + 'updt' => $now, + 'updt_by' => $req->auth->uid, + ]); + + // new termin1 utk transaksi 2 + $v2_termin1_percent = 100; + $v2_termin1_calc_percent = $v2_termin1_percent / 100 * $newTerminBuyPriceTo; + $insTermin1To = [ + 'ord_id' => $mrgToOrd[0]->ord_id, + 'ord_code' => $mrgToOrd[0]->ord_code, + 'flow_type' => OrdersTermins::FLOW_TYPE_PAYMENT, + 'cash_type' => OrdersTermins::TYPE_CASH_OUT, + 'sequence' => count($allTerminsVdrTo) + 1, + 'termin_base_flat' => $newTerminBuyPriceTo, + 'termin_amt_type' => OrdersTermins::AMT_TYPE_PERCENT, + 'termin_amt' => $v2_termin1_percent, + 'termin_calc_percent' => $v2_termin1_calc_percent, + 'termin_result_flat' => $v2_termin1_calc_percent, + 'termin_ddln_type' => $allTerminsVdrTo[0]->termin_ddln_type, + 'termin_ddln_at' => $allTerminsVdrTo[0]->termin_ddln_at, + 'termin_for' => OrdersTermins::TERMIN_FOR_VENDOR, + 'is_active' => OrdersTermins::IS_ACTIVE_YES, + 'stts_merge' => OrdersTermins::STTS_MERGE_RESULT, + 'group_merge_code' => $merge_code, + 'merge_at' => $now, + 'crt' => $now, + 'crt_by' => $req->auth->uid, + 'crt_type' => OrdersTermins::CRT_TYPE_ADMIN, + 'updt' => $now, + 'updt_by' => $req->auth->uid, + ]; + $v2_termin1_id = OrdersTermins::add($insTermin1To); + $unit_qty = 1; + $ddln_pay_type = ($insTermin1To['termin_ddln_at'] === OrdersTermins::DDLN_TERMIN_TYPE_TIME) ? OrdersAItems::DDLN_PAY_TYPE_TIME : OrdersAItems::DDLN_PAY_TYPE_ORD_FINISH; + OrdersAItems::add([ + 'ord_id' => $mrgToOrd[0]->ord_id, + 'ord_code' => $mrgToOrd[0]->ord_code, + 'flow_type' => OrdersAItems::FLOW_TYPE_PAYMENT, + 'cash_type' => OrdersAItems::TYPE_CASH_OUT, + 'v_termin_id' => $v2_termin1_id, + 'a_item_type' => OrdersAItems::A_TYPE_PRIMARY, + 'desc' => "Pengantaran Logistik
" . ucwords(strtolower($mrgToOrd[0]->pck_prid_name)) . " - " . ucwords(strtolower($mrgToOrd[0]->drop_prid_name)) . "
" . date('d F Y', $mrgToOrd[0]->set_pck_at) . " WIB
Pembayaran termin 1", + 'unit_id' => 0, + 'unit_type' => UnitTypes::UNIT_TYPE_PAKET, + 'unit_qty' => $unit_qty, + 'amt_base_flat' => $insTermin1To['termin_result_flat'], + 'amt_result_flat' => $insTermin1To['termin_result_flat'], + 'amt_total_flat' => $insTermin1To['termin_result_flat'] * $unit_qty, + 'ddln_pay_at' => $insTermin1To['termin_ddln_at'], + 'ddln_pay_type' => $ddln_pay_type, + 'img_proof_submission' => null, + 'img_proof_payment' => null, + 'bank_id' => $mrgToOrd[0]->vdr_bank_id, + 'bank_code' => $mrgToOrd[0]->vdr_bank_code, + 'bank_name' => $mrgToOrd[0]->vdr_bank_name, + 'bank_short_name' => $mrgToOrd[0]->vdr_bank_short_name, + 'bank_acc_number' => $mrgToOrd[0]->vdr_bank_acc_number, + 'bank_acc_name' => $mrgToOrd[0]->vdr_bank_acc_name, + 'invc_to_client' => OrdersAItems::INVC_TO_CLIENT_NO, + 'calc_to_vdr' => OrdersAItems::CALC_TO_VDR_YES, + 'only_vdr' => OrdersAItems::ONLY_VDR_YES, + 'is_active' => OrdersAItems::IS_ACTIVE_YES, + 'stts_merge' => OrdersAItems::STTS_MERGE_RESULT, + 'group_merge_code' => $merge_code, + 'merge_at' => $now, + 'ref_ord_id' => $mrgToOrd[0]->ord_id, + 'ref_ord_code' => $mrgToOrd[0]->ord_code, + 'ref_v_termin_id' => $v2_termin1_id, + 'crt' => $now, + 'crt_by' => $req->auth->uid, + 'updt' => $now, + 'updt_by' => $req->auth->uid, + ]); + + foreach ($allTerminsVdrFrom as $terminVdr1) { + if ($terminVdr1->termin_is_paid !== OrdersTermins::IS_PAID_YES) { + OrdersTermins::updt($terminVdr1->id, [ + 'is_active' => OrdersTermins::IS_ACTIVE_NO, + 'stts_merge' => OrdersTermins::STTS_MERGE_TO, + 'merge_to_code' => $merge_code, + 'merge_at' => $now, + ]); + } + } + foreach ($allTerminsVdrTo as $terminVdr2) { + if ($terminVdr2->termin_is_paid !== OrdersTermins::IS_PAID_YES) { + OrdersTermins::updt($terminVdr2->id, [ + 'is_active' => OrdersTermins::IS_ACTIVE_NO, + 'stts_merge' => OrdersTermins::STTS_MERGE_TO, + 'merge_to_code' => $merge_code, + 'merge_at' => $now, + ]); + } + } + + foreach ($mainItems1 as $main1) { + OrdersAItems::updt($main1->ord_a_item_id, [ + 'is_active' => OrdersTermins::IS_ACTIVE_NO, + 'stts_merge' => OrdersTermins::STTS_MERGE_TO, + 'merge_to_code' => $merge_code, + 'merge_at' => $now, + ]); + } + foreach ($mainItems2 as $main2) { + OrdersAItems::updt($main2->ord_a_item_id, [ + 'is_active' => OrdersTermins::IS_ACTIVE_NO, + 'stts_merge' => OrdersTermins::STTS_MERGE_TO, + 'merge_to_code' => $merge_code, + 'merge_at' => $now, + ]); + } + + Orders::updateOrder($mrgFromOrd[0]->ord_id, [ + 'buy_price' => $updtBuyPriceFrom, + 'group_code' => $merge_code, + 'stts_merge' => Orders::STTS_MERGE_RESULT, + 'group_merge_code' => $merge_code, + 'merge_at' => $now, + 'merge_note' => $req->note, + ]); + Orders::updateOrder($mrgToOrd[0]->ord_id, [ + 'buy_price' => $updtBuyPriceTo, + 'group_code' => $merge_code, + 'stts_merge' => Orders::STTS_MERGE_RESULT, + 'group_merge_code' => $merge_code, + 'merge_at' => $now, + 'merge_note' => $req->note, + ]); + + $apiResp = Responses::success('success merge transaksi'); + + DB::commit(); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + // + /** + * diskon disini defaultnya minus, jadi jangan dikurangin nanti malah jadi + + * ppn dan pph jika type pajak sudah termasuk pajak maka mendjadi minus + */ + public function api_finance_crt_updt_invc(Request $req) + { + $url_up_paid_proof_base64 = []; + try { + $now = time(); + + $input = [ + 'ord_id' => $req->ord_id, + 'ord_code' => $req->ord_code, + 'termin_id' => $req->termin_id, + 'items' => $req->items, + 'subtotal' => $req->subtotal, + 'tax_type' => $req->tax_type, + 'tax_type_kind' => $req->tax_type_kind, + 'ppn_percent' => $req->ppn_percent, + 'ppn_flat' => $req->ppn_flat, + 'pph_percent' => $req->pph_percent, + 'pph_flat' => $req->pph_flat, + 'tax_flat' => $req->tax_flat, + 'disc_type' => $req->disc_type, + 'disc_percent' => $req->disc_percent, + 'disc_flat' => $req->disc_flat, + 'total' => $req->total, + 'is_gnrt_invc' => $req->is_gnrt_invc, + ]; + $rulesInput = [ + 'ord_id' => 'required|integer|not_in:0', + 'ord_code' => 'required|string', + 'termin_id' => 'required|integer|not_in:0', + 'items' => 'required|string', + 'subtotal' => 'required|numeric', + 'tax_type' => 'required|numeric', + 'tax_type_kind' => 'required|numeric', + 'ppn_percent' => 'required|numeric', + 'ppn_flat' => 'required|numeric', + 'pph_percent' => 'required|numeric', + 'pph_flat' => 'required|numeric', + 'tax_flat' => 'required|numeric', + 'disc_type' => 'required|numeric', + 'disc_percent' => 'required|numeric', + 'disc_flat' => 'required|numeric', + 'total' => 'required|numeric', + 'is_gnrt_invc' => 'nullable|integer|not_in:0', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + if (strpos($req->items, ',') !== false) { + $req->items = substr($req->items, 0, -1); + } + + $order = Orders::showOrder([ + 'id' => $req->ord_id, + 'get_client_pt' => 1, + ]); + if (count($order) < 1 || $order === false) { + $apiResp = Responses::not_found('order not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + $ord_invc = OrdersInvoices::getByTerminId($req->termin_id); + $is_updt = true; + if (count($ord_invc) < 1 || $ord_invc === false) { + $is_updt = false; + $code = Helper::gnrtInvcCode($order[0]->ord_code); + // $nanoid = new Nanoid(); + // $code = $nanoid->formattedId('0123456789', 12); + // $doWhile = true; + // do { + // $uniqCode = OrdersInvoices::getByCode($code); + // if (count($uniqCode) > 0) { + // $code = $nanoid->formattedId('0123456789', 12); + // } else { + // $doWhile = false; + // } + // } while ($doWhile); + } else { + $invc_id = $ord_invc[0]->id; + $code = $ord_invc[0]->code; + if ($req->is_gnrt_invc == OrdersInvoices::IS_GNRT_INVC_YES) { + // $is_gnrt_invc = OrdersInvoices::IS_GNRT_INVC_YES; + // $code = Helper::gnrtInvcCode($order[0]->ord_code); + } + // else if ($ord_invc[0]->is_gnrt_invc == OrdersInvoices::IS_GNRT_INVC_YES) { + // $is_gnrt_invc = OrdersInvoices::IS_GNRT_INVC_YES; + // } else { + // $is_gnrt_invc = OrdersInvoices::IS_GNRT_INVC_NO; + // } + } + + $a_item_ppn = OrdersAItems::listAItems([ + 'c_termin_id' => $req->termin_id, + 'is_hidden' => OrdersAItems::IS_HIDDEN_YES, + 'is_tax' => OrdersAItems::IS_TAX_YES, + 'is_ppn' => OrdersAItems::IS_TAX_YES, + ]); + + $a_item_pph = OrdersAItems::listAItems([ + 'c_termin_id' => $req->termin_id, + 'is_hidden' => OrdersAItems::IS_HIDDEN_YES, + 'is_tax' => OrdersAItems::IS_TAX_YES, + 'is_pph' => OrdersAItems::IS_TAX_YES, + ]); + + $a_item_disc = OrdersAItems::listAItems([ + 'c_termin_id' => $req->termin_id, + 'is_hidden' => OrdersAItems::IS_HIDDEN_YES, + 'is_disc' => OrdersAItems::IS_DISC_YES, + ]); + + $req->tax_flat = round($req->tax_flat); + $req->disc_flat = round($req->disc_flat); + + DB::beginTransaction(); + + $sell_price = $order[0]->price; + + $old_bill_items = OrdersAItems::showAItemByIds(explode(',', $req->items)); + $perbedaan_selisih = 0; + foreach ($old_bill_items as $i => $bill_item) { + if ($req->tax_type_kind == OrdersAItems::AMT_TAX_TYPE_INCLUDE) { + $before_ppn = round($bill_item->amt_bill_base_flat / OrdersAItems::PPN_PERCENT_INCLUDE); + $ppn = round($bill_item->amt_bill_base_flat - $before_ppn); + $amt_bill_base_tax_flat = round($before_ppn); + $amt_bill_total_flat = round($amt_bill_base_tax_flat * $bill_item->unit_qty); + OrdersAItems::updt($bill_item->id, [ + 'amt_bill_tax_type' => $req->tax_type_kind, + 'amt_bill_tax_ppn_percent' => $req->ppn_percent, + 'amt_bill_tax_ppn_flat' => $ppn, + 'amt_bill_tax_pph_percent' => $req->pph_percent, + 'amt_bill_tax_pph_flat' => 0, + 'amt_bill_total_tax_flat' => $amt_bill_base_tax_flat, + 'amt_bill_result_flat' => $amt_bill_base_tax_flat, + 'amt_bill_total_flat' => $amt_bill_total_flat, + ]); + $sell_price = round($sell_price + $bill_item->amt_bill_total_flat); + $sell_price = round($sell_price - $amt_bill_total_flat); + $perbedaan_selisih += round($bill_item->amt_bill_total_flat - $amt_bill_total_flat); + } else { + OrdersAItems::updt($bill_item->id, [ + 'amt_bill_tax_type' => 0, + 'amt_bill_tax_ppn_percent' => 0, + 'amt_bill_tax_ppn_flat' => 0, + 'amt_bill_tax_pph_percent' => 0, + 'amt_bill_tax_pph_flat' => 0, + 'amt_bill_total_tax_flat' => 0, + 'amt_bill_result_flat' => round($bill_item->amt_bill_base_flat), + 'amt_bill_total_flat' => round($bill_item->amt_bill_base_flat * $bill_item->unit_qty), + ]); + $sell_price = round($sell_price - $bill_item->amt_bill_total_flat); + $sell_price = round($sell_price + $bill_item->amt_bill_base_flat * $bill_item->unit_qty); + } + } + $sell_price = $sell_price - $perbedaan_selisih; + + $a_item_ppn_id = 0; + $a_item_pph_id = 0; + + /** + * KALAU SUDAH TERMASUK PAJAK YANG DIHITUNG DI SUMMARY (PENGHASILANNYA) YANG 1.5 + * KALAU BELUM TERMASUK PAJAK YANG DIHITUNG DI SUMMARY (PENGHASILANNYA) YANG 1.5 + PAJAK + */ + + // dump('sell_price => '. $sell_price); + if ($req->tax_type_kind == OrdersAItems::AMT_TAX_TYPE_INCLUDE) { + if ($a_item_ppn === false || count($a_item_ppn) < 1) { + $insPpn = [ + 'ord_id' => $order[0]->ord_id, + 'ord_code' => $order[0]->ord_code, + 'c_termin_id' => $req->termin_id, + 'flow_type' => OrdersInvoices::FLOW_TYPE_BILLING, + 'cash_type' => OrdersInvoices::TYPE_CASH_IN, + 'a_item_type' => OrdersAItems::A_TYPE_SECONDARY, + 'desc' => "PPN ($req->ppn_percent%)", + 'unit_id' => 0, + 'unit_type' => UnitTypes::UNIT_TYPE_PCS, + 'amt_bill_base_flat' => $req->ppn_flat, + 'unit_qty' => 1, + 'amt_bill_tax_type' => $req->tax_type_kind, + 'amt_bill_result_flat' => $req->ppn_flat, + 'amt_bill_total_flat' => $req->ppn_flat, + 'ddln_pay_at' => 0, + 'ddln_pay_type' => OrdersAItems::DDLN_PAY_TYPE_TIME, + 'invc_to_client' => OrdersAItems::INVC_TO_CLIENT_YES, + 'calc_to_vdr' => OrdersAItems::CALC_TO_VDR_NO, + 'is_adm_price' => OrdersAItems::IS_ADM_PRICE_NO, + 'only_client' => OrdersAItems::ONLY_CLIENT_YES, + 'is_hidden' => OrdersAItems::IS_HIDDEN_YES, + 'is_tax' => OrdersAItems::IS_TAX_YES, + 'is_tax_type' => $req->tax_type_kind, + 'is_ppn' => OrdersAItems::IS_TAX_YES, + 'ref_ord_id' => $order[0]->ord_id, + 'ref_ord_code' => $order[0]->ord_code, + 'ref_c_termin_id' => $req->termin_id, + 'crt' => $now, + 'crt_by' => $req->auth->uid, + 'updt' => $now, + 'updt_by' => $req->auth->uid, + ]; + $a_item_ppn_id = OrdersAItems::add($insPpn); + // $sell_price = $sell_price + $insPpn['amt_bill_total_flat']; // + + } else { + $a_item_ppn_id = $a_item_ppn[0]->id; + $updtPpn = [ + 'desc' => "PPN ($req->ppn_percent%)", + 'unit_id' => 0, + 'unit_type' => UnitTypes::UNIT_TYPE_PCS, + 'amt_bill_base_flat' => $req->ppn_flat, + 'unit_qty' => 1, + 'amt_bill_result_flat' => $req->ppn_flat, + 'amt_bill_total_flat' => $req->ppn_flat, + 'is_tax_type' => $req->tax_type_kind, + 'updt' => $now, + 'updt_by' => $req->auth->uid, + ]; + OrdersAItems::updt($a_item_ppn[0]->id, $updtPpn); + // if ($updtPpn['amt_bill_total_flat'] != $a_item_ppn[0]->amt_bill_total_flat) { + // $sell_price = $sell_price - $a_item_ppn[0]->amt_bill_total_flat + $updtPpn['amt_bill_total_flat']; // - + + // } + if ($updtPpn['amt_bill_total_flat'] != $a_item_ppn[0]->amt_bill_total_flat) { + // $sell_price = $sell_price - $a_item_ppn[0]->amt_bill_total_flat + $updtPpn['amt_bill_total_flat']; // - + + } + } + + if ($a_item_pph === false || count($a_item_pph) < 1) { + // $insPph = [ + // 'ord_id' => $order[0]->ord_id, + // 'ord_code' => $order[0]->ord_code, + // 'c_termin_id' => $req->termin_id, + // 'flow_type' => OrdersInvoices::FLOW_TYPE_BILLING, + // 'cash_type' => OrdersInvoices::TYPE_CASH_IN, + // 'a_item_type' => OrdersAItems::A_TYPE_SECONDARY, + // 'desc' => "PPH ($req->pph_percent%)", + // 'unit_id' => 0, + // 'unit_type' => UnitTypes::UNIT_TYPE_PCS, + // 'amt_bill_base_flat' => $req->pph_flat, + // 'unit_qty' => 1, + // 'amt_bill_tax_type' => $req->tax_type_kind, + // 'amt_bill_result_flat' => $req->pph_flat, + // 'amt_bill_total_flat' => $req->pph_flat, + // 'ddln_pay_at' => 0, + // 'ddln_pay_type' => OrdersAItems::DDLN_PAY_TYPE_TIME, + // 'invc_to_client' => OrdersAItems::INVC_TO_CLIENT_YES, + // 'calc_to_vdr' => OrdersAItems::CALC_TO_VDR_NO, + // 'is_adm_price' => OrdersAItems::IS_ADM_PRICE_NO, + // 'only_client' => OrdersAItems::ONLY_CLIENT_YES, + // 'is_hidden' => OrdersAItems::IS_HIDDEN_YES, + // 'is_tax' => OrdersAItems::IS_TAX_YES, + // 'is_tax_type' => $req->tax_type_kind, + // 'is_pph' => OrdersAItems::IS_TAX_YES, + // 'ref_ord_id' => $order[0]->ord_id, + // 'ref_ord_code' => $order[0]->ord_code, + // 'ref_c_termin_id' => $req->termin_id, + // 'crt' => $now, + // 'crt_by' => $req->auth->uid, + // 'updt' => $now, + // 'updt_by' => $req->auth->uid, + // ]; + // $a_item_pph_id = OrdersAItems::add($insPph); + // // $sell_price = $sell_price + $insPph['amt_bill_total_flat']; // + + } else { + // $a_item_pph_id = $a_item_pph[0]->id; + // $updtPph = [ + // 'desc' => "PPH ($req->pph_percent%)", + // 'unit_id' => 0, + // 'unit_type' => UnitTypes::UNIT_TYPE_PCS, + // 'amt_bill_base_flat' => $req->pph_flat, + // 'unit_qty' => 1, + // 'amt_bill_result_flat' => $req->pph_flat, + // 'amt_bill_total_flat' => $req->pph_flat, + // 'is_tax_type' => $req->tax_type_kind, + // 'updt' => $now, + // 'updt_by' => $req->auth->uid, + // ]; + // OrdersAItems::updt($a_item_pph[0]->id, $updtPph); + // // if ($updtPph['amt_bill_total_flat'] != $a_item_pph[0]->amt_bill_total_flat) { + // // $sell_price = $sell_price - $a_item_pph[0]->amt_bill_total_flat + $updtPph['amt_bill_total_flat']; // - + + // // } + // if ($updtPph['amt_bill_total_flat'] != $a_item_pph[0]->amt_bill_total_flat) { + // // $sell_price = $sell_price - $a_item_pph[0]->amt_bill_total_flat + $updtPph['amt_bill_total_flat']; // - + + // } + } + } + + if ($a_item_disc === false || count($a_item_disc) < 1) { + if ($req->disc_type == OrdersAItems::AMT_TYPE_PERCENT) { + $desc = "Discount ($req->disc_percent%)"; + } else { + $desc = "Discount"; + } + $insDisc = [ + 'ord_id' => $order[0]->ord_id, + 'ord_code' => $order[0]->ord_code, + 'c_termin_id' => $req->termin_id, + 'flow_type' => OrdersInvoices::FLOW_TYPE_BILLING, + 'cash_type' => OrdersInvoices::TYPE_CASH_IN, + 'a_item_type' => OrdersAItems::A_TYPE_SECONDARY, + 'desc' => $desc, + 'unit_id' => 0, + 'unit_type' => UnitTypes::UNIT_TYPE_PCS, + 'amt_bill_base_flat' => -$req->disc_flat, + 'unit_qty' => 1, + 'amt_bill_result_flat' => -$req->disc_flat, + 'amt_bill_total_flat' => -$req->disc_flat, + 'ddln_pay_at' => 0, + 'ddln_pay_type' => OrdersAItems::DDLN_PAY_TYPE_TIME, + 'invc_to_client' => OrdersAItems::INVC_TO_CLIENT_YES, + 'calc_to_vdr' => OrdersAItems::CALC_TO_VDR_NO, + 'is_adm_price' => OrdersAItems::IS_ADM_PRICE_NO, + 'only_client' => OrdersAItems::ONLY_CLIENT_YES, + 'is_hidden' => OrdersAItems::IS_HIDDEN_YES, + 'is_disc' => OrdersAItems::IS_DISC_YES, + 'ref_ord_id' => $order[0]->ord_id, + 'ref_ord_code' => $order[0]->ord_code, + 'ref_c_termin_id' => $req->termin_id, + 'crt' => $now, + 'crt_by' => $req->auth->uid, + 'updt' => $now, + 'updt_by' => $req->auth->uid, + ]; + $a_item_disc_id = OrdersAItems::add($insDisc); + $sell_price = $sell_price + $insDisc['amt_bill_total_flat']; + } else { + $a_item_disc_id = $a_item_disc[0]->id; + if ($req->disc_type == OrdersAItems::AMT_TYPE_PERCENT) { + $desc = "Discount ($req->disc_percent%)"; + } else { + $desc = "Discount"; + } + $updtDisc = [ + 'desc' => $desc, + 'unit_id' => 0, + 'unit_type' => UnitTypes::UNIT_TYPE_PCS, + 'amt_bill_base_flat' => -$req->disc_flat, + 'unit_qty' => 1, + 'amt_bill_result_flat' => -$req->disc_flat, + 'amt_bill_total_flat' => -$req->disc_flat, + 'updt' => $now, + 'updt_by' => $req->auth->uid, + ]; + OrdersAItems::updt($a_item_disc[0]->id, $updtDisc); + if ($updtDisc['amt_bill_total_flat'] != $a_item_disc[0]->amt_bill_total_flat) { + // $sell_price = $sell_price + $a_item_disc[0]->amt_bill_total_flat; // ngebug + $sell_price = $sell_price - $a_item_disc[0]->amt_bill_total_flat + $updtDisc['amt_bill_total_flat']; + // $sell_price = $sell_price + $updtDisc['amt_bill_total_flat']; + } + } + + if ($req->tax_type_kind == OrdersAItems::AMT_TAX_TYPE_EXCLUDE) { + if ($a_item_ppn === false || count($a_item_ppn) < 1) { + $insPpn = [ + 'ord_id' => $order[0]->ord_id, + 'ord_code' => $order[0]->ord_code, + 'c_termin_id' => $req->termin_id, + 'flow_type' => OrdersInvoices::FLOW_TYPE_BILLING, + 'cash_type' => OrdersInvoices::TYPE_CASH_IN, + 'a_item_type' => OrdersAItems::A_TYPE_SECONDARY, + 'desc' => "PPN ($req->ppn_percent%)", + 'unit_id' => 0, + 'unit_type' => UnitTypes::UNIT_TYPE_PCS, + 'amt_bill_base_flat' => $req->ppn_flat, + 'unit_qty' => 1, + 'amt_bill_tax_type' => $req->tax_type_kind, + 'amt_bill_result_flat' => $req->ppn_flat, + 'amt_bill_total_flat' => $req->ppn_flat, + 'ddln_pay_at' => 0, + 'ddln_pay_type' => OrdersAItems::DDLN_PAY_TYPE_TIME, + 'invc_to_client' => OrdersAItems::INVC_TO_CLIENT_YES, + 'calc_to_vdr' => OrdersAItems::CALC_TO_VDR_NO, + 'is_adm_price' => OrdersAItems::IS_ADM_PRICE_NO, + 'only_client' => OrdersAItems::ONLY_CLIENT_YES, + 'is_hidden' => OrdersAItems::IS_HIDDEN_YES, + 'is_tax' => OrdersAItems::IS_TAX_YES, + 'is_tax_type' => $req->tax_type_kind, + 'is_ppn' => OrdersAItems::IS_TAX_YES, + 'ref_ord_id' => $order[0]->ord_id, + 'ref_ord_code' => $order[0]->ord_code, + 'ref_c_termin_id' => $req->termin_id, + 'crt' => $now, + 'crt_by' => $req->auth->uid, + 'updt' => $now, + 'updt_by' => $req->auth->uid, + ]; + $a_item_ppn_id = OrdersAItems::add($insPpn); + $sell_price = $sell_price + $insPpn['amt_bill_total_flat']; // + + } else { + $a_item_ppn_id = $a_item_ppn[0]->id; + $updtPpn = [ + 'desc' => "PPN ($req->ppn_percent%)", + 'unit_id' => 0, + 'unit_type' => UnitTypes::UNIT_TYPE_PCS, + 'amt_bill_base_flat' => $req->ppn_flat, + 'unit_qty' => 1, + 'amt_bill_result_flat' => $req->ppn_flat, + 'amt_bill_total_flat' => $req->ppn_flat, + 'is_tax_type' => $req->tax_type_kind, + 'updt' => $now, + 'updt_by' => $req->auth->uid, + ]; + OrdersAItems::updt($a_item_ppn[0]->id, $updtPpn); + // if ($updtPpn['amt_bill_total_flat'] != $a_item_ppn[0]->amt_bill_total_flat) { + // $sell_price = $sell_price - $a_item_ppn[0]->amt_bill_total_flat + $updtPpn['amt_bill_total_flat']; // - + + // } + if ($updtPpn['amt_bill_total_flat'] != $a_item_ppn[0]->amt_bill_total_flat) { + $sell_price = $sell_price - $a_item_ppn[0]->amt_bill_total_flat + $updtPpn['amt_bill_total_flat']; // - + + } + } + + if ($a_item_pph === false || count($a_item_pph) < 1) { + // $insPph = [ + // 'ord_id' => $order[0]->ord_id, + // 'ord_code' => $order[0]->ord_code, + // 'c_termin_id' => $req->termin_id, + // 'flow_type' => OrdersInvoices::FLOW_TYPE_BILLING, + // 'cash_type' => OrdersInvoices::TYPE_CASH_IN, + // 'a_item_type' => OrdersAItems::A_TYPE_SECONDARY, + // 'desc' => "PPH ($req->pph_percent%)", + // 'unit_id' => 0, + // 'unit_type' => UnitTypes::UNIT_TYPE_PCS, + // 'amt_bill_base_flat' => $req->pph_flat, + // 'unit_qty' => 1, + // 'amt_bill_tax_type' => $req->tax_type_kind, + // 'amt_bill_result_flat' => $req->pph_flat, + // 'amt_bill_total_flat' => $req->pph_flat, + // 'ddln_pay_at' => 0, + // 'ddln_pay_type' => OrdersAItems::DDLN_PAY_TYPE_TIME, + // 'invc_to_client' => OrdersAItems::INVC_TO_CLIENT_YES, + // 'calc_to_vdr' => OrdersAItems::CALC_TO_VDR_NO, + // 'is_adm_price' => OrdersAItems::IS_ADM_PRICE_NO, + // 'only_client' => OrdersAItems::ONLY_CLIENT_YES, + // 'is_hidden' => OrdersAItems::IS_HIDDEN_YES, + // 'is_tax' => OrdersAItems::IS_TAX_YES, + // 'is_tax_type' => $req->tax_type_kind, + // 'is_pph' => OrdersAItems::IS_TAX_YES, + // 'ref_ord_id' => $order[0]->ord_id, + // 'ref_ord_code' => $order[0]->ord_code, + // 'ref_c_termin_id' => $req->termin_id, + // 'crt' => $now, + // 'crt_by' => $req->auth->uid, + // 'updt' => $now, + // 'updt_by' => $req->auth->uid, + // ]; + // $a_item_pph_id = OrdersAItems::add($insPph); + // $sell_price = $sell_price + $insPph['amt_bill_total_flat']; // + + } else { + // $a_item_pph_id = $a_item_pph[0]->id; + // $updtPph = [ + // 'desc' => "PPH ($req->pph_percent%)", + // 'unit_id' => 0, + // 'unit_type' => UnitTypes::UNIT_TYPE_PCS, + // 'amt_bill_base_flat' => $req->pph_flat, + // 'unit_qty' => 1, + // 'amt_bill_result_flat' => $req->pph_flat, + // 'amt_bill_total_flat' => $req->pph_flat, + // 'is_tax_type' => $req->tax_type_kind, + // 'updt' => $now, + // 'updt_by' => $req->auth->uid, + // ]; + // OrdersAItems::updt($a_item_pph[0]->id, $updtPph); + // // if ($updtPph['amt_bill_total_flat'] != $a_item_pph[0]->amt_bill_total_flat) { + // // $sell_price = $sell_price - $a_item_pph[0]->amt_bill_total_flat + $updtPph['amt_bill_total_flat']; // - + + // // } + // if ($updtPph['amt_bill_total_flat'] != $a_item_pph[0]->amt_bill_total_flat) { + // $sell_price = $sell_price - $a_item_pph[0]->amt_bill_total_flat + $updtPph['amt_bill_total_flat']; // - + + // } + } + } + + Orders::updateOrder($order[0]->ord_id, [ + 'price' => $sell_price, + // 'price' => round($req->total), + ]); + + if ($is_updt) { + // $sell_price = $sell_price - $ord_invc[0]->amt_disc_flat - $ord_invc[0]->tax_flat; + OrdersInvoices::updt($ord_invc[0]->id, [ + 'code' => $code, + 'ord_a_item_ids' => $req->items, + 'amt_base_flat' => $req->subtotal, + 'amt_disc_type' => $req->disc_type, + 'amt_disc_percent' => $req->disc_percent, + 'amt_disc_flat' => $req->disc_flat, + 'amt_tax_type' => $req->tax_type, + 'amt_tax_type_kind' => $req->tax_type_kind, + 'amt_tax_ppn_percent' => $req->ppn_percent, + 'amt_tax_ppn_flat' => $req->ppn_flat, + 'amt_tax_pph_percent' => $req->pph_percent, + 'amt_tax_pph_flat' => $req->pph_flat, + 'amt_tax_flat' => $req->tax_flat, + 'amt_total_flat' => round($req->total), + // 'bank_id' => Banks::DFT_BANK_ID, + // 'bank_code' => Banks::DFT_BANK_CODE, + // 'bank_short_name' => Banks::DFT_BANK_NAME, + // 'bank_name' => Banks::DFT_BANK_SHORT_NAME, + // 'bank_acc_name' => Banks::DFT_BANK_ACC_NAME, + // 'bank_acc_number' => Banks::DFT_BANK_ACC_NUMBER, + 'invc_at' => $now, + // 'invc_for_uid' => $order[0]->c_id, + // 'invc_for_ptid' => $order[0]->c_pt_id, + // 'invc_for_type' => OrdersInvoices::INVC_FOR_CLIENT, + // 'pay_due_type' => OrdersInvoices::PAY_DUE_TYPE_14_WORK_DAY, + 'a_item_ppn_id' => $a_item_ppn_id, + 'a_item_pph_id' => $a_item_pph_id, + 'a_item_disc_id' => $a_item_disc_id, + 'is_gnrt_invc' => $req->is_gnrt_invc ?? 0, + 'updt' => $now, + 'updt_by' => $req->auth->uid, + ]); + } else { + $invc_id = OrdersInvoices::add([ + 'code' => $code, + 'ord_id' => $order[0]->ord_id, + 'ord_code' => $order[0]->ord_code, + 'flow_type' => OrdersInvoices::FLOW_TYPE_BILLING, + 'cash_type' => OrdersInvoices::TYPE_CASH_IN, + 'c_termin_id' => $req->termin_id, + 'ord_a_item_ids' => $req->items, + 'amt_base_flat' => $req->subtotal, + 'amt_disc_type' => $req->disc_type, + 'amt_disc_percent' => $req->disc_percent, + 'amt_disc_flat' => $req->disc_flat, + 'amt_tax_type' => $req->tax_type, + 'amt_tax_type_kind' => $req->tax_type_kind, + 'amt_tax_ppn_percent' => $req->ppn_percent, + 'amt_tax_ppn_flat' => $req->ppn_flat, + 'amt_tax_pph_percent' => $req->pph_percent, + 'amt_tax_pph_flat' => $req->pph_flat, + 'amt_tax_flat' => $req->tax_flat, + 'amt_total_flat' => $req->total, + 'bank_id' => Banks::DFT_BANK_ID, + 'bank_code' => Banks::DFT_BANK_CODE, + 'bank_short_name' => Banks::DFT_BANK_NAME, + 'bank_name' => Banks::DFT_BANK_SHORT_NAME, + 'bank_acc_name' => Banks::DFT_BANK_ACC_NAME, + 'bank_acc_number' => Banks::DFT_BANK_ACC_NUMBER, + 'invc_at' => $now, + 'invc_for_uid' => $order[0]->c_id, + 'invc_for_ptid' => $order[0]->c_pt_id, + 'invc_for_type' => OrdersInvoices::INVC_FOR_CLIENT, + 'pay_due_type' => OrdersInvoices::PAY_DUE_TYPE_14_WORK_DAY, + 'a_item_ppn_id' => $a_item_ppn_id, + 'a_item_pph_id' => $a_item_pph_id, + 'a_item_disc_id' => $a_item_disc_id, + 'is_gnrt_invc' => $req->is_gnrt_invc ?? 0, + 'crt' => $now, + 'crt_by' => $req->auth->uid, + 'crt_type' => OrdersInvoices::CRT_TYPE_FINANCE, + 'updt' => $now, + 'updt_by' => $req->auth->uid, + ]); + } + + $apiResp = Responses::success('success create / update invoice'); + $apiResp['id'] = $invc_id; + $apiResp['code'] = $code; + + DB::commit(); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + DB::rollBack(); + if (count($url_up_paid_proof_base64) > 0) { + foreach ($url_up_paid_proof_base64 as $path) { + Storage::disk('public')->delete($path); + } + } + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_finance_crt_updt_tax(Request $req) + { + try { + $now = time(); + + $input = [ + 'termin_id' => $req->termin_id, + 'ord_id' => $req->ord_id, + 'ord_code' => $req->ord_code, + 'invc_tax_type' => $req->invc_tax_type, + 'invc_tax_ppn_percent' => $req->invc_tax_ppn_percent, + 'invc_tax_pph_percent' => $req->invc_tax_pph_percent, + ]; + $rulesInput = [ + 'ord_id' => 'required|integer|not_in:0', + 'ord_code' => 'required|integer|not_in:0', + 'termin_id' => 'required|integer|not_in:0', + 'invc_tax_type' => 'required|numeric', + 'invc_tax_ppn_percent' => 'required|numeric', + 'invc_tax_pph_percent' => 'required|numeric', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $order = Orders::showOrder([ + 'id' => $req->ord_id, + 'get_client_pt' => 1, + ]); + if (count($order) < 1 || $order === false) { + $apiResp = Responses::not_found('order not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + $a_item_ppn = OrdersAItems::listAItems([ + 'c_termin_id' => $req->termin_id, + 'is_hidden' => OrdersAItems::IS_HIDDEN_YES, + 'is_tax' => OrdersAItems::IS_TAX_YES, + 'is_ppn' => OrdersAItems::IS_TAX_YES, + ]); + + $a_item_pph = OrdersAItems::listAItems([ + 'c_termin_id' => $req->termin_id, + 'is_hidden' => OrdersAItems::IS_HIDDEN_YES, + 'is_tax' => OrdersAItems::IS_TAX_YES, + 'is_pph' => OrdersAItems::IS_TAX_YES, + ]); + + DB::beginTransaction(); + + $sell_price = $order[0]->price; + + $ord_invc = OrdersInvoices::getByTerminId($req->termin_id); + if (count($ord_invc) < 1 || $ord_invc === false) {} + else { + OrdersInvoices::updt($ord_invc[0]->id, [ + 'is_gnrt_invc' => OrdersInvoices::IS_GNRT_INVC_NO, + ]); + } + + OrdersTermins::updt($req->termin_id, [ + 'termin_tax_type' => $req->invc_tax_type, + 'termin_tax_ppn_percent' => $req->invc_tax_ppn_percent, + 'termin_tax_pph_percent' => $req->invc_tax_pph_percent, + ]); + + if ($a_item_ppn === false || count($a_item_ppn) < 1) {} + else { + if ($a_item_ppn[0]->amt_bill_tax_type === OrdersAItems::AMT_TAX_TYPE_INCLUDE) { + $sell_price = $sell_price - $a_item_ppn[0]->amt_bill_total_flat; + } else if ($a_item_ppn[0]->amt_bill_tax_type === OrdersAItems::AMT_TAX_TYPE_EXCLUDE) { + $sell_price = $sell_price - $a_item_ppn[0]->amt_bill_total_flat; + } + OrdersAItems::dlt($a_item_ppn[0]->id); + } + + if ($a_item_pph === false || count($a_item_pph) < 1) {} + else { + if ($a_item_pph[0]->amt_bill_tax_type === OrdersAItems::AMT_TAX_TYPE_INCLUDE) { + $sell_price = $sell_price - $a_item_pph[0]->amt_bill_total_flat; + } else if ($a_item_pph[0]->amt_bill_tax_type === OrdersAItems::AMT_TAX_TYPE_EXCLUDE) { + $sell_price = $sell_price - $a_item_pph[0]->amt_bill_total_flat; + } + OrdersAItems::dlt($a_item_pph[0]->id); + } + + Orders::updateOrder($order[0]->ord_id, [ + 'price' => $sell_price, + // 'price' => round($req->total), + ]); + + $apiResp = Responses::success('success save tax'); + + DB::commit(); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_finance_confirm_invc(Request $req) + { + $url_up_paid_proof_base64 = []; + try { + $now = time(); + + $input = [ + 'invc_id' => $req->invc_id, + 'invc_code' => $req->invc_code, + 'amt_invoicing' => $req->amt_invoicing, + 'amt_bill_confirm' => $req->amt_bill_confirm, + 'amt_bill_confirm_note' => $req->amt_bill_confirm_note, + ]; + $rulesInput = [ + 'invc_id' => 'required|integer|not_in:0', + 'invc_code' => 'nullable|numeric', + 'amt_invoicing' => 'required|numeric', + 'amt_bill_confirm' => 'required|numeric', + 'amt_bill_confirm_note' => 'nullable|string', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + // if (!$req->up_paid_proof_base64 || count($req->up_paid_proof_base64) < 1) { + // $apiResp = Responses::bad_input('bukti pembayaran wajib diisi'); + // return new Response($apiResp, $apiResp['meta']['code']); + // } + + $ord_invc = OrdersInvoices::getById($req->invc_id); + if (count($ord_invc) < 1 || $ord_invc === false) { + $apiResp = Responses::not_found('invoice not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + $item_ids = explode(',', $ord_invc[0]->ord_a_item_ids); + $order = Orders::showOrder(['id' => $ord_invc[0]->ord_id]); + + // $a_item_ppn = OrdersAItems::listAItems([ + // 'c_termin_id' => $req->termin_id, + // 'is_hidden' => OrdersAItems::IS_HIDDEN_YES, + // 'is_tax' => OrdersAItems::IS_TAX_YES, + // ]); + + // $a_item_disc = OrdersAItems::listAItems([ + // 'c_termin_id' => $req->termin_id, + // 'is_hidden' => OrdersAItems::IS_HIDDEN_YES, + // 'is_disc' => OrdersAItems::IS_DISC_YES, + // ]); + + DB::beginTransaction(); + + $updtOrdersInvoices = [ + 'updt' => $now, + 'updt_by' => $req->auth->uid, + 'is_paid' => OrdersInvoices::IS_PAID_YES, + 'paid_at' => $now, + 'paid_by' => $req->auth->uid, + ]; + + if ($ord_invc[0]->c_termin_id !== 0) { + $termin = OrdersTermins::getById($ord_invc[0]->c_termin_id); + if ($termin[0]->termin_is_paid !== OrdersTermins::IS_PAID_YES) { + OrdersTermins::updt($ord_invc[0]->c_termin_id, [ + 'termin_is_paid' => OrdersTermins::IS_PAID_YES, + 'termin_paid_at' => $now, + 'termin_paid_by' => $req->auth->uid, + 'amt_bill_confirm' => $req->amt_bill_confirm, + 'amt_bill_confirm_note' => $req->amt_bill_confirm_note, + 'updt' => $now, + 'updt_by' => $req->auth->uid, + ]); + } + } + + $qty = 1; + $selisih = $req->amt_bill_confirm - $req->amt_invoicing; + OrdersAItems::add([ + 'ord_id' => $ord_invc[0]->ord_id, + 'ord_code' => $ord_invc[0]->ord_code, + 'flow_type' => OrdersAItems::FLOW_TYPE_BILLING, + 'cash_type' => OrdersAItems::TYPE_CASH_IN, + 'c_termin_id' => $ord_invc[0]->c_termin_id, + 'a_item_type' => OrdersAItems::A_TYPE_SECONDARY, + // 'desc' => $main_item_dec . "
Pembayaran termin 1", + 'desc' => 'Selisih dari nilai yang ditagihkan dan diterima pada trx_code:' . $ord_invc[0]->ord_code, + 'unit_id' => 0, + 'unit_type' => UnitTypes::UNIT_TYPE_PCS, + 'unit_qty' => $qty, + 'amt_bill_base_flat' => $selisih, + 'amt_bill_result_flat' => $selisih, + 'amt_bill_total_flat' => $selisih * $qty, + 'ddln_pay_at' => 0, + 'ddln_pay_type' => OrdersAItems::DDLN_PAY_TYPE_TIME, + 'img_proof_submission' => null, + 'img_proof_payment' => null, + 'bank_id' => Banks::DFT_BANK_ID, + 'bank_code' => Banks::DFT_BANK_CODE, + 'bank_name' => Banks::DFT_BANK_NAME, + 'bank_short_name' => Banks::DFT_BANK_SHORT_NAME, + 'bank_acc_number' => Banks::DFT_BANK_ACC_NUMBER, + 'bank_acc_name' => Banks::DFT_BANK_ACC_NAME, + // 'invc_to_client' => OrdersAItems::INVC_TO_CLIENT_YES, // seharusnya yang ini kalau diaktifin (mau dihitung di summary / ledger balance) + 'invc_to_client' => OrdersAItems::INVC_TO_CLIENT_NO, + 'calc_to_vdr' => OrdersAItems::CALC_TO_VDR_NO, + 'is_adm_price' => OrdersAItems::IS_ADM_PRICE_NO, + // 'only_client' => OrdersAItems::ONLY_CLIENT_YES, // seharusnya yang ini kalau diaktifin (mau dihitung di summary / ledger balance) + 'only_client' => OrdersAItems::ONLY_CLIENT_NO, + 'is_hidden' => OrdersAItems::IS_HIDDEN_YES, + 'is_substract' => OrdersAItems::IS_SUBTRACT_YES, + 'ref_ord_id' => $ord_invc[0]->ord_id, + 'ref_ord_code' => $ord_invc[0]->ord_code, + 'ref_c_termin_id' => $ord_invc[0]->c_termin_id, + 'is_bill_paid' => OrdersAItems::IS_PAID_YES, + 'paid_bill_at' => $now, + 'paid_bill_by' => $req->auth->uid, + 'crt' => $now, + 'crt_by' => $req->auth->uid, + 'updt' => $now, + 'updt_by' => $req->auth->uid, + ]); + + foreach ($item_ids as $id) { + OrdersAItems::updt($id, [ + 'updt' => $now, + 'updt_by' => $req->auth->uid, + 'is_bill_paid' => OrdersAItems::IS_PAID_YES, + 'paid_bill_at' => $now, + 'paid_bill_by' => $req->auth->uid, + ]); + } + + if ($ord_invc[0]->a_item_ppn_id != 0) { + OrdersAItems::updt($ord_invc[0]->a_item_ppn_id, [ + 'updt' => $now, + 'updt_by' => $req->auth->uid, + 'is_bill_paid' => OrdersAItems::IS_PAID_YES, + 'paid_bill_at' => $now, + 'paid_bill_by' => $req->auth->uid, + ]); + } + if ($ord_invc[0]->a_item_pph_id != 0) { + OrdersAItems::updt($ord_invc[0]->a_item_pph_id, [ + 'updt' => $now, + 'updt_by' => $req->auth->uid, + 'is_bill_paid' => OrdersAItems::IS_PAID_YES, + 'paid_bill_at' => $now, + 'paid_bill_by' => $req->auth->uid, + ]); + } + if ($ord_invc[0]->a_item_disc_id != 0) { + OrdersAItems::updt($ord_invc[0]->a_item_disc_id, [ + 'updt' => $now, + 'updt_by' => $req->auth->uid, + 'is_bill_paid' => OrdersAItems::IS_PAID_YES, + 'paid_bill_at' => $now, + 'paid_bill_by' => $req->auth->uid, + ]); + } + + OrdersInvoices::updt($ord_invc[0]->id, $updtOrdersInvoices); + + $updtOrd = []; + + $checkPaidOff = Finance::checkJustPaidOff($ord_invc[0]->ord_id); + if ($checkPaidOff['invc_paid'] === 1) { + $updtOrd['is_invc_paid'] = Orders::IS_PAID_YES; + $updtOrd['invc_paid_at'] = $now; + } + if ($checkPaidOff['vdr_paid'] === 1) { + $updtOrd['is_vdr_paid'] = Orders::IS_PAID_YES; + $updtOrd['vdr_paid_at'] = $now; + // kalau vhc & driver bisa order lagi setelah pembayaran lunas + // Vehicles::updateVehicle($order[0]->vhc_id, [ + // 'is_in_ord' => Vehicles::IN_ORD_NO, + // 'ord_id' => 0, + // 'ord_code' => 0, + // ]); + // Drivers::updateDriver($order[0]->drv_id, [ + // 'is_in_ord' => Drivers::IN_ORD_NO, + // 'ord_id' => 0, + // 'ord_code' => 0, + // ]); + } + if ($checkPaidOff['invc_vdr_paid'] === 1 || $checkPaidOff['invc_vdr_paid'] === 2) { + if ($order[0]->status === Orders::STTS_DROP || $order[0]->status === Orders::STTS_CLIENT_PAY || $order[0]->status === Orders::STTS_VENDOR_PAYED) { + $updtOrd['status'] = Orders::STTS_CLOSE; + } + } + + if (count($updtOrd) > 0) { + Orders::updateOrder($ord_invc[0]->ord_id, $updtOrd); + } + + // $currentBill = Finance::listBillings(['ord_id' => $ord_invc[0]->ord_id]); + // $currentPay = Finance::listPayments(['ord_id' => $ord_invc[0]->ord_id]); + // if ($currentBill[0]->total_billing === $currentBill[0]->total_payed || $currentPay[0]->total_payment === $currentPay[0]->total_payed) { + // $updtOrd = []; + // if ($currentBill[0]->total_billing === $currentBill[0]->total_payed) { + // if ($order[0]->is_invc_paid !== Orders::IS_PAID_YES) { + // $updtOrd['is_invc_paid'] = Orders::IS_PAID_YES; + // $updtOrd['invc_paid_at'] = $now; + // } + // } + // if ($currentPay[0]->total_payment === $currentPay[0]->total_payed) { + // if ($order[0]->is_vdr_paid !== Orders::IS_PAID_YES) { + // $updtOrd['is_vdr_paid'] = Orders::IS_PAID_YES; + // $updtOrd['vdr_paid_at'] = $now; + // Vehicles::updateVehicle($order[0]->vhc_id, [ + // 'is_in_ord' => Vehicles::IN_ORD_NO, + // 'ord_id' => 0, + // 'ord_code' => 0, + // ]); + // Drivers::updateDriver($order[0]->drv_id, [ + // 'is_in_ord' => Drivers::IN_ORD_NO, + // 'ord_id' => 0, + // 'ord_code' => 0, + // ]); + // } + // } + // if ($currentBill[0]->total_billing === $currentBill[0]->total_payed && $currentPay[0]->total_payment === $currentPay[0]->total_payed) { + // $updtOrd['status'] = Orders::STTS_CLOSE; + // } + // if (count($updtOrd) > 0) { + // Orders::updateOrder($ord_invc[0]->ord_id, $updtOrd); + // } + // } + + $apiResp = Responses::success('success paid invoice'); + + DB::commit(); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + DB::rollBack(); + if (count($url_up_paid_proof_base64) > 0) { + foreach ($url_up_paid_proof_base64 as $path) { + Storage::disk('public')->delete($path); + } + } + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_finance_save_note(Request $req, $ord_id) + { + $url_up_paid_proof_base64 = []; + try { + $now = time(); + + $input = [ + 'ord_id' => $ord_id, + 'fnnc_note' => $req->fnnc_note, + ]; + $rulesInput = [ + 'ord_id' => 'required|integer|not_in:0', + 'fnnc_note' => 'required|string|min:2', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $order = Orders::showOrder(['id' => $ord_id]); + if (count($order) < 1 || $order === false) { + $apiResp = Responses::not_found('order not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + DB::beginTransaction(); + + $updtOrd = [ + 'fnnc_note' => $req->fnnc_note, + ]; + Orders::updateOrder($order[0]->ord_id, $updtOrd); + + $apiResp = Responses::success('success save note'); + + DB::commit(); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + DB::rollBack(); + if (count($url_up_paid_proof_base64) > 0) { + foreach ($url_up_paid_proof_base64 as $path) { + Storage::disk('public')->delete($path); + } + } + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + + // DANA || CHECKPOINTS + public function api_list_pocket_tf_history(Request $req) + { + try { + $now = time(); + $input = []; + $rulesInput = []; + + // validasi input + // $isValidInput = Validator::make($input, $rulesInput); + // if (!$isValidInput->passes()) { + // $apiResp = Responses::bad_input($isValidInput->messages()->first()); + // return new Response($apiResp, $apiResp['meta']['code']); + // } + + $filter = [ + 'tf_method' => OrdersCheckpoints::TF_METHOD_DANA, + 'where_not_tf_at' => '0', + 'order_by' => 'point.tf_at DESC', + ]; + // $historys = OrdersLogsTf::listLogsTf($filter); + $historys = OrdersCheckpoints::listCheckpoints($filter); + + $i = 0; + foreach ($historys as $key => $row) { + $historys[$key]->DT_RowIndex = ++$i; + $historys[$key]->action = '-'; + } + $apiResp = Responses::success('success'); + $apiResp['data'] = $historys; + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_resend_pocket(Request $req) + { + try { + $now = time(); + $input = []; + $rulesInput = []; + + $input = [ + 'ord_checkpoint_id' => $req->ord_checkpoint_id, + ]; + $rulesInput = [ + 'ord_checkpoint_id' => 'required|integer|not_in:0', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $filter = [ + 'id' => $req->ord_checkpoint_id, + 'limit' => '1', + ]; + $historys = OrdersCheckpoints::listCheckpoints($filter); + if (count($historys) < 1) { + $apiResp = Responses::bad_request('Riwayat transfer tidak ditemukan'); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $order = Orders::showOrder([ + 'id' => $historys[0]->ord_id, + 'get_drv_bank' => 1, + 'ord_pck_drop_id' => $req->ord_pck_drop_id, + 'couple_pck_drop' => 1, + ]); + if (count($order) < 1) { + $apiResp = Responses::not_found('order not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + $drvPhone = DrvPhoneDevices::get(['drv_id' => $order[0]->drv_id]); + if (count($drvPhone) < 1) { + $apiResp = Responses::bad_request('Driver belum pernah melakukan login'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + $admins = Users::getUsersActiveByRole(Users::ROLE_FINANCE); + $admins_data = []; + foreach ($admins as $k => $v) { + array_push($admins_data, [ + "admin_id" => $v->id, + "admin_name" => $v->first_name, + "admin_phone" => $v->phone_code . " " . implode(" ", str_split($v->phone, 4)), + "admin_mail" => $v->email, + "admin_addr" => "" + ]); + } + + $dana = Dana::getDanaById(Dana::PK_ID); + if (count($dana) < 1) { + $apiResp = Responses::bad_request('dana error'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + $dana = $dana[0]; + + DB::beginTransaction(); + + $url = env('API_DANA_BINGCORP') . '/order/create'; + $guzReq = new GuzzleClient(); + $json = [ + 'ord_id' => $order[0]->ord_id, + 'ord_code' => $order[0]->ord_code, + 'checkpoint_id' => $historys[0]->ord_checkpoint_id, + 'bank_code' => $order[0]->drv_bank_code, + 'bank_name' => $order[0]->drv_bank_name, + 'bank_branch' => $order[0]->drv_bank_branch_name ?? null, + 'amt' => $historys[0]->pocket_total, + 'acc_name' => $order[0]->drv_bank_acc_name, + 'acc_number' => $order[0]->drv_bank_acc_number, + 'device_id' => $drvPhone[0]->device_id, + ]; + if ($dana->amt > $historys[0]->pocket_total && $dana->amt > Dana::MINIMUM_AMT) { + try { + $respDana = $guzReq->request('POST', $url, [ + 'headers' => [ + // 'Host' => $_SERVER['SERVER_ADDR'] ?? '127.0.0.1', + 'User-Agent' => 'curl/7.65.3', + 'Accept' => '*/*', + 'Accept-Encoding' => 'gzip, deflate, br', + // 'Content-Type' => 'application/x-www-form-urlencoded; charset=UTF-8', + 'Content-Type' => 'application/json', + // 'Connection' => 'keep-alive', + ], + 'json' => $json, + ]); + $isValidDana = 1; + $bodyDana = json_decode($respDana->getBody()->getContents()); + if ($respDana->getStatusCode() != 200 || $bodyDana->meta->code != 200) { + $isValidDana = 0; + // DB::rollBack(); + OrdersLogsTf::addLogsTf([ + 'ord_id' => $order[0]->ord_id, + 'ord_code' => $order[0]->ord_code, + 'type' => OrdersLogsTf::TYPE_TF_CHECKPOINT, + 'checkpoint_id' => $historys[0]->ord_checkpoint_id, + 'amount' => $historys[0]->pocket_total, + 'stts' => OrdersLogsTf::STTS_FAIL, + 'fail_at' => time(), + 'note' => $bodyDana->data->note, + 'bank_id' => $order[0]->drv_bank_id, + 'bank_name' => $order[0]->drv_bank_name, + 'bank_code' => $order[0]->drv_bank_code, + 'bank_short_name' => $order[0]->drv_bank_short_name, + 'bank_branch_name' => $order[0]->drv_bank_branch_name ?? null, + 'bank_acc_name' => $order[0]->drv_bank_acc_name, + 'bank_acc_number' => $order[0]->drv_bank_acc_number, + 'method' => OrdersLogsTf::METHOD_DANA, + 'url' => $url, + 'ref_code' => $bodyDana->data->dana_reference_no, + 'req_data' => json_encode($json), + 'resp_data' => json_encode($bodyDana), + 'crt' => time(), + 'updt' => time(), + ]); + OrdersCheckpoints::updateCheckpoint($historys[0]->ord_checkpoint_id, [ + 'pocket_is_paid' => OrdersCheckpoints::IS_TF_FAIL, + 'pocket_paid_note' => $bodyDana->data->note, + 'bank_id' => $order[0]->drv_bank_id, + 'bank_name' => $order[0]->drv_bank_name, + 'bank_code' => $order[0]->drv_bank_code, + 'bank_short_name' => $order[0]->drv_bank_short_name, + 'bank_branch_name' => $order[0]->drv_bank_branch_name ?? null, + 'bank_acc_name' => $order[0]->drv_bank_acc_name, + 'bank_acc_number' => $order[0]->drv_bank_acc_number, + 'tf_method' => OrdersCheckpoints::TF_METHOD_DANA, + 'tf_at' => $now, + 'tf_url' => $url, + 'tf_ref_code' => $bodyDana->data->dana_reference_no, + 'tf_note' => $bodyDana->data->note, + 'tf_req_data' => json_encode($json), + 'tf_resp_data' => json_encode($bodyDana), + ]); + $apiResp = Responses::bad_request('Gagal transfer ke rekening driver'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + if ($isValidDana === 1) { + OrdersLogsTf::addLogsTf([ + 'ord_id' => $order[0]->ord_id, + 'ord_code' => $order[0]->ord_code, + 'type' => OrdersLogsTf::TYPE_TF_CHECKPOINT, + 'checkpoint_id' => $historys[0]->ord_checkpoint_id, + 'amount' => $historys[0]->pocket_total, + 'stts' => OrdersLogsTf::STTS_PAID, + 'paid_at' => time(), + 'note' => $bodyDana->data->note, + 'bank_id' => $order[0]->drv_bank_id, + 'bank_name' => $order[0]->drv_bank_name, + 'bank_code' => $order[0]->drv_bank_code, + 'bank_short_name' => $order[0]->drv_bank_short_name, + 'bank_branch_name' => $order[0]->drv_bank_branch_name ?? null, + 'bank_acc_name' => $order[0]->drv_bank_acc_name, + 'bank_acc_number' => $order[0]->drv_bank_acc_number, + 'method' => OrdersLogsTf::METHOD_DANA, + 'url' => $url, + 'ref_code' => $bodyDana->data->dana_reference_no, + 'req_data' => json_encode($json), + 'resp_data' => json_encode($bodyDana), + 'crt' => time(), + 'updt' => time(), + ]); + OrdersCheckpoints::updateCheckpoint($historys[0]->ord_checkpoint_id, [ + 'pocket_is_paid' => OrdersCheckpoints::IS_PAID, + 'pocket_paid_at' => $now, + // 'pocket_paid_by' => $req->auth->id, + 'bank_id' => $order[0]->drv_bank_id, + 'bank_name' => $order[0]->drv_bank_name, + 'bank_code' => $order[0]->drv_bank_code, + 'bank_short_name' => $order[0]->drv_bank_short_name, + 'bank_branch_name' => $order[0]->drv_bank_branch_name ?? null, + 'bank_acc_name' => $order[0]->drv_bank_acc_name, + 'bank_acc_number' => $order[0]->drv_bank_acc_number, + 'tf_method' => OrdersCheckpoints::TF_METHOD_DANA, + 'tf_at' => $now, + 'tf_url' => $url, + 'tf_ref_code' => $bodyDana->data->dana_reference_no ?? 0, + 'tf_note' => $bodyDana->data->note ?? 0, + 'tf_req_data' => json_encode($json), + 'tf_resp_data' => json_encode($bodyDana), + ]); + Dana::updateDana($dana->id, ['amt' => DB::raw('amt-'.$historys[0]->pocket_total)]); + } + } catch (\GuzzleHttp\Exception\BadResponseException $e) { + $respDana = $e->getResponse(); + $bodyDana = json_decode($respDana->getBody()->getContents()); + // DB::rollBack(); + OrdersLogsTf::addLogsTf([ + 'ord_id' => $order[0]->ord_id, + 'ord_code' => $order[0]->ord_code, + 'type' => OrdersLogsTf::TYPE_TF_CHECKPOINT, + 'checkpoint_id' => $historys[0]->ord_checkpoint_id, + 'amount' => $historys[0]->pocket_total, + 'stts' => OrdersLogsTf::STTS_FAIL, + 'fail_at' => time(), + 'note' => $bodyDana->data->note, + 'bank_id' => $order[0]->drv_bank_id, + 'bank_name' => $order[0]->drv_bank_name, + 'bank_code' => $order[0]->drv_bank_code, + 'bank_short_name' => $order[0]->drv_bank_short_name, + 'bank_branch_name' => $order[0]->drv_bank_branch_name ?? null, + 'bank_acc_name' => $order[0]->drv_bank_acc_name, + 'bank_acc_number' => $order[0]->drv_bank_acc_number, + 'method' => OrdersLogsTf::METHOD_DANA, + 'url' => $url, + 'ref_code' => $bodyDana->data->dana_reference_no, + 'req_data' => json_encode($json), + 'resp_data' => json_encode($bodyDana), + 'crt' => time(), + 'updt' => time(), + ]); + OrdersCheckpoints::updateCheckpoint($historys[0]->ord_checkpoint_id, [ + 'pocket_is_paid' => OrdersCheckpoints::IS_TF_FAIL, + 'pocket_paid_note' => $bodyDana->data->note, + 'bank_id' => $order[0]->drv_bank_id, + 'bank_name' => $order[0]->drv_bank_name, + 'bank_code' => $order[0]->drv_bank_code, + 'bank_short_name' => $order[0]->drv_bank_short_name, + 'bank_branch_name' => $order[0]->drv_bank_branch_name ?? null, + 'bank_acc_name' => $order[0]->drv_bank_acc_name, + 'bank_acc_number' => $order[0]->drv_bank_acc_number, + 'tf_method' => OrdersCheckpoints::TF_METHOD_DANA, + 'tf_at' => $now, + 'tf_url' => $url, + 'tf_ref_code' => $bodyDana->data->dana_reference_no, + 'tf_note' => $bodyDana->data->note, + 'tf_req_data' => json_encode($json), + 'tf_resp_data' => json_encode($bodyDana), + ]); + $apiResp = Responses::bad_request('Gagal transfer ke rekening driver'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } else { + $url = env('API_URL_NODE') . '/order/finance_info_dana_amount'; + $guzReq = new GuzzleClient(); + $respNode = $guzReq->request('POST', $url, [ + 'headers' => [ + 'Host' => $_SERVER['SERVER_ADDR'] ?? '127.0.0.1', + 'User-Agent' => 'curl/7.65.3', + 'Accept' => '*/*', + 'Accept-Encoding' => 'gzip, deflate, br', + // 'Content-Type' => 'application/x-www-form-urlencoded; charset=UTF-8', + // 'Connection' => 'keep-alive', + ], + 'json' => [ + "trx_code" => $order[0]->ord_code, + "drv_name" => $order[0]->drv_name, + "pickup_zone_title" => $order[0]->pck_name, + "pickup_zone_addr" => $order[0]->pck_addr, + "drop_zone_title" => $order[0]->drop_name, + "drop_zone_addr" => $order[0]->drop_addr, + "pocket_total" => 'Rp'.number_format($historys[0]->pocket_total, 0, ',', '.'), + "bank_name" => $order[0]->drv_bank_name, + "bank_code" => $order[0]->drv_bank_code, + "bank_branch_name" => $order[0]->drv_bank_branch_name ?? '', + "bank_acc_name" => $order[0]->drv_bank_acc_name, + "bank_acc_no" => $order[0]->drv_bank_acc_number, + "admins" => $admins_data + ], + ]); + if ($respNode->getStatusCode() != 200) { + DB::rollBack(); + $apiResp = Responses::bad_request('gagal mengirim email ke finance'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + $body = json_decode($respNode->getBody()->getContents()); + } + + DB::commit(); + + $url = env('API_URL_NODE') . '/order/finance_info_tf_pocket'; + $guzReq = new GuzzleClient(); + $respNode = $guzReq->request('POST', $url, [ + 'headers' => [ + 'Host' => $_SERVER['SERVER_ADDR'] ?? '127.0.0.1', + 'User-Agent' => 'curl/7.65.3', + 'Accept' => '*/*', + 'Accept-Encoding' => 'gzip, deflate, br', + // 'Content-Type' => 'application/x-www-form-urlencoded; charset=UTF-8', + // 'Connection' => 'keep-alive', + ], + 'json' => [ + "trx_code" => $order[0]->ord_code, + "drv_name" => $order[0]->drv_name, + "pickup_zone_title" => $order[0]->pck_name, + "pickup_zone_addr" => $order[0]->pck_addr, + "drop_zone_title" => $order[0]->drop_name, + "drop_zone_addr" => $order[0]->drop_addr, + "pocket_total" => 'Rp'.number_format($historys[0]->pocket_total, 0, ',', '.'), + "bank_name" => $order[0]->drv_bank_name, + "bank_code" => $order[0]->drv_bank_code, + "bank_branch_name" => $order[0]->drv_bank_branch_name ?? '', + "bank_acc_name" => $order[0]->drv_bank_acc_name, + "bank_acc_no" => $order[0]->drv_bank_acc_number, + "admins" => $admins_data + ], + ]); + if ($respNode->getStatusCode() != 200) { + DB::rollBack(); + $apiResp = Responses::bad_request('gagal mengirim email ke finance'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + $body = json_decode($respNode->getBody()->getContents()); + + $apiResp = Responses::success('Berhasil transfer ulang'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } +} diff --git a/app/Http/Controllers/HomeController.php b/app/Http/Controllers/HomeController.php new file mode 100755 index 0000000..76dd11f --- /dev/null +++ b/app/Http/Controllers/HomeController.php @@ -0,0 +1,37 @@ +middleware('auth'); + // } + + /** + * Show the application dashboard. + * + * @return \Illuminate\Contracts\Support\Renderable + */ + public function index() + { + return view('home'); + } + + public function check_redirect() + { + if (Auth::guest()) { + return redirect(route('login')); + } + return redirect(route('view_dashboard')); + } +} diff --git a/app/Http/Controllers/InjectController.php b/app/Http/Controllers/InjectController.php new file mode 100755 index 0000000..5bdd327 --- /dev/null +++ b/app/Http/Controllers/InjectController.php @@ -0,0 +1,513 @@ + $req->Sheet1, + ]; + $rulesInput = [ + 'Sheet1' => 'required|array', + 'Sheet1.*.NAME' => 'required|string|max:255', + 'Sheet1.*.COMPANY' => 'required|string|max:255', + 'Sheet1.*.DIVISION' => 'required|string|max:255', + 'Sheet1.*.GROUP' => 'required|string|max:255', + 'Sheet1.*.TYPE' => 'required|string|max:255', + 'Sheet1.*.TYPE ID' => 'required|numeric', + 'Sheet1.*.COLOR' => 'required|string|min:7|max:7', + 'Sheet1.*.ADDRESS' => 'required|string', + 'Sheet1.*.SHIP-TO CODE' => 'nullable|string', + 'Sheet1.*.SHAPE' => 'required|numeric', + 'Sheet1.*.BOUNDARY' => 'required|string', + 'Sheet1.*.GEONAMES' => 'nullable|string', + 'Sheet1.*.COMPANIES' => 'nullable|string', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + DB::beginTransaction(); + + foreach ($req->Sheet1 as $keyTop => $row) { + $now = time(); + $zid = null; + $cid = Clients::DEFAULT_CID; + $c_div_id = ClientsDivs::DEFAULT_CID; + $c_div_group_id = ClientsDivGroups::DEFAULT_CID; + $uniqClient = Clients::getClientByName($row['COMPANY']); + if (count($uniqClient) > 0) { + $cid = $uniqClient[0]->id; + } else { + $insClient = [ + 'c_name' => $row['COMPANY'], + 'c_addr_office' => $row['ADDRESS'], + 'c_phone' => 81288789878, + 'c_phone_code' => Clients::DEFAULT_PHONE_CODE, + 'c_mail' => 'inject@gmail.com', + 'pic_name' => $row['COMPANY'], + 'pic_phone' => 81288789878, + 'pic_phone_code' => Clients::DEFAULT_PHONE_CODE, + 'pic_mail' => 'inject@gmail.com', + 'c_status' => Clients::CSTTS_ACTIVE, + 'crt' => $now, + 'crt_by' => Users::DEFAULT_UID, + 'updt' => $now, + 'updt_by' => Users::DEFAULT_UID, + ]; + $cid = Clients::addClient($insClient); + } + $uniqCDiv = ClientsDivs::getCDivByName($row['DIVISION']); + if (count($uniqCDiv) > 0) { + $c_div_id = $uniqCDiv[0]->id; + } else { + $insCDiv = [ + 'client_id' => $cid, + 'name' => $row['DIVISION'], + 'crt' => $now, + 'crt_by' => Users::DEFAULT_UID, + 'updt' => $now, + 'updt_by' => Users::DEFAULT_UID, + ]; + $c_div_id = ClientsDivs::addCDiv($insCDiv); + } + $uniqCDivGroup = ClientsDivGroups::getCDivGroupByName($row['GROUP']); + if (count($uniqCDivGroup) > 0) { + $c_div_group_id = $uniqCDivGroup[0]->id; + } + + $uniqZone = Zone::getZoneByName($row['NAME']); + if (count($uniqZone) > 0) { + $zid = $uniqZone[0]->id; + } else { + $boundary_latlngs = []; + $radius = 0; + $boundary_type = Zone::ZONE_BOUNDARY_POLYGON; + $workflow_type = Zone::ZONE_WORKFLOW_DEST; + + if (strpos(strtolower($row['TYPE']), 'bongkar') !== false) { + $workflow_type = Zone::ZONE_WORKFLOW_DEST; + } else if (strpos(strtolower($row['TYPE']), 'muat') !== false) { + $workflow_type = Zone::ZONE_WORKFLOW_PICKUP; + } else if (strpos(strtolower($row['TYPE']), 'park') !== false) { + $workflow_type = Zone::ZONE_WORKFLOW_PARKING; + } else if (strpos(strtolower($row['TYPE']), 'bengkel') !== false) { + $workflow_type = Zone::ZONE_WORKFLOW_SERVICE; + } + + $boundarys = explode('|', $row['BOUNDARY']); + foreach ($boundarys as $k => $v) { + $latLng = explode(',', $v); + $boundary_latlngs[] = [ + 'lat' => $latLng[0], + 'lng' => $latLng[1], + ]; + } + + $row['SHAPE']; // 1=>circle,0=>polygon + if ($row['SHAPE'] == 1) { + $boundary_type = Zone::ZONE_BOUNDARY_CIRCLE; + $radius = Helper::haversineGreatCircleDistance($boundary_latlngs[0]['lat'], $boundary_latlngs[0]['lng'], $boundary_latlngs[1]['lat'], $boundary_latlngs[1]['lng']); + } + + $insZone = [ + 'name' => $row['NAME'], + 'type' => Zone::ZONE_TYPE_WAREHOUSE, + 'workflow_type' => $workflow_type, + 'shiptocode' => 0, + 'fulladdress' => $row['ADDRESS'], + 'boundary_type' => $boundary_type, + 'boundary_hex_color' => strtoupper($row['COLOR']), + 'boundary_latlngs' => json_encode($boundary_latlngs), + 'boundary_bounds' => null, + 'boundary_radius' => $radius, + 'status' => Zone::STATUS_ACTIVE, + 'client_group_id' => $cid, + 'crt' => $now, + 'crt_by' => Users::DEFAULT_UID, + 'updt' => $now, + 'updt_by' => Users::DEFAULT_UID, + ]; + $insZone['boundary_points'] = "ST_GeomFromText('MULTIPOINT("; + foreach ($boundary_latlngs as $key => $val) { + $insZone['boundary_points'] .= $val['lng'] . " " . $val['lat'] . ", "; + } + $insZone['boundary_points'] = substr($insZone['boundary_points'], 0, -2); // remove 2 last character + $insZone['boundary_points'] .= ")')"; + $insZone['boundary_points'] = DB::raw($insZone['boundary_points']); + + // dump($insZone); + // if ($keyTop == 5) { + // dd('stop'); + // } + $zoneId = Zone::addZone($insZone); + } + } + + $apiResp = Responses::created('success inject add new zone'); + + DB::commit(); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + // B_8074_AS_Positions_01-Feb-2022_06-Feb-2022.xlsx + /** + * 00000000AB8021AS == 0000000128021119 + * 000000000B8026AS == 0000000028026119 + * 000000000B8038AS == 0000000028038119 + * 000000000B8074AS == 0000000028074119 + * 000000000B8129AS == 0000000028129119 + * 000000000B8224AS == 0000000028223119 + */ + public function add_vhc_tracks_v1(Request $req) + { + try { + $now = time(); + + $apiResp = Responses::bad_request('service unavailable'); + return (new Response($apiResp, $apiResp['meta']['code'])); + + $input = [ + 'Sheet1' => $req->Sheet1, + ]; + $rulesInput = [ + 'Sheet1' => 'required|array', + 'Sheet1.*.DIVISION' => 'required|string|max:255', + 'Sheet1.*.GROUP' => 'required|string|max:255', + 'Sheet1.*.TIMESTAMP' => 'required|string|max:255', + 'Sheet1.*.VEHICLE' => 'required|string|max:12', + 'Sheet1.*.DRIVER' => 'nullable|string', + 'Sheet1.*.ZONE' => 'nullable|string', + 'Sheet1.*.LOCATION' => 'required|string', + 'Sheet1.*.LATITUDE' => 'required|string|max:25', + 'Sheet1.*.LONGITUDE' => 'required|string|max:25', + 'Sheet1.*.SPEED (kph)' => 'required|numeric', + 'Sheet1.*.COURSE (°)' => 'required|numeric', + 'Sheet1.*.IGINITION' => 'nullable|string|max:2', + 'Sheet1.*.ENGINE STATUS' => 'required|string|max:25', + 'Sheet1.*.VEHICLE MILEAGE (km)' => 'required|string', + 'Sheet1.*.FUEL LEVEL (%)' => 'nullable|numeric', + 'Sheet1.*.POWER TAKEOFF' => 'nullable|numeric', + ]; + // pre_milleage, sum_milleage + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + DB::beginTransaction(); + + foreach ($req->Sheet1 as $key => $row) { + $now = time(); + $track_id = null; + + $crt = strtotime($row['TIMESTAMP']); + $crt_format = date('Y-m-d h:i:s', $crt); + + // $nopol = explode(' ', $row['VEHICLE']); + $device_id = '0000000028223119'; // 16 digits + + $ignition = null; + if ($row['IGNITION'] == 'ON') { + $ignition = 1; + } else { + $ignition = 2; + } + + $en_status = null; + if ($row['ENGINE STATUS'] == 'Moving') { + $en_status = 2; // moving + } else { + $en_status = 1; // idling + } + + $insTracks = [ + 'original_hex' => '78781f12', + 'protocol' => 'gt06', + 'action' => 'location', + 'device_id' => $device_id, + 'latitude' => $row['LATITUDE'], + 'longitude' => $row['LONGITUDE'], + 'speed' => $row['SPEED (kph)'] ?? null, + 'orientation' => $row['COURSE (°)'] ?? null, + 'ignition' => $ignition, // 1 on, 2 off. + 'stts_engine' => $en_status, // 1 idling, 2 moving + 'stts_reverse_geo' => 1, // 1 sudah reverse + 'pre_milleage' => null, + 'sum_milleage' => $row['VEHICLE MILEAGE (km)'], + 'crt' => $crt, + 'crt_format' => $crt_format, + ]; + $track_id = Tracks::addTracks($insTracks); + + $insTracksAddr = [ + 'master_id' => $track_id, + 'device_id' => $device_id, + 'type' => 2, // inject + 'lat' => $row['LATITUDE'], + 'lng' => $row['LONGITUDE'], + 'zone_name' => $row['ZONE'] ?? null, + 'country_id' => 1, + 'country_code' => 'id', + 'country_text' => 'INDONESIA', + 'fulladdress' => $row['LOCATION'] ?? null, + 'stts_reverse_geo' => 1, // 1 sudah reverse + 'crt' => $crt, + 'crt_format' => $crt_format, + ]; + Tracks::addTracksAddr($insTracksAddr); + } + + $apiResp = Responses::created('success inject add new tracks'); + + DB::commit(); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + // Publish Rate Bingkis.xlsx + public function add_conf_rate_v1(Request $req) + { + try { + $apiResp = Responses::bad_request('service unavailable'); + return (new Response($apiResp, $apiResp['meta']['code'])); + + $now = time(); + + // $exists = Storage::disk('local')->get('PublishRateBingkis.xlsx'); + // dd($exists); + + // $file = fopen(__DIR__.'/../../../storage/app/PublishRateBingkis.xlsx', 'r'); + // //Output lines until EOF is reached + // while(! feof($file)) { + // $line = fgets($file); + // echo $line. "
"; + // } + // fclose($file); + // return false; + + // dd($req->input()); + + // DB::beginTransaction(); + + $lanes = ConfRates::getLanesActive(); + + foreach ($req['Publish Rate'] as $keyTop => $row) { + $nanoid = new Nanoid(); + $code = $nanoid->formattedId('123456789', 6); + + $uniqCode = ConfRates::getRateByCode($code); + if (count($uniqCode) > 0) { + $code = $nanoid->formattedId('123456789', 6); + $uniqCode = ConfRates::getRateByCode($code); + if (count($uniqCode) > 0) { + $code = $nanoid->formattedId('123456789', 6); + $uniqCode = ConfRates::getRateByCode($code); + if (count($uniqCode) > 0) { + $code = $nanoid->formattedId('123456789', 6); + } + } + } + + $lead_time = explode('-', $row['Lead Time']); + $fast_time = trim($lead_time[0]); + if (count($lead_time) == 1) { + $long_time = trim($lead_time[0]); + } else { + $long_time = trim(explode('hari', $lead_time[1])[0]); + } + + $lane_id = 0; + foreach ($lanes as $k => $v) { + if ($lane_id === 0) { + if (strpos($v->name, $row['Via']) !== false) { + $lane_id = $v->id; + } + } + } + + $prid = Region::getLikeProv($row['Dest Province']); + if ($prid) { + $prid = $prid[0]->kodeProv; + } else { + $prid = 0; + } + + $city_name = $row['Dest City']; + $district_name = $row['Dest City']; + if (strpos($row['Dest City'], '(') !== false) { + $part = explode('(', $row['Dest City']); + $pos = strpos($part[1], ')'); + $part[1] = substr($part[1], 0, $pos); + + $district_name = trim($part[0]); + $city_name = trim($part[1]); + } + + $ktid = Region::getLikeCity($city_name); + if ($ktid) { + $kodeKab = 0; + foreach ($ktid as $city) { + if ($city->kodeProv == $prid) { + $kodeKab = $city->kodeKab; + } + } + $ktid = $kodeKab; + } else { + $ktid = 0; + } + $kcid = Region::getLikeDistrict($district_name); + if ($kcid) { + $kodeKab = $ktid; + $kodeKec = 0; + foreach ($kcid as $district) { + if ($district->kodeProv == $prid) { + if ($kodeKab === 0) { + $kodeKab = $district->kodeKab; + $kodeKec = $district->kodeKec; + } else { + if ($kodeKab === $district->kodeKab) { + $kodeKec = $district->kodeKec; + } + } + $kodeKec = $district->kodeKec; + } + } + $ktid = $kodeKab; + $kcid = $kodeKec; + } else { + $kcid = 0; + } + + if ($ktid === 0) { + $city_name = trim($part[0]); + $district_name = trim($part[1]); + + $ktid = Region::getLikeCity($city_name); + if ($ktid) { + $kodeKab = 0; + foreach ($ktid as $city) { + if ($city->kodeProv == $prid) { + $kodeKab = $city->kodeKab; + } + } + $ktid = $kodeKab; + } else { + $ktid = 0; + } + $kcid = Region::getLikeDistrict($district_name); + if ($kcid) { + $kodeKab = $ktid; + $kodeKec = 0; + foreach ($kcid as $district) { + if ($district->kodeProv == $prid) { + if ($kodeKab === 0) { + $kodeKab = $district->kodeKab; + $kodeKec = $district->kodeKec; + } else { + if ($kodeKab === $district->kodeKab) { + $kodeKec = $district->kodeKec; + } + } + $kodeKec = $district->kodeKec; + } + } + $ktid = $kodeKab; + $kcid = $kodeKec; + } else { + $kcid = 0; + } + } + + $insRate = [ + 'code' => $code, + 'origin_prov' => 31, + // 'origin_city' => $row->origin_city, + 'lane' => $lane_id, + 'dest_prov' => $prid, + 'dest_city' => $ktid, + 'dest_district' => $kcid, + 'fast_time' => $fast_time, + 'long_time' => $long_time, + 'unit_time' => ConfRates::UNIT_DAY, + 'sell_kg' => (int)str_replace(',', '', str_replace('Rp', '', $row['Sell KG'])), + 'buy_kg' => (int)str_replace(',', '', str_replace('Rp', '', $row['Buy KG'])), + 'margin_kg' => (int)str_replace(',', '', str_replace('Rp', '', $row['Margin'])), + 'percent_kg' => number_format(str_replace('%', '', $row['Persentase']), 2, '.', ','), + 'sell_cbm' => (int)str_replace(',', '', str_replace('Rp', '', $row[' Sell CBM '])), + 'buy_cbm' => (int)str_replace(',', '', str_replace('Rp', '', $row[' Buy CBM '])), + 'margin_cbm' => (int)str_replace(',', '', str_replace('Rp', '', $row['Margin_1'])), + 'percent_cbm' => number_format(str_replace('%', '', $row['Persentase_1']), 2, '.', ','), + 'is_active' => ConfRates::IS_ACTIVE, + 'crt' => $now, + 'crt_by' => 1, + 'updt' => $now, + 'updt_by' => 1, + ]; + + // dump($insRate); + // if ($keyTop > 5) { + // dd('stop'); + // } + $rid = ConfRates::addRate($insRate); + } + + $apiResp = Responses::created('success inject add new conf rate'); + + // DB::commit(); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } +} diff --git a/app/Http/Controllers/InsuranceController.php b/app/Http/Controllers/InsuranceController.php new file mode 100755 index 0000000..5db9495 --- /dev/null +++ b/app/Http/Controllers/InsuranceController.php @@ -0,0 +1,254 @@ +passes()) { + // $apiResp = Responses::bad_input($isValidInput->messages()->first()); + // return new Response($apiResp, $apiResp['meta']['code']); + // } + + $list = Insurances::listInsurances(); + foreach ($list as $key => $row) { + $list[$key]->DT_RowIndex = $key + 1; + $list[$key]->action = '-'; + } + + $apiResp = Responses::success('success list insurances'); + $apiResp['count'] = count($list); + $apiResp['data'] = $list; + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_show_insurance(Request $req, $iid) + { + try { + $now = time(); + + $input = [ + 'iid' => $iid, + ]; + $rulesInput = [ + 'iid' => 'required|integer|not_in:0', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $insurance = Insurances::showInsuranceById($iid); + if (count($insurance) < 1) { + $apiResp = Responses::not_found('insurance not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + $apiResp = Responses::success('success get detail insurance'); + $apiResp['data'] = $insurance[0]; + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_add_insurance(Request $req) + { + try { + $now = time(); + + $input = [ + 'name' => $req->name, + 'desc' => $req->desc, + 'price' => $req->price, + 'min_price' => $req->min_price, + 'max_price' => $req->max_price, + 'status' => $req->status, + ]; + $rulesInput = [ + 'name' => 'required|string', + 'desc' => 'nullable|string', + 'price' => 'required|numeric|min:0', + 'min_price' => 'required|numeric|min:0', + 'max_price' => 'required|numeric|min:0', + 'status' => 'required|numeric|min:0', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + DB::beginTransaction(); + + $insInsurance = [ + 'premi_name' => $req->name, + 'desc' => $req->desc, + 'premi_price' => $req->price, + 'premi_min_price' => $req->min_price, + 'premi_max_price' => $req->max_price, + 'is_active' => $req->status, + 'crt' => $now, + 'crt_by' => $req->auth->uid, + 'updt' => $now, + 'updt_by' => $req->auth->uid, + ]; + $iid = Insurances::addInsurance($insInsurance); + + $apiResp = Responses::created('success add new insurance'); + + DB::commit(); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_edit_insurance(Request $req, $iid) + { + try { + $now = time(); + + $input = [ + 'iid' => $iid, + 'name' => $req->name, + 'desc' => $req->desc, + 'price' => $req->price, + 'min_price' => $req->min_price, + 'max_price' => $req->max_price, + 'status' => $req->status, + ]; + $rulesInput = [ + 'iid' => 'required|integer|not_in:0', + 'name' => 'required|string', + 'desc' => 'nullable|string', + 'price' => 'required|numeric|min:0', + 'min_price' => 'required|numeric|min:0', + 'max_price' => 'required|numeric|min:0', + 'status' => 'required|numeric|min:0', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $insurance = Insurances::showInsuranceById($iid); + if (count($insurance) < 1) { + $apiResp = Responses::not_found('insurance not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + DB::beginTransaction(); + + $updtInsurance = [ + 'premi_name' => $req->name, + 'desc' => $req->desc, + 'premi_price' => $req->price, + 'premi_min_price' => $req->min_price, + 'premi_max_price' => $req->max_price, + 'is_active' => $req->status, + 'updt' => $now, + 'updt_by' => $req->auth->uid, + ]; + if ($req->dest_district) { + $updtInsurance['dest_district'] = $req->dest_district; + } + $iid = Insurances::updateInsurance($iid, $updtInsurance); + + $apiResp = Responses::created('success update insurance'); + + DB::commit(); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_del_insurance(Request $req, $iid) + { + try { + $now = time(); + + $input = [ + 'iid' => $iid, + ]; + $rulesInput = [ + 'iid' => 'required|integer|not_in:0', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $insurance = Insurances::showInsuranceById($iid); + if (count($insurance) < 1) { + $apiResp = Responses::not_found('insurance not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + DB::beginTransaction(); + + Insurances::updateInsurance($iid, [ + 'dlt' => $now, + 'dlt_by' => $req->auth->uid, + ]); + + DB::commit(); + + $apiResp = Responses::success('success delete insurance'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } +} diff --git a/app/Http/Controllers/LogbookKeysController.php b/app/Http/Controllers/LogbookKeysController.php new file mode 100755 index 0000000..e4acdfa --- /dev/null +++ b/app/Http/Controllers/LogbookKeysController.php @@ -0,0 +1,312 @@ + LogbookTypes::listLgbTypes(['is_active' => LogbookTypes::IS_ACTIVE]), + 'dtypes' => DataTypes::listDataTypes(['is_active' => DataTypes::IS_ACTIVE]), + ]; + + return view('menu_v1.logbook_keys', $data); + } + + + /** + * API + */ + + public function api_list_lgb_keys(Request $req) + { + try { + $now = time(); + $input = [ + 'cptid' => $req->cptid, + 'is_active' => $req->is_active, + ]; + $rulesInput = [ + 'cptid' => 'nullable|numeric', + 'is_active' => 'nullable|numeric', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + $filter = []; + if ($input['cptid'] != null && $input['cptid'] != 0) { + $filter['cptid'] = $input['cptid']; + } + if ($input['is_active'] != null && $input['is_active'] != 0) { + $filter['is_active'] = $input['is_active']; + } + + $list = LogbookKeys::listLgbKeys($filter); + foreach ($list as $key => $row) { + $list[$key]->DT_RowIndex = $key + 1; + $list[$key]->action = '-'; + } + + $apiResp = Responses::success('success list lgb_keys'); + $apiResp['count'] = count($list); + $apiResp['data'] = $list; + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_show_lgb_key(Request $req, $lgb_key_id) + { + try { + $now = time(); + + $input = [ + 'lgb_key_id' => $lgb_key_id, + ]; + $rulesInput = [ + 'lgb_key_id' => 'required|integer|not_in:0', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $lgb_key = LogbookKeys::showLgbKey(['lgb_key_id' => $lgb_key_id]); + if (count($lgb_key) < 1) { + $apiResp = Responses::not_found('logbook master not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + $apiResp = Responses::success('success get detail logbook master'); + $apiResp['data'] = $lgb_key[0]; + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_add_lgb_key(Request $req) + { + try { + $now = time(); + + $input = [ + 'name' => $req->add_name, + 'type' => $req->add_type, + 'keys' => $req->add_keys, + 'units' => $req->add_units, + 'dtypes' => $req->add_dtypes, + 'status' => $req->status, + ]; + $rulesInput = [ + 'name' => 'required|string|max:255', + 'type' => 'required|numeric|min:0', + 'keys' => 'required|array', + 'units' => 'required|array', + 'dtypes' => 'required|array', + 'status' => 'required|numeric|min:0', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + DB::beginTransaction(); + + $insLgbKey = [ + 'name' => $input['name'], + 'type' => $input['type'], + 'keys' => json_encode($input['keys']), + 'units' => json_encode($input['units']), + 'dtypes' => json_encode($input['dtypes']), + 'is_active' => $input['status'], + 'crt' => $now, + 'crt_by' => $req->auth->uid, + 'updt' => $now, + 'updt_by' => $req->auth->uid, + ]; + $lgb_key_id = LogbookKeys::addLgbKey($insLgbKey); + + $apiResp = Responses::created('success add new logbook master'); + + DB::commit(); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_edit_lgb_key(Request $req, $lgb_key_id) + { + try { + $now = time(); + + $input = [ + 'lgb_key_id' => $lgb_key_id, + 'name' => $req->updt_name, + 'type' => $req->updt_type, + 'keys' => $req->updt_keys, + 'units' => $req->updt_units, + 'dtypes' => $req->updt_dtypes, + 'status' => $req->status, + ]; + $rulesInput = [ + 'lgb_key_id' => 'required|integer|not_in:0', + 'name' => 'required|string|max:255', + 'type' => 'required|numeric|min:0', + 'keys' => 'required|array', + 'units' => 'required|array', + 'dtypes' => 'required|array', + 'status' => 'required|numeric|min:0', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $lgb_key = LogbookKeys::showLgbKey(['lgb_key_id' => $lgb_key_id]); + if (count($lgb_key) < 1) { + $apiResp = Responses::not_found('logbook master not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + DB::beginTransaction(); + + $updtPocket = [ + 'name' => $input['name'], + 'type' => $input['type'], + 'keys' => json_encode($input['keys']), + 'units' => json_encode($input['units']), + 'dtypes' => json_encode($input['dtypes']), + 'is_active' => $input['status'], + 'updt' => $now, + 'updt_by' => $req->auth->uid, + ]; + LogbookKeys::updateLgbKey($input['lgb_key_id'], $updtPocket); + + $apiResp = Responses::created('success update logbook master'); + + DB::commit(); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_del_lgb_key(Request $req, $lgb_key_id) + { + try { + $now = time(); + + $input = [ + 'lgb_key_id' => $lgb_key_id, + ]; + $rulesInput = [ + 'lgb_key_id' => 'required|integer|not_in:0', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $lgb_key = LogbookKeys::showLgbKey(['lgb_key_id' => $lgb_key_id]); + if (count($lgb_key) < 1) { + $apiResp = Responses::not_found('logbook master not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + DB::beginTransaction(); + + LogbookKeys::updateLgbKey($lgb_key_id, [ + 'dlt' => $now, + 'dlt_by' => $req->auth->uid, + ]); + + DB::commit(); + + $apiResp = Responses::success('success delete logbook master'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_selection_lgb_keys(Request $req) + { + try { + $now = time(); + $input = [ + 'is_active' => $req->is_active, + ]; + $rulesInput = [ + 'is_active' => 'nullable|numeric', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + $filter = []; + if ($input['is_active'] != null && $input['is_active'] != 0) { + $filter['is_active'] = $input['is_active']; + } + + $list = LogbookKeys::listLgbKeys($filter); + foreach ($list as $key => $row) { + $list[$key]->DT_RowIndex = $key + 1; + $list[$key]->action = '-'; + } + + $apiResp = Responses::success('success list logbook master'); + $apiResp['count'] = count($list); + $apiResp['data'] = $list; + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } +} diff --git a/app/Http/Controllers/LogbookTypesController.php b/app/Http/Controllers/LogbookTypesController.php new file mode 100755 index 0000000..1efa31d --- /dev/null +++ b/app/Http/Controllers/LogbookTypesController.php @@ -0,0 +1,278 @@ + $req->cptid, + ]; + $rulesInput = [ + 'cptid' => 'nullable|numeric' + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + $filter = []; + if ($input['cptid'] != null && $input['cptid'] != 0) { + $filter['cptid'] = $input['cptid']; + } + + $list = LogbookTypes::listLgbTypes($filter); + foreach ($list as $key => $row) { + $list[$key]->DT_RowIndex = $key + 1; + $list[$key]->action = '-'; + } + + $apiResp = Responses::success('success list lgb_types'); + $apiResp['count'] = count($list); + $apiResp['data'] = $list; + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_show_lgb_type(Request $req, $lgb_type_id) + { + try { + $now = time(); + + $input = [ + 'lgb_type_id' => $lgb_type_id, + ]; + $rulesInput = [ + 'lgb_type_id' => 'required|integer|not_in:0', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $lgb_type = LogbookTypes::showLgbType(['lgb_type_id' => $lgb_type_id]); + if (count($lgb_type) < 1) { + $apiResp = Responses::not_found('logbook type not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + $apiResp = Responses::success('success get detail logbook type'); + $apiResp['data'] = $lgb_type[0]; + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_add_lgb_type(Request $req) + { + try { + $now = time(); + + $input = [ + 'name' => $req->add_name, + 'status' => $req->status, + ]; + $rulesInput = [ + 'name' => 'required|string|max:255', + 'status' => 'required|numeric|min:0', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + DB::beginTransaction(); + + $insLgbType = [ + 'name' => $input['name'], + 'is_active' => $input['status'], + 'crt' => $now, + 'crt_by' => $req->auth->uid, + 'updt' => $now, + 'updt_by' => $req->auth->uid, + ]; + $lgb_type_id = LogbookTypes::addLgbType($insLgbType); + + $apiResp = Responses::created('success add new lgb_type'); + + DB::commit(); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_edit_lgb_type(Request $req, $lgb_type_id) + { + try { + $now = time(); + + $input = [ + 'lgb_type_id' => $lgb_type_id, + 'name' => $req->updt_name, + 'status' => $req->status, + ]; + $rulesInput = [ + 'lgb_type_id' => 'required|integer|not_in:0', + 'name' => 'required|string|max:255', + 'status' => 'required|numeric|min:0', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $lgb_type = LogbookTypes::showLgbType(['lgb_type_id' => $lgb_type_id]); + if (count($lgb_type) < 1) { + $apiResp = Responses::not_found('logbook type not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + DB::beginTransaction(); + + $updtPocket = [ + 'name' => $input['name'], + 'is_active' => $input['status'], + 'updt' => $now, + 'updt_by' => $req->auth->uid, + ]; + LogbookTypes::updateLgbType($input['lgb_type_id'], $updtPocket); + + $apiResp = Responses::created('success update logbook type'); + + DB::commit(); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_del_lgb_type(Request $req, $lgb_type_id) + { + try { + $now = time(); + + $input = [ + 'lgb_type_id' => $lgb_type_id, + ]; + $rulesInput = [ + 'lgb_type_id' => 'required|integer|not_in:0', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $lgb_type = LogbookTypes::showLgbType(['lgb_type_id' => $lgb_type_id]); + if (count($lgb_type) < 1) { + $apiResp = Responses::not_found('logbook type not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + DB::beginTransaction(); + + LogbookTypes::updateLgbType($lgb_type_id, [ + 'dlt' => $now, + 'dlt_by' => $req->auth->uid, + ]); + + DB::commit(); + + $apiResp = Responses::success('success delete logbook type'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_selection_lgb_types(Request $req) + { + try { + $now = time(); + $input = [ + 'is_active' => $req->is_active, + ]; + $rulesInput = [ + 'is_active' => 'nullable|numeric', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + $filter = []; + if ($input['is_active'] != null && $input['is_active'] != 0) { + $filter['is_active'] = $input['is_active']; + } + + $list = LogbookTypes::listLgbTypes($filter); + foreach ($list as $key => $row) { + $list[$key]->DT_RowIndex = $key + 1; + $list[$key]->action = '-'; + } + + $apiResp = Responses::success('success list logbook type'); + $apiResp['count'] = count($list); + $apiResp['data'] = $list; + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } +} diff --git a/app/Http/Controllers/LoggerController.php b/app/Http/Controllers/LoggerController.php new file mode 100755 index 0000000..a404112 --- /dev/null +++ b/app/Http/Controllers/LoggerController.php @@ -0,0 +1,75 @@ + $req->label, + 'level' => $req->level, + 'logtype' => $req->logtype, + 'keys' => $req->keys, + 'act' => 'email', + 'to' => ['rafifmreswara@gmail.com'], + 'errors' => $req->errors, + 'vers' => '1.2.1', + 'source' => 'service', + 'payloads' => $req->payloads, + ]; + $rulesInput = [ + 'label' => 'required|string', + 'level' => 'required|numeric', + 'logtype' => 'required|string', + 'keys' => 'required|array', + 'act' => 'required|string', + 'to' => 'nullable|array', + 'errors' => 'nullable|string', + 'vers' => 'required|string', + 'source' => 'required|string', + 'payloads' => 'nullable|string', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $payload = Helper::createPayload([ + 'usnme' => 'rafif', + 'paswd' => 12345678 + ]); + $login = Helper::req_post('https://api.simerahputih.com/logger/login', [ + 'Content-Type: application/x-www-form-urlencoded', + ], $payload); + + // $payload = Helper::createPayload($input); + // dd($payload); + $resp = Helper::req_post('https://api.simerahputih.com/logger/log', [ + 'Content-Type: application/json', + 'x-api-key: ' . $login['data']->data->token + ], json_encode($input)); + + $apiResp = Responses::success('success send log'); + return new Response($apiResp, $apiResp['meta']['code']); + } catch (\Exception $e) { + dd($e); + } + } +} diff --git a/app/Http/Controllers/MenuController.php b/app/Http/Controllers/MenuController.php new file mode 100755 index 0000000..054ad5a --- /dev/null +++ b/app/Http/Controllers/MenuController.php @@ -0,0 +1,900 @@ + Clients::getClientById($req->auth->client_group_id), + ]; + + if (count($data["client_group"]) > 0) { + $data["client_group"] = $data["client_group"][0]; + } else { + $data["client_group"] = null; + } + + return view("menu_v1.dashboard", $data); + } + + public function view_drivers(Request $req) + { + $data = [ + "bloods" => Helper::listBloods(), + "relationships" => Drivers::listRelationships(), + "vendors" => Users::listUsersByRole(Users::ROLE_VENDOR), + "banks" => Banks::listBanks(["is_active" => Banks::IS_ACTIVE]), + ]; + return view("menu_v1.drivers", $data); + } + + public function view_vehicles(Request $req) + { + $data = [ + // 'cats' => Vehicles::listCats(), // default Truck + "brands" => Vehicles::listBrands(), + "types" => Vehicles::listTypes(), + "drivers" => Drivers::getDrivers($req->auth), + "vendors" => Users::listUsersByRole(Users::ROLE_VENDOR), + "devices" => Devices::listDevices([ + "is_active" => Devices::IS_ACTIVE, + "type" => Devices::TYPE_BUILT_IN, + "is_idle_yes" => 1, + "is_available" => Devices::IS_AVAIL, + ]), + ]; + // dd($data); + return view("menu_v1.vehicles", $data); + } + + /** + * ADMIN TRX + */ + + public function view_transactions() + { + $data = [ + "availOrdToMerge" => Finance::availOrdToMerge(), + ]; + return view("menu_v1.transactions", $data); + } + public function view_transactions_view__bak(Request $req) + { + $codes = explode(",", $req->code); + $limit = count($codes); + if ($limit > 2) { + return redirect(route("view_transactions")); + } + // dd($codes[0]); + $orders = Orders::showOrder([ + "codes" => $codes, + "get_stts_checker" => 1, + "get_checker_data" => 1, + "get_checker_user" => 1, + // 'get_prefer_type_truck' => 1, + "get_additional_vehicles_info" => 1, + "get_accidents" => 1, + "couple_pck_drop" => 1, + "get_user_aprv_pck" => 1, + "group_by" => "ord.id", + "limit" => $limit, + ]); + // dd($orders); + if (count($orders) < 1) { + return redirect(route("view_transactions")); + } + + // uang saku / pocket money + $checkpoints = OrdersCheckpoints::listCheckpoints([ + "ord_id" => $orders[0]->ord_id, + ]); + + $bladeViewOrders = []; + foreach ($orders as $iOrd => $order) { + // get multiple point (pick,drop) + $adtPoints = Orders::getPoints([ + "id" => $order->ord_id, + "limit" => $order->drop_total, + ]); + // hilangkan index 0, karena yang didapatkan adalah childnya + array_splice($adtPoints, 0, 1); + $orders[$iOrd]->adtPoints = $adtPoints; + + // uang saku / pocket money + $orders[$iOrd]->checkpoints = $checkpoints; + + // formated for blade views + $tmpBladeView = clone $order; + if ($order->ord_pck_docs_client_img) { + $tmpBladeView->ord_pck_docs_client_img = json_decode($order->ord_pck_docs_client_img); + } + if ($order->ord_acdnt_imgs) { + $tmpBladeView->ord_acdnt_imgs = json_decode($order->ord_acdnt_imgs); + } + $bladeViewOrders[] = clone $tmpBladeView; + } + $drvs_ups = OrdersDriversUploads::list([ + "ord_id" => $orders[0]->ord_id, + "pck_id" => $orders[0]->ord_pck_id, + "drop_id" => $orders[0]->ord_drop_id, + "ord_pck_drop_id" => $orders[0]->ord_pck_drop_id, + ]); + $data = [ + "orders" => $orders, + "bladeViewOrders" => $bladeViewOrders, + "drvs_ups" => $drvs_ups, + "items" => AItems::listAItems([ + "is_active" => AItems::IS_ACTIVE, + "is_adm_price" => AItems::IS_ADM_PRICE_NO, + "crt_type" => AItems::CRT_TYPE_ADMIN, + ]), + "unitTypes" => UnitTypes::listUnitTypes([ + "is_active" => UnitTypes::IS_ACTIVE, + "is_publish" => UnitTypes::IS_PUBLISH, + ]), + "banks" => Banks::listBanks(["is_active" => Banks::IS_ACTIVE]), + ]; + return view("menu_v1._viewTransactions", $data); + } + public function view_transactions_view(Request $req) + { + $codes = explode(",", $req->code); + $limit = count($codes); + if ($limit > 2) { + return redirect(route("view_transactions")); + } + $orders = Orders::showOrder([ + "codes" => $codes, + "get_stts_checker" => 1, + "get_checker_data" => 1, + "get_checker_user" => 1, + // 'get_prefer_type_truck' => 1, + "get_additional_vehicles_info" => 1, + "get_accidents" => 1, + "group_by" => "ord.id", + "limit" => $limit, + ]); + + if (count($orders) < 1) { + return redirect(route("view_transactions")); + } + $bladeViewOrders = []; + foreach ($orders as $iOrd => $order) { + // get multiple point (pick,drop) + $adtPoints = Orders::getPoints([ + "id" => $order->ord_id, + "limit" => $order->drop_total, + ]); + // hilangkan index 0, karena yang didapatkan adalah childnya + array_splice($adtPoints, 0, 1); + $orders[$iOrd]->adtPoints = $adtPoints; + // dd($adtPoints); + // formated for blade views + $tmpBladeView = clone $order; + if ($order->ord_pck_docs_client_img) { + $tmpBladeView->ord_pck_docs_client_img = json_decode($order->ord_pck_docs_client_img); + } + if ($order->ord_acdnt_imgs) { + $tmpBladeView->ord_acdnt_imgs = json_decode($order->ord_acdnt_imgs); + } + $bladeViewOrders[] = clone $tmpBladeView; + } + + $rawData = DB::table("t_orders_pck_drop as topd") + ->leftJoin("t_orders_pickups as top", "top.id", "topd.pck_id") + ->leftJoin("t_orders_drops as tod", "tod.id", "topd.drop_id") + ->where("topd.ord_code", $codes) + ->selectRaw( + "topd.id, + FROM_UNIXTIME(top.set_pck_at, '%d %M %Y') as pck_date, + FROM_UNIXTIME(top.set_pck_at, '%H:%i:%s') as pck_time, + top.pck_name, + top.pck_addr, + tod.drop_name, + tod.drop_addr" + ) + ->get(); + foreach ($rawData as $_data) { + $ehck = DB::table("t_orders_drivers_uploads") + ->select( + "id", // + "checklist_name", + "checklist_desc", + "img", + "updt" + ) + ->where("ord_pck_drop_id", $_data->id) + ->get(); + $data[] = [ + "id" => $_data->id, + "pck_date" => $_data->pck_date, + "pck_time" => $_data->pck_time, + "pck_name" => $_data->pck_name, + "pck_addr" => $_data->pck_addr, + "drop_name" => $_data->drop_name, + "drop_addr" => $_data->drop_addr, + "checklist_array" => $ehck, + ]; + } + // dd($data[0]["checklist_array"]); + // dd($data); + $data = [ + "data" => $data, + "orders" => $orders, + "bladeViewOrders" => $bladeViewOrders, + ]; + // dd($data); + return view("menu_v1._viewTransactions", $data); + } + public function view_transactions_view_bak_single(Request $req) + { + $codes = explode(",", $req->code); + $order = Orders::showOrder([ + "code" => $codes[0], + "get_stts_checker" => 1, + "get_checker_data" => 1, + "get_checker_user" => 1, + // 'get_prefer_type_truck' => 1, + "get_additional_vehicles_info" => 1, + "get_accidents" => 1, + ]); + if (count($order) < 1) { + return redirect(route("view_transactions")); + } + $cantConfirmPrice = [Orders::STTS_WAIT, Orders::STTS_CONFIRM, Orders::STTS_HAVE_GET_VHC]; + $show_confirm_price = 1; + if (in_array($order[0]->status, $cantConfirmPrice)) { + $show_confirm_price = 0; + } + $adtPoints = Orders::getPoints([ + "id" => $order[0]->ord_id, + "limit" => $order[0]->drop_total, + ]); + array_splice($adtPoints, 0, 1); + $data = [ + "order" => $order[0], + "adtPoints" => $adtPoints, + "adtPointsJson" => json_encode($adtPoints), + "items" => AItems::listAItems([ + "is_active" => AItems::IS_ACTIVE, + "is_adm_price" => AItems::IS_ADM_PRICE_NO, + "crt_type" => AItems::CRT_TYPE_ADMIN, + ]), + "unitTypes" => UnitTypes::listUnitTypes([ + "is_active" => UnitTypes::IS_ACTIVE, + "is_publish" => UnitTypes::IS_PUBLISH, + ]), + "banks" => Banks::listBanks(["is_active" => Banks::IS_ACTIVE]), + ]; + return view("menu_v1._viewTransactions", $data); + } + public function view_transactions_confirm(Request $req) + { + $order = Orders::showOrder([ + "code" => $req->code, + "center_pck" => 1, + "get_prefer_type_truck" => 1, + ]); + if (count($order) < 1) { + return redirect(route("view_transactions")); + } + if (isset($order[0]->pck_center)) { + $split = explode(" ", $order[0]->pck_center); + $order[0]->pck_center_lat = substr($split[1], 0, -1); + $order[0]->pck_center_lng = substr($split[0], 6); + } + $rate = OrdersRates::getById($order[0]->ord_rate_id); + $data = [ + "order" => $order[0], + "vendors" => OrdersVendors::searchVendorsByRate([ + "active_rates" => $rate[0], + "prefer_truck_type" => $order[0]->prefer_truck_type, + ]), + ]; + return view("menu_v1._confirmTransactions", $data); + } + + /** + * ADMIN CONFIG + */ + + public function view_logs_gps() + { + return view("menu_v1.configs.index_logs_gps"); + } + + /** + * CLIENT TRX + */ + + public function view_transactions_add(Request $req) + { + $data = [ + "uclients" => Users::listUsers([ + "role" => Users::ROLE_CLIENT_ADMIN, + "status" => Users::STATUS_ACTIVE, + ]), + "truck_types" => ConfTruckTypes::listTruckTypesRates( + ConfTruckTypes::IS_ACTIVE, + ConfRates::LANE_EARTH + ), + ]; + return view("menu_v2.Clients._addTransactions", $data); + } + + public function view_user_client_transaction() + { + return view("menu_v2.Clients.transactions"); + } + public function view_user_client_transaction_view(Request $req) + { + $order = Orders::showOrder([ + "code" => $req->code, + "get_stts_checker" => 1, + // 'get_prefer_type_truck' => 1, + "get_additional_vehicles_info" => 1, + "get_accidents" => 1, + ]); + if (count($order) < 1) { + return redirect(route("view_user_client_transaction")); + } + $adtPoints = Orders::getPoints([ + "id" => $order[0]->ord_id, + "limit" => $order[0]->drop_total, + ]); + array_splice($adtPoints, 0, 1); + $data = [ + "order" => $order[0], + "adtPoints" => $adtPoints, + "adtPointsJson" => json_encode($adtPoints), + ]; + return view("menu_v2.Clients._viewTransactions", $data); + } + public function view_user_client_transaction_add(Request $req) + { + $client_group_id = $req->auth->client_group_id; + + // if ($req->rdl == 1) { + // // $inActive = Orders::getOrdersClientActive($req->auth->uid); + // $haveOrder = Orders::getOrdersByClient($req->auth->uid, 1); + // if (count($haveOrder) > 0) { + // return redirect(route('view_user_client_transaction')); + // } + // } + + $data = [ + "pickups" => Zone::getActiveZones($client_group_id, 0, Zone::ZONE_WORKFLOW_PICKUP), + "drops" => Zone::getActiveZones($client_group_id, 0, Zone::ZONE_WORKFLOW_DEST), + "truck_types" => ConfTruckTypes::listTruckTypesRates( + ConfTruckTypes::IS_ACTIVE, + ConfRates::LANE_EARTH + ), + ]; + return view("menu_v2.Clients._addTransactions", $data); + } + // public function view_user_client() { + // return view('menu_v2.Clients._addTransactions'); + // } + + /** + * VENDOR TRX + */ + + public function view_user_vendor_transaction() + { + return view("menu_v2.Vendors.transactions"); + } + public function view_user_vendor_transaction_view(Request $req) + { + $codes = explode(",", $req->code); + $limit = count($codes); + if ($limit > 2) { + return redirect(route("view_transactions")); + } + $orders = Orders::showOrder([ + "codes" => $codes, + "get_stts_checker" => 1, + "get_checker_data" => 1, + "get_checker_user" => 1, + // 'get_prefer_type_truck' => 1, + "get_additional_vehicles_info" => 1, + "get_accidents" => 1, + "group_by" => "ord.id", + "limit" => $limit, + ]); + + if (count($orders) < 1) { + return redirect(route("view_transactions")); + } + $bladeViewOrders = []; + foreach ($orders as $iOrd => $order) { + // get multiple point (pick,drop) + $adtPoints = Orders::getPoints([ + "id" => $order->ord_id, + "limit" => $order->drop_total, + ]); + // hilangkan index 0, karena yang didapatkan adalah childnya + array_splice($adtPoints, 0, 1); + $orders[$iOrd]->adtPoints = $adtPoints; + // dd($adtPoints); + // formated for blade views + $tmpBladeView = clone $order; + if ($order->ord_pck_docs_client_img) { + $tmpBladeView->ord_pck_docs_client_img = json_decode($order->ord_pck_docs_client_img); + } + if ($order->ord_acdnt_imgs) { + $tmpBladeView->ord_acdnt_imgs = json_decode($order->ord_acdnt_imgs); + } + $bladeViewOrders[] = clone $tmpBladeView; + } + + $rawData = DB::table("t_orders_pck_drop as topd") + ->leftJoin("t_orders_pickups as top", "top.id", "topd.pck_id") + ->leftJoin("t_orders_drops as tod", "tod.id", "topd.drop_id") + ->where("topd.ord_code", $codes) + ->selectRaw( + "topd.id, + FROM_UNIXTIME(top.set_pck_at, '%d %M %Y') as pck_date, + FROM_UNIXTIME(top.set_pck_at, '%H:%i:%s') as pck_time, + top.pck_name, + top.pck_addr, + tod.drop_name, + tod.drop_addr" + ) + ->get(); + foreach ($rawData as $_data) { + $ehck = DB::table("t_orders_drivers_uploads") + ->select( + "id", // + "checklist_name", + "checklist_desc", + "img", + "updt" + ) + ->where("ord_pck_drop_id", $_data->id) + ->get(); + $data[] = [ + "id" => $_data->id, + "pck_date" => $_data->pck_date, + "pck_time" => $_data->pck_time, + "pck_name" => $_data->pck_name, + "pck_addr" => $_data->pck_addr, + "drop_name" => $_data->drop_name, + "drop_addr" => $_data->drop_addr, + "checklist_array" => $ehck, + ]; + } + // dd($data[0]["checklist_array"]); + // dd($data); + $data = [ + "data" => $data, + "orders" => $orders, + "bladeViewOrders" => $bladeViewOrders, + ]; + // dd($data); + return view("menu_v2.Vendors._viewTransactions", $data); + } + public function view_user_vendor_transaction_view_bak_single(Request $req) + { + $order = Orders::showOrder([ + "code" => $req->code, + ]); + if (count($order) < 1) { + return redirect(route("view_transactions")); + } + $adtPoints = Orders::getPoints([ + "id" => $order[0]->ord_id, + "limit" => $order[0]->drop_total, + ]); + array_splice($adtPoints, 0, 1); + $data = [ + "order" => $order[0], + "adtPoints" => $adtPoints, + "adtPointsJson" => json_encode($adtPoints), + ]; + return view("menu_v2.Vendors._viewTransactions", $data); + } + public function view_user_vendor_transaction_new_order(Request $req) + { + // dd($req->code); + $order = Orders::showOrder([ + "code" => $req->code, + "get_exp_vendor" => 1, + "vdr_id" => $req->auth->uid, + "get_bid_info" => 1, + ]); + // dd($order); + // if (count($order) < 1) { + // return redirect(route("view_user_vendor_transaction")); + // } + // if ($order[0]->vdr_status !== OrdersVendors::STTS_WAIT) { + // return redirect(route("view_user_vendor_transaction")); + // } + // if ( + // $order[0]->status === Orders::STTS_WAIT || + // $order[0]->status === Orders::STTS_CONFIRM + // ) { + // } else { + // return redirect(route("view_user_vendor_transaction")); + // } + // // date('Y-m-d H:i:s', $order[0]->vdr_exp_at); + // if ($order[0]->vdr_is_exp === OrdersVendors::LINK_WILL_EXP) { + // if ($order[0]->vdr_exp_at < time()) { + // return redirect(route("view_user_vendor_transaction")); + // } + // } + // if ($order[0]->is_mailing_bid != OrdersVendors::IS_MAILING_BID_SEND) { + // return redirect(route("view_user_vendor_transaction")); + // } + $haveBeenAcc = OrdersVendors::getByOrdIdByStatus($order[0]->ord_id, OrdersVendors::STTS_ACC); + if (count($haveBeenAcc) > 0) { + return redirect(route("view_user_vendor_transaction")); + } + $vehicles = Vehicles::getVehiclesInIdsActiveNoInOrder($order[0]->find_vhcs); + // $drivers = Drivers::getDriversNoInOrder($req->auth, [ + // 'status' => Drivers::STTS_ACTIVE + // ]); + $drivers = Drivers::getDriversNoInOrderNew($req->auth, [ + "status" => Drivers::STTS_ACTIVE, + ]); + + $data = [ + "order" => $order[0], + "vehicles" => $vehicles, + "drivers" => $drivers, + ]; + return view("menu_v2.Vendors._newOrder", $data); + } + + /** + * CHECKER TRX + */ + + // public function view_user_checker() + // { + // return view('menu_v2.Checker.index'); + // } + // public function view_user_checker_view(Request $req) + // { + // $order = Orders::showOrder([ + // 'code' => $req->code, + // 'get_stts_checker' => 1, + // ]); + // if (count($order) < 1) { + // return redirect(route('view_user_checker')); + // } + // $filter = [ + // 'get_not_deleted' => 1, + // ]; + // $items = OrdersItems::getsByOrdId($order[0]->ord_id, $filter); + // $data = [ + // 'order' => $order[0], + // 'items' => $items, + // ]; + // return view('menu_v2.Checker._view', $data); + // } + + public function view_user_checker() + { + return view("menu_v2.Checker.index"); + } + public function view_user_checker_view(Request $req) + { + $data = []; + $orders = Orders::showOrder([ + "code" => $req->code, + "get_stts_checker" => 1, + "get_prefer_type_truck" => 1, + "get_checker_data" => 1, + "get_client_pt" => 1, + "get_accidents" => 1, + "couple_pck_drop" => 1, + "get_user_aprv_pck" => 1, + "get_user_aprv_pck" => 1, + "join_pockets" => 1, + "group_by" => "ord.id", + ]); + if (count($orders) < 1) { + return redirect(route("view_user_checker")); + } + $orderOne = clone $orders[0]; + if ($orders[0]->group_merge_code) { + $orders = Orders::showOrder([ + "group_merge_code" => $orders[0]->group_merge_code, + "get_stts_checker" => 1, + "get_prefer_type_truck" => 1, + "get_checker_data" => 1, + "get_client_pt" => 1, + "get_accidents" => 1, + "couple_pck_drop" => 1, + "get_user_aprv_pck" => 1, + "join_pockets" => 1, + "group_by" => "ord.id", + "limit" => 2, + ]); + } + + // uang saku / pocket money + $checkpoints = OrdersCheckpoints::listCheckpoints([ + "ord_id" => $orders[0]->ord_id, + ]); + + $truck_types = ConfTruckTypes::listTruckTypes(ConfTruckTypes::IS_ACTIVE, [ + "is_publish" => ConfTruckTypes::IS_PUBLISH, + ]); + $bladeViewOrders = []; + foreach ($orders as $iOrd => $order) { + // get multiple point (pick,drop) + $adtPoints = Orders::getPoints([ + "id" => $order->ord_id, + "limit" => $order->drop_total, + ]); + // hilangkan index 0, karena yang didapatkan adalah childnya + array_splice($adtPoints, 0, 1); + $orders[$iOrd]->adtPoints = $adtPoints; + + // uang saku / pocket money + $orders[$iOrd]->checkpoints = $checkpoints; + + // formated for blade views + $tmpBladeView = clone $order; + if ($order->ord_pck_docs_client_img) { + $tmpBladeView->ord_pck_docs_client_img = json_decode($order->ord_pck_docs_client_img); + } + if ($order->ord_acdnt_imgs) { + $tmpBladeView->ord_acdnt_imgs = json_decode($order->ord_acdnt_imgs); + } + $bladeViewOrders[] = clone $tmpBladeView; + + // special case for checker, karena meskipun merge tapi tampilnya tetap 1-1 per trx + if ($req->code === $order->ord_code) { + $orderOne = clone $order; + } + } + + $drvs_ups = OrdersDriversUploads::list([ + "ord_id" => $orders[0]->ord_id, + "pck_id" => $orders[0]->ord_pck_id, + "drop_id" => $orders[0]->ord_drop_id, + "ord_pck_drop_id" => $orders[0]->ord_pck_drop_id, + ]); + + $data = [ + "orders" => $orders, + "drvs_ups" => $drvs_ups, + "order" => $orderOne, + "truck_types" => $truck_types, + "adtPoints" => $orders[0]->adtPoints, + "adtPointsJson" => json_encode($orders[0]->adtPoints), + ]; + return view("menu_v2.Checker._view", $data); + } + + /** + * FINANCE + */ + public function view_keuangan_payment() + { + return view("menu_v2.Finance.payment"); + } + public function view_keuangan_payment_view(Request $req) + { + $codes = explode(",", $req->code); + $limit = count($codes); + if ($limit > 2) { + return redirect(route("view_transactions")); + } + $orders = Orders::showOrder([ + "codes" => $codes, + // 'get_prefer_type_truck' => 1, + "get_additional_vehicles_info" => 1, + "get_pic_zone" => 1, + // 'get_stts_checker' => 1, + // 'get_checker_data' => 1, + // 'get_checker_user' => 1, + // 'get_accidents' => 1, + "couple_pck_drop" => 1, + "get_user_aprv_pck" => 1, + "group_by" => "ord.id", + "limit" => $limit, + ]); + if (count($orders) < 1) { + return redirect(route("view_keuangan_payment")); + } + $bladeViewOrders = []; + foreach ($orders as $iOrd => $order) { + // get multiple point (pick,drop) + $adtPoints = Orders::getPoints([ + "id" => $order->ord_id, + "limit" => $order->drop_total, + ]); + // hilangkan index 0, karena yang didapatkan adalah childnya + array_splice($adtPoints, 0, 1); + $orders[$iOrd]->adtPoints = $adtPoints; + + // formated for blade views + $tmpBladeView = clone $order; + // if ($order->ord_pck_docs_client_img) $tmpBladeView->ord_pck_docs_client_img = json_decode($order->ord_pck_docs_client_img); + // if ($order->ord_acdnt_imgs) $tmpBladeView->ord_acdnt_imgs = json_decode($order->ord_acdnt_imgs); + $bladeViewOrders[] = clone $tmpBladeView; + } + + $drvs_ups = OrdersDriversUploads::list([ + "ord_id" => $orders[0]->ord_id, + "pck_id" => $orders[0]->ord_pck_id, + "drop_id" => $orders[0]->ord_drop_id, + "ord_pck_drop_id" => $orders[0]->ord_pck_drop_id, + ]); + + $data = [ + "orders" => $orders, + "bladeViewOrders" => $bladeViewOrders, + "drvs_ups" => $drvs_ups, + "items" => AItems::listAItems([ + "is_active" => AItems::IS_ACTIVE, + "crt_type" => AItems::CRT_TYPE_FINANCE, + ]), + "unitTypes" => UnitTypes::listUnitTypes([ + "is_active" => UnitTypes::IS_ACTIVE, + "is_publish" => UnitTypes::IS_PUBLISH, + ]), + "banks" => Banks::listBanks(["is_active" => Banks::IS_ACTIVE]), + "availOrdToMerge" => Finance::availOrdToMerge([ + "except_ord_id" => $orders[0]->ord_id, + ]), + ]; + return view("menu_v2.Finance._viewPayment", $data); + } + public function view_keuangan_payment_view_single_bak(Request $req) + { + $order = Orders::showOrder([ + "code" => $req->code, + // 'get_prefer_type_truck' => 1, + "get_additional_vehicles_info" => 1, + "get_pic_zone" => 1, + // 'get_stts_checker' => 1, + // 'get_checker_data' => 1, + // 'get_checker_user' => 1, + // 'get_accidents' => 1, + ]); + if (count($order) < 1) { + return redirect(route("view_keuangan_payment")); + } + $adtPoints = Orders::getPoints([ + "id" => $order[0]->ord_id, + "limit" => $order[0]->drop_total, + ]); + array_splice($adtPoints, 0, 1); + + $data = [ + "order" => $order[0], + "adtPoints" => $adtPoints, + "adtPointsJson" => json_encode($adtPoints), + "items" => AItems::listAItems([ + "is_active" => AItems::IS_ACTIVE, + "crt_type" => AItems::CRT_TYPE_FINANCE, + ]), + "unitTypes" => UnitTypes::listUnitTypes([ + "is_active" => UnitTypes::IS_ACTIVE, + "is_publish" => UnitTypes::IS_PUBLISH, + ]), + "banks" => Banks::listBanks(["is_active" => Banks::IS_ACTIVE]), + "availOrdToMerge" => Finance::availOrdToMerge([ + "except_ord_id" => $order[0]->ord_id, + ]), + ]; + return view("menu_v2.Finance._viewPayment", $data); + } + public function view_keuangan_billing() + { + return view("menu_v2.Finance.billing"); + } + public function view_keuangan_billing_view(Request $req) + { + $order = Orders::showOrder([ + "code" => $req->code, + // 'get_prefer_type_truck' => 1, + "get_additional_vehicles_info" => 1, + "get_pic_zone" => 1, + // 'get_stts_checker' => 1, + // 'get_checker_data' => 1, + // 'get_checker_user' => 1, + // 'get_accidents' => 1, + "get_client_pt" => 1, + "couple_pck_drop" => 1, + "get_user_aprv_pck" => 1, + ]); + if (count($order) < 1) { + return redirect(route("view_keuangan_billing")); + } + + $a_items = Finance::listAdtItemsBillings([ + "ord_id" => $order[0]->ord_id, + "group_by" => "ord_a_item.id", + "is_bill_aprv" => OrdersAItems::IS_APRV_YES, + ]); + $group_items_by_termin = []; + foreach ($a_items as $i => $row) { + if (!isset($group_items_by_termin[$row->c_group_termin_id])) { + if ( + $row->a_item_type === OrdersAItems::A_TYPE_PRIMARY && + $row->stts_merge !== OrdersAItems::STTS_MERGE_RESULT + ) { + $row->previous_termin = OrdersAItems::showAItem([ + "ord_id" => $row->ord_id, + "is_active" => OrdersAItems::IS_ACTIVE_YES, + "a_item_type" => OrdersAItems::A_TYPE_PRIMARY, + "prev_main_item_id" => $row->ord_a_item_id, + "c_termin_id_not_zero" => 1, + "limit" => 1, + ]); + } + $group_items_by_termin[$row->c_group_termin_id] = []; + $group_items_by_termin[$row->c_group_termin_id][] = $row; + continue; + } + $group_items_by_termin[$row->c_group_termin_id][] = $row; + } + $adtPoints = Orders::getPoints([ + "id" => $order[0]->ord_id, + "limit" => $order[0]->drop_total, + ]); + array_splice($adtPoints, 0, 1); + + $drvs_ups = OrdersDriversUploads::list([ + "ord_id" => $order[0]->ord_id, + "pck_id" => $order[0]->ord_pck_id, + "drop_id" => $order[0]->ord_drop_id, + "ord_pck_drop_id" => $order[0]->ord_pck_drop_id, + ]); + + $data = [ + "order" => $order[0], + "adtPoints" => $adtPoints, + "adtPointsJson" => json_encode($adtPoints), + "drvs_ups" => $drvs_ups, + "items" => AItems::listAItems([ + "is_active" => AItems::IS_ACTIVE, + "crt_type" => AItems::CRT_TYPE_FINANCE, + ]), + "unitTypes" => UnitTypes::listUnitTypes([ + "is_active" => UnitTypes::IS_ACTIVE, + "is_publish" => UnitTypes::IS_PUBLISH, + ]), + "banks" => Banks::listBanks(["is_active" => Banks::IS_ACTIVE]), + "group_items_by_termin" => $group_items_by_termin, + ]; + return view("menu_v2.Finance._viewBilling", $data); + } +} diff --git a/app/Http/Controllers/OSMController.php b/app/Http/Controllers/OSMController.php new file mode 100755 index 0000000..08e2d60 --- /dev/null +++ b/app/Http/Controllers/OSMController.php @@ -0,0 +1,87 @@ + $req->address, + 'country_code' => $req->country_code, + ]; + $rulesInput = [ + 'address' => 'required|string|min:45', + 'country_code' => 'required|string|min:2', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $payload = [ + 'countrycodes' => $req->country_code, + 'format' => 'geojson', + 'q' => $req->address, + ]; + $payload = http_build_query($payload); + // $url = env('API_URL_NOMINATIM') . '/search?format=geojson&countrycodes=' . $req->country_code . '&q=' . $req->address; + $url = env('API_URL_NOMINATIM') . '/search?' . $payload; + + // $respNominatim = Helper::req_get($url, [ + // 'User-Agent: PostmanRuntime/7.28.4', + // 'Accept: */*', + // 'Accept-Encoding: gzip, deflate, br', + // 'Connection: keep-alive' + // ]); + + $guzReq = new GuzzleClient(); + $respNominatim = $guzReq->request('GET', $url, [ + 'headers' => [ + 'Host' => $_SERVER['SERVER_ADDR'] ?? '127.0.0.1', + 'User-Agent' => 'curl/7.65.3', + 'Accept' => '*/*', + 'Accept-Encoding' => 'gzip, deflate, br', + // 'Connection' => 'keep-alive', + ] + ]); + + if ($respNominatim->getStatusCode() != 200) { + $apiResp = Responses::bad_request('fail geo address'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + $body = json_decode($respNominatim->getBody()->getContents()); + $data = null; + if (count($body->features) > 0) { + $data = [ + 'lat' => $body->features[0]->geometry->coordinates[1], + 'lng' => $body->features[0]->geometry->coordinates[0], + ]; + } + + $apiResp = Responses::success('success geo address'); + $apiResp['data'] = $data; + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } +} diff --git a/app/Http/Controllers/PocketController.php b/app/Http/Controllers/PocketController.php new file mode 100755 index 0000000..1182ff9 --- /dev/null +++ b/app/Http/Controllers/PocketController.php @@ -0,0 +1,498 @@ + PocketMoney::getTypes(), + 'flows' => PocketMoney::getFlows(), + // 'clients' => Clients::listClients(['c_status' => Clients::CSTTS_ACTIVE]), + // 'pickups' => Zone::listZones($req->auth, ['is_active' => Zone::STATUS_ACTIVE, 'type' => Zone::ZONE_TYPE_WAREHOUSE, 'workflow_type' => Zone::ZONE_WORKFLOW_PICKUP]), + // 'drops' => Zone::listZones($req->auth, ['is_active' => Zone::STATUS_ACTIVE, 'type' => Zone::ZONE_TYPE_WAREHOUSE, 'workflow_type' => Zone::ZONE_WORKFLOW_DEST]), + ]; + + return view('menu_v1.configs.pocket_money', $data); + } + + + /** + * API + */ + + public function api_list_pockets(Request $req) + { + try { + $now = time(); + $input = [ + 'cptid' => $req->cptid, + ]; + $rulesInput = [ + 'cptid' => 'nullable|numeric' + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + $filter = []; + if ($input['cptid'] != null && $input['cptid'] != 0) { + $filter['cptid'] = $input['cptid']; + } + + $list = PocketMoney::listPockets($filter); + foreach ($list as $key => $row) { + $list[$key]->DT_RowIndex = $key + 1; + $list[$key]->action = '-'; + } + + $apiResp = Responses::success('success list pockets'); + $apiResp['count'] = count($list); + $apiResp['data'] = $list; + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_show_pocket(Request $req, $pocket_id) + { + try { + $now = time(); + + $input = [ + 'pocket_id' => $pocket_id, + ]; + $rulesInput = [ + 'pocket_id' => 'required|integer|not_in:0', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $pocket = PocketMoney::showPocketById($pocket_id); + if (count($pocket) < 1) { + $apiResp = Responses::not_found('pocket not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + $pocket[0]->checkpoints = Checkpoints::listCheckpoints(['pocket_id' => $pocket[0]->id]); + + $apiResp = Responses::success('success get detail pocket'); + $apiResp['data'] = $pocket[0]; + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_add_pocket(Request $req) + { + try { + $now = time(); + + $input = [ + 'name' => $req->add_name, + 'type' => $req->add_type, + 'pck' => $req->add_pck, + 'drop' => $req->add_drop, + 'price' => $req->add_price, + 'start_checkpoint' => $req->add_start_checkpoints, + // 'end_checkpoint' => $req->add_end_checkpoints, + 'price_checkpoint' => $req->add_price_checkpoints, + 'status' => $req->status, + ]; + $rulesInput = [ + 'name' => 'required|string|max:255', + 'type' => 'required|numeric|min:0', + 'pck' => 'required|numeric|min:0', + 'drop' => 'required|numeric|min:0', + 'price' => 'required|numeric|min:0', + 'start_checkpoint' => 'nullable|array', + 'start_checkpoint.*' => 'nullable|numeric|min:0', + // 'end_checkpoint' => 'nullable|array', + // 'end_checkpoint.*' => 'nullable|numeric|min:0', + 'price_checkpoint' => 'nullable|array', + 'price_checkpoint.*' => 'nullable|numeric|min:0', + 'status' => 'required|numeric|min:0', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $nanoid = new Nanoid(); + $code = $nanoid->formattedId('0123456789', 9); + // $code = $now; + $doWhile = true; + do { + if (substr($code, 0, 1) == 0) { + $code = $nanoid->formattedId('0123456789', 9); + } else { + $doWhile = false; + } + } while ($doWhile); + $uniqCode = PocketMoney::getPocketByCode($code); + if (count($uniqCode) > 0) { + $apiResp = Responses::bad_request('code has been used, try again'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + // $uniqPckDrop = PocketMoney::getPocketByPckDrop($input['pck'], $input['drop']); + // if (count($uniqPckDrop) > 0) { + // $apiResp = Responses::bad_request('Pickup dan Drop sudah pernah ditambahkan'); + // return (new Response($apiResp, $apiResp['meta']['code'])); + // } + + if ($input['start_checkpoint']) { + if ($input['start_checkpoint'][0] != $input['pck']) { + $apiResp = Responses::bad_request('Titik lokasi pertama checkpoint haruslah sama dengan pickup'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + $pck = Zone::showZoneById($input['pck']); + if (count($pck) < 1) { + $apiResp = Responses::not_found('lokasi pickup tidak ditemukan'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + $drop = Zone::showZoneById($input['drop']); + if (count($drop) < 1) { + $apiResp = Responses::not_found('lokasi drop tidak ditemukan'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + if ($pck[0]->client_group_id !== $drop[0]->client_group_id) { + $apiResp = Responses::bad_request('Lokasi pickup dan drop sudah beda perusahaan'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + DB::beginTransaction(); + + $insPocket = [ + 'code' => $code, + 'name' => $input['name'], + 'type' => $input['type'], + 'flow' => PocketMoney::FLOW_HYBRID, + 'pck_id' => $input['pck'], + 'drop_id' => $input['drop'], + 'is_active' => $input['status'], + 'total' => 0, + 'crt' => $now, + 'crt_by' => $req->auth->uid, + 'updt' => $now, + 'updt_by' => $req->auth->uid, + ]; + $pocket_id = PocketMoney::addPocket($insPocket); + + $total = 0; + if ($input['start_checkpoint']) { + foreach ($input['start_checkpoint'] as $i => $row) { + $insCheckpoint = [ + 'pocket_id' => $pocket_id, + 'pck_id' => $input['start_checkpoint'][$i], + // 'drop_id' => $input['end_checkpoint'][$i], + 'total' => $input['price_checkpoint'][$i], + 'sort' => $i + 1, + 'crt' => $now, + 'crt_by' => $req->auth->uid, + 'updt' => $now, + 'updt_by' => $req->auth->uid, + ]; + $total += $input['price_checkpoint'][$i]; + Checkpoints::addCheckpoint($insCheckpoint); + } + } else { + $insCheckpoint = [ + 'pocket_id' => $pocket_id, + 'pck_id' => $input['pck'], + 'drop_id' => $input['drop'], + 'total' => $input['price'], + 'sort' => 1, + 'crt' => $now, + 'crt_by' => $req->auth->uid, + 'updt' => $now, + 'updt_by' => $req->auth->uid, + ]; + $total += $input['price']; + Checkpoints::addCheckpoint($insCheckpoint); + } + + PocketMoney::updatePocket($pocket_id, ['total' => $total]); + + $apiResp = Responses::created('success add new pocket'); + + DB::commit(); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_edit_pocket(Request $req, $pocket_id) + { + try { + $now = time(); + + $input = [ + 'pocket_id' => $pocket_id, + 'name' => $req->updt_name, + 'type' => $req->updt_type, + 'pck' => $req->updt_pck, + 'drop' => $req->updt_drop, + 'price' => $req->updt_price, + 'start_checkpoint' => $req->updt_start_checkpoints, + // 'end_checkpoint' => $req->updt_end_checkpoints, + 'price_checkpoint' => $req->updt_price_checkpoints, + 'status' => $req->status, + ]; + $rulesInput = [ + 'pocket_id' => 'required|integer|not_in:0', + 'name' => 'required|string|max:255', + 'type' => 'required|numeric|min:0', + 'pck' => 'required|numeric|min:0', + 'drop' => 'required|numeric|min:0', + 'price' => 'required|numeric|min:0', + 'start_checkpoint' => 'nullable|array', + 'start_checkpoint.*' => 'nullable|numeric|min:0', + // 'end_checkpoint' => 'nullable|array', + // 'end_checkpoint.*' => 'nullable|numeric|min:0', + 'price_checkpoint' => 'nullable|array', + 'price_checkpoint.*' => 'nullable|numeric|min:0', + 'status' => 'required|numeric|min:0', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $pocket = PocketMoney::showPocketById($pocket_id); + if (count($pocket) < 1) { + $apiResp = Responses::not_found('pocket not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + $pocket[0]->checkpoints = Checkpoints::listCheckpoints(['pocket_id' => $pocket[0]->id]); + + if ($input['start_checkpoint']) { + if ($input['start_checkpoint'][0] != $input['pck']) { + $apiResp = Responses::bad_request('Titik lokasi pertama checkpoint haruslah sama dengan pickup'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + $pck = Zone::showZoneById($input['pck']); + if (count($pck) < 1) { + $apiResp = Responses::not_found('lokasi pickup tidak ditemukan'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + $drop = Zone::showZoneById($input['drop']); + if (count($drop) < 1) { + $apiResp = Responses::not_found('lokasi drop tidak ditemukan'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + if ($pck[0]->client_group_id !== $drop[0]->client_group_id) { + $apiResp = Responses::bad_request('Lokasi pickup dan drop sudah beda perusahaan'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + DB::beginTransaction(); + + $updtPocket = [ + // 'code' => $code, + 'type' => $input['type'], + 'name' => $input['name'], + // 'flow' => PocketMoney::FLOW_HYBRID, + 'pck_id' => $input['pck'], + 'drop_id' => $input['drop'], + 'is_active' => $input['status'], + 'total' => 0, + 'updt' => $now, + 'updt_by' => $req->auth->uid, + ]; + PocketMoney::updatePocket($input['pocket_id'], $updtPocket); + + $total = 0; + if ($input['start_checkpoint']) { + Checkpoints::deleteCheckpointByPocketId($input['pocket_id']); + foreach ($input['start_checkpoint'] as $i => $row) { + $insCheckpoint = [ + 'pocket_id' => $input['pocket_id'], + 'pck_id' => $input['start_checkpoint'][$i], + // 'drop_id' => $input['end_checkpoint'][$i], + 'total' => $input['price_checkpoint'][$i], + 'sort' => $i + 1, + 'crt' => $now, + 'crt_by' => $req->auth->uid, + 'updt' => $now, + 'updt_by' => $req->auth->uid, + ]; + $total += $input['price_checkpoint'][$i]; + Checkpoints::addCheckpoint($insCheckpoint); + } + } else { + Checkpoints::deleteCheckpointByPocketId($input['pocket_id']); + $updtCheckpoint = [ + 'pocket_id' => $input['pocket_id'], + 'pck_id' => $input['pck'], + 'drop_id' => $input['drop'], + 'total' => $input['price'], + 'sort' => 1, + 'crt' => $now, + 'crt_by' => $req->auth->uid, + 'updt' => $now, + 'updt_by' => $req->auth->uid, + ]; + $total += $input['price']; + // Checkpoints::updateCheckpoint($pocket[0]->checkpoints[0]->id, $updtCheckpoint); + Checkpoints::addCheckpoint($updtCheckpoint); + } + + PocketMoney::updatePocket($input['pocket_id'], ['total' => $total]); + + $apiResp = Responses::created('success update pocket'); + + DB::commit(); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_del_pocket(Request $req, $pocket_id) + { + try { + $now = time(); + + $input = [ + 'pocket_id' => $pocket_id, + ]; + $rulesInput = [ + 'pocket_id' => 'required|integer|not_in:0', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $pocket = PocketMoney::showPocketById($pocket_id); + if (count($pocket) < 1) { + $apiResp = Responses::not_found('pocket not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + $pocket[0]->checkpoints = Checkpoints::listCheckpoints(['pocket_id' => $pocket[0]->id]); + + DB::beginTransaction(); + + PocketMoney::updatePocket($pocket_id, [ + 'dlt' => $now, + 'dlt_by' => $req->auth->uid, + ]); + + foreach ($pocket[0]->checkpoints as $row) { + Checkpoints::updateCheckpoint($row->id, [ + 'dlt' => $now, + 'dlt_by' => $req->auth->uid, + ]); + } + + DB::commit(); + + $apiResp = Responses::success('success delete pocket'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_pck_drop_pocket(Request $req) + { + try { + $now = time(); + + $input = [ + 'client_id' => $req->client_id, + 'pck_id' => $req->pck_id, + 'drop_id' => $req->drop_id, + ]; + $rulesInput = [ + 'client_id' => 'required|integer|not_in:0', + 'pck_id' => 'required|integer|not_in:0', + 'drop_id' => 'required|integer|not_in:0', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $pockets = PocketMoney::listPockets([ + 'cptid' => $input['client_id'], + 'pck_id' => $input['pck_id'], + 'drop_id' => $input['drop_id'], + 'is_active' => PocketMoney::IS_ACTIVE, + ]); + if (count($pockets) < 1) { + $apiResp = Responses::not_found('pocket not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + foreach ($pockets as $i => $pkt) { + $pockets[$i]->checkpoints = Checkpoints::listCheckpoints(['pocket_id' => $pkt->id]); + } + + $apiResp = Responses::success('success get pockets'); + $apiResp['data'] = $pockets; + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } +} diff --git a/app/Http/Controllers/RegionController.php b/app/Http/Controllers/RegionController.php new file mode 100755 index 0000000..51f14a3 --- /dev/null +++ b/app/Http/Controllers/RegionController.php @@ -0,0 +1,100 @@ + $req->kodeProv, + ]; + $rulesInput = [ + 'kodeProv' => 'required|numeric', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $apiResp = Responses::success('success get list district'); + $apiResp['data'] = Region::listCity($req->kodeProv); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_list_district(Request $req) + { + try { + $now = time(); + + $input = [ + 'kodeKab' => $req->kodeKab, + ]; + $rulesInput = [ + 'kodeKab' => 'required|numeric', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $apiResp = Responses::success('success get list village'); + $apiResp['data'] = Region::listDistrict($req->kodeKab); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_list_village(Request $req) + { + try { + $now = time(); + + $input = [ + 'kodeKec' => $req->kodeKec, + ]; + $rulesInput = [ + 'kodeKec' => 'required|numeric', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $apiResp = Responses::success('success get list village'); + $apiResp['data'] = Region::listVillage($req->kodeKec); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } +} diff --git a/app/Http/Controllers/StaticInsuranceController.php b/app/Http/Controllers/StaticInsuranceController.php new file mode 100755 index 0000000..2d6b547 --- /dev/null +++ b/app/Http/Controllers/StaticInsuranceController.php @@ -0,0 +1,146 @@ +passes()) { + // $apiResp = Responses::bad_input($isValidInput->messages()->first()); + // return new Response($apiResp, $apiResp['meta']['code']); + // } + + $list = StaticInsurances::listStaticInsurances(); + foreach ($list as $key => $row) { + $list[$key]->DT_RowIndex = $key + 1; + $list[$key]->action = '-'; + } + + $apiResp = Responses::success('success list insurances'); + $apiResp['count'] = count($list); + $apiResp['data'] = $list; + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_show_static_insurance(Request $req, $id) + { + try { + $now = time(); + + $input = [ + 'id' => $id, + ]; + $rulesInput = [ + 'id' => 'required|integer|not_in:0', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $insurance = StaticInsurances::getInsuranceById($id); + if (count($insurance) < 1) { + $apiResp = Responses::not_found('insurance not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + $apiResp = Responses::success('success get detail insurance'); + $apiResp['data'] = $insurance[0]; + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_edit_static_insurance(Request $req, $id) + { + try { + $now = time(); + + $input = [ + 'id' => $id, + 'desc' => $req->desc, + 'amt_percent' => $req->amt_percent, + // 'status' => $req->status, + ]; + $rulesInput = [ + 'id' => 'required|integer|not_in:0', + 'desc' => 'required|string', + 'amt_percent' => 'required|numeric|min:0', + // 'status' => 'required|numeric|min:0', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $insurance = StaticInsurances::getInsuranceById($id); + if (count($insurance) < 1) { + $apiResp = Responses::not_found('insurance not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + DB::beginTransaction(); + + $updtInsurance = [ + 'desc' => $req->desc, + 'amt_percent' => $req->amt_percent, + // 'is_active' => $req->status, + 'updt' => $now, + 'updt_by' => $req->auth->uid, + ]; + if ($req->dest_district) { + $updtInsurance['dest_district'] = $req->dest_district; + } + $id = StaticInsurances::updateInsurance($id, $updtInsurance); + + $apiResp = Responses::created('success update insurance'); + + DB::commit(); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } +} diff --git a/app/Http/Controllers/StorageController.php b/app/Http/Controllers/StorageController.php new file mode 100755 index 0000000..bf1398a --- /dev/null +++ b/app/Http/Controllers/StorageController.php @@ -0,0 +1,79 @@ + $req->names, + 'photos' => $req->photos, + ]; + $rulesInput = [ + 'names' => 'required|array', + 'names.*' => 'required|string|max:255', + 'photos' => 'required|array', + 'photos.*' => 'required|string', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + if ($req->names && count($req->names) < 1) { + $apiResp = Responses::bad_input('names is required'); + return new Response($apiResp, $apiResp['meta']['code']); + } + if ($req->photos && count($req->photos) < 1) { + $apiResp = Responses::bad_input('photos is required'); + return new Response($apiResp, $apiResp['meta']['code']); + } + + foreach ($req->photos as $i => $img) { + $clearBase64 = preg_replace('/^data:(image|application)\/(png|jpg|jpeg|pdf);base64,/', '', $img); + // $type = 'jpeg'; + // if (strpos($img, 'application/pdf') !== false) $type = 'pdf'; + // $url_photos_base64[$i] = "orders/" . $order[0]->ord_id . "/a_items/" . $oa_id . "/submission/" . $req->auth->uid . "/submission_proof_img_$now" . "_" . "$i.$type"; + $url_photos_base64[$i] = $req->names[$i]; + if (!Storage::disk('public')->put($url_photos_base64[$i], base64_decode($clearBase64))) { + $apiResp = Responses::bad_request('fail save photo'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + $apiResp = Responses::success('success save photos'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + if (count($url_photos_base64) > 0) { + foreach ($url_photos_base64 as $path) { + Storage::disk('public')->delete($path); + } + } + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + +} \ No newline at end of file diff --git a/app/Http/Controllers/TrackController.php b/app/Http/Controllers/TrackController.php new file mode 100755 index 0000000..426c822 --- /dev/null +++ b/app/Http/Controllers/TrackController.php @@ -0,0 +1,249 @@ +passes()) { + // $apiResp = Responses::bad_input($isValidInput->messages()->first()); + // return new Response($apiResp, $apiResp['meta']['code']); + // } + $filter = [ + "get_order_data" => 1, + ]; + if ($req->cptid) { + $filter["company"] = $req->cptid; + } + + if ($req->auth->is_tracking === Users::IS_TRACK_VHC_YES) { + if ($req->auth->vhcs) { + $filter["vids"] = explode(",", $req->auth->vhcs); + } else { + $filter["vid"] = 0; + } + } elseif ($req->auth->is_tracking === Users::IS_TRACK_VHC_DEFAULT) { + if ($req->auth->role === Users::ROLE_ADMIN) { + if ($req->ord_id) { + $ord = Orders::showOrder(["id" => $req->ord_id]); + if (count($ord) > 0) { + $filter["vid"] = $ord[0]->vhc_id; + } else { + $filter["vid"] = 0; + } + } elseif ($req->ord_code) { + $ord = Orders::showOrder(["code" => $req->ord_code]); + if (count($ord) > 0) { + $filter["vid"] = $ord[0]->vhc_id; + } else { + $filter["vid"] = 0; + } + } + } elseif ($req->auth->role === Users::ROLE_VENDOR) { + $filter["own_by_vdr_id"] = $req->auth->uid; + } elseif ($req->auth->role === Users::ROLE_CLIENT_ADMIN) { + $ords = Orders::listOrders([ + "client_id_active_orders" => $req->auth->uid, + "is_accident" => Orders::IS_ACCIDENT_NO, + ]); + $filter["vids"] = []; + $filter["client_id"] = $req->auth->uid; + foreach ($ords as $k => $v) { + $filter["vids"][] = $v->vhc_id; + } + } elseif ($req->auth->role === Users::ROLE_SPECIAL_TRACKING) { + // $filter['vid'] = 0; + $filter["company"] = $req->auth->client_group_id; + } else { + $filter["vid"] = 0; + } + } else { + $filter["vid"] = 0; + } + + $list = Tracks::listCurrentTracks($filter); + foreach ($list as $key => $row) { + $list[$key]->DT_RowIndex = $key + 1; + // $list[$key]->mileage_km = '-'; + $list[$key]->track_schedule = $row->track_sch_h . "/" . $row->track_sch_d; // combine track_sch_h + track_sch_d + $list[$key]->is_track_holiday_text = + $list[$key]->is_track_holiday == Vehicles::ENABLED_TRACK_HOLIDAY ? "Enabled" : "Disabled"; + $list[$key]->alert_zones = "-"; + $list[$key]->cameras = "-"; + + $insideZones = []; + $insideZoneCircle = Zone::insideZoneCircle($row->lst_lat, $row->lst_lng); + if (count($insideZoneCircle) > 0) { + array_push($insideZones, ...$insideZoneCircle); + } + $insideZoneShape = Zone::insideZoneShape($row->lst_lat, $row->lst_lng); + if (count($insideZoneShape) > 0) { + array_push($insideZones, ...$insideZoneShape); + } + if (count($insideZones) > 0) { + $list[$key]->inside_zones = $insideZones; + } else { + $list[$key]->inside_zones = null; + } + } + $apiResp = Responses::success("success list vehicles"); + $apiResp["data"] = $list; + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_last_move_track_vhc(Request $req) + { + try { + $now = time(); + + $input = [ + "vid" => $req->vid, + "end_at" => $req->end_at, + ]; + $rulesInput = [ + "vid" => "required|integer", + "end_at" => "nullable|date", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $filter = [ + "limit" => 500, + ]; + // default 500, jika ada filter date maka max 5K + if ( + $req->start_date != null && + $req->start_date != "" && + ($req->end_date != null && $req->end_date != "") + ) { + $filter["start_date"] = $req->start_date; + $filter["end_date"] = $req->end_date; + $filter["limit"] = 5000; + } + + $list = Tracks::lastMoveTracks($req->vid, $filter); + + $apiResp = Responses::success("success get last movements"); + $apiResp["data"] = $list; + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_conf_list_logs_gps(Request $req) + { + try { + $now = time(); + $input = []; + $rulesInput = []; + + // validasi input + // $isValidInput = Validator::make($input, $rulesInput); + // if (!$isValidInput->passes()) { + // $apiResp = Responses::bad_input($isValidInput->messages()->first()); + // return new Response($apiResp, $apiResp['meta']['code']); + // } + + $filter = [ + "limit" => 1000, + "crt_greater_than" => 1646122574, + ]; + + $list = Tracks::listLogsGps($filter); + foreach ($list as $key => $row) { + $list[$key]->DT_RowIndex = $key + 1; + $list[$key]->action = "-"; + } + + $apiResp = Responses::success("success list gps tracker"); + $apiResp["count"] = count($list); + $apiResp["data"] = $list; + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_track_order(Request $req) + { + try { + $now = time(); + $input = []; + $rulesInput = []; + + // validasi input + // $isValidInput = Validator::make($input, $rulesInput); + // if (!$isValidInput->passes()) { + // $apiResp = Responses::bad_input($isValidInput->messages()->first()); + // return new Response($apiResp, $apiResp['meta']['code']); + // } + + $ord = []; + $filter = [ + "get_pic_zone" => 1, + "get_zone_data" => 1, + ]; + if ($req->ord_id) { + $filter["id"] = $req->ord_id; + } elseif ($req->ord_code) { + $filter["code"] = $req->ord_code; + } + $ord = Orders::showOrder($filter); + + if (count($ord) < 1) { + $apiResp = Responses::not_found("order not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $vid = $ord[0]->vhc_id; + + $history = Tracks::lastMoveTracks($vid, [ + "start_at" => $ord[0]->confirm_at, + ]); + + $apiResp = Responses::success("success track order"); + $apiResp["data"] = [ + "order" => $ord[0], + "history" => $history, + ]; + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } +} diff --git a/app/Http/Controllers/TransactionController.php b/app/Http/Controllers/TransactionController.php new file mode 100755 index 0000000..4c0989e --- /dev/null +++ b/app/Http/Controllers/TransactionController.php @@ -0,0 +1,5590 @@ +toString(); + // return (new Nanoid())->generateId(36); + + // test uniq the random code + // https://blog.bitsrc.io/why-is-nanoid-replacing-uuid-1b5100e62ed2 + // $tokens = []; + // for ($i=0; $i<1000; $i++) { + // // $token = Str::uuid()->toString(); + // $token = (new Nanoid())->generateId(36); + // foreach ($tokens as $tkn) { + // if ($tkn === $token) { + // dd('same'); + // } + // } + // $tokens[] = $token; + // } + // dd('stop'); + $now = time(); + $input = [ + "token" => $req->token, + ]; + $rulesInput = [ + "token" => "required|string|max:100", + ]; + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + return redirect(route("login")); + } + + $ord_vdr = OrdersVendors::getByBidToken($req->token); + if (count($ord_vdr) < 1) { + return redirect(route("login")); + } + + Auth::loginUsingId($ord_vdr[0]->vdr_id); + return redirect(route("view_user_vendor_transaction_new_order") . "?code=" . $ord_vdr[0]->ord_code); + } + + public function view_transactions_download_do(Request $req) + { + // try { + $now = time(); + $input = [ + "ord_code" => $req->ord_code, + ]; + $rulesInput = [ + "ord_code" => "required|numeric", + ]; + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + return abort(403, $isValidInput->messages()->first()); + } + + $filter = [ + "code" => $req->ord_code, + "get_pic_zone" => 1, + "get_client_pt" => 1, + "get_stts_checker" => 1, + ]; + $order = Orders::showOrder($filter); + if (count($order) < 1) { + return abort(404, "order not found"); + } + + $filter = []; + $filter["get_not_deleted"] = 1; + + $items = OrdersItems::getsByOrdId($order[0]->ord_id, $filter); + if (count($items) < 1) { + $apiResp = Responses::not_found("order not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $pdf = PDF::loadView("menu_v1._printDeliveryOrder", [ + "order" => $order[0], + "items" => $items, + ]); + return $pdf->setPaper("a4", "potrait")->stream("delivery_order.pdf"); + // } catch (\Exception $e) { + // $apiResp = Responses::error($e->getMessage()); + // return abort(500, $apiResp['meta']['message']); + // } + } + + public function view_transactions_download_invoice(Request $req) + { + // try { + $now = time(); + $input = [ + "ord_code" => $req->ord_code, + ]; + $rulesInput = [ + "ord_code" => "required|numeric", + ]; + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + return abort(403, $isValidInput->messages()->first()); + } + + $filter = [ + "code" => $req->ord_code, + "get_pic_zone" => 1, + "get_client_pt" => 1, + "get_stts_checker" => 1, + ]; + $order = Orders::showOrder($filter); + if (count($order) < 1) { + return abort(404, "order not found"); + } + + $filter = []; + $filter["get_not_deleted"] = 1; + + $items = OrdersItems::getsByOrdId($order[0]->ord_id, $filter); + if (count($items) < 1) { + $apiResp = Responses::not_found("order not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $pdf = PDF::loadView("menu_v1._printInvoiceClient", [ + "order" => $order[0], + "items" => $items, + ]); + return $pdf->setPaper("a4", "potrait")->stream("invoice_client.pdf"); + // } catch (\Exception $e) { + // $apiResp = Responses::error($e->getMessage()); + // return abort(500, $apiResp['meta']['message']); + // } + } + + public function view_transactions_download_payout(Request $req) + { + // try { + $now = time(); + $input = [ + "ord_code" => $req->ord_code, + ]; + $rulesInput = [ + "ord_code" => "required|numeric", + ]; + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + return abort(403, $isValidInput->messages()->first()); + } + + $filter = [ + "code" => $req->ord_code, + "get_pic_zone" => 1, + "get_client_pt" => 1, + "get_stts_checker" => 1, + ]; + $order = Orders::showOrder($filter); + if (count($order) < 1) { + return abort(404, "order not found"); + } + + $filter = []; + $filter["get_not_deleted"] = 1; + + $items = OrdersItems::getsByOrdId($order[0]->ord_id, $filter); + if (count($items) < 1) { + $apiResp = Responses::not_found("order not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $pdf = PDF::loadView("menu_v1._printPayoutVendor", [ + "order" => $order[0], + "items" => $items, + ]); + return $pdf->setPaper("a4", "potrait")->stream("payout_vendor.pdf"); + // } catch (\Exception $e) { + // $apiResp = Responses::error($e->getMessage()); + // return abort(500, $apiResp['meta']['message']); + // } + } + + protected function one_page_one_doc( + $imgPathFile = "", + $pdfPath = "", + $pdfTitle = "", + $imgName = "", + $outputPdfFile = "", + ) { + if (empty($imgPathFile)) { + return false; + } + if (strpos($imgPathFile, ".pdf") !== false) { + return $imgPathFile; + } else { + $imgAry = []; + if (strpos($imgPathFile, "only_title") !== false) { + $imgAry[] = [ + "name" => $imgName, + ]; + } else { + $imgAry[] = [ + "name" => $imgName, + "path" => $imgPathFile, + ]; + } + $pdf = PDF::loadView("menu_v1.reports._onePageOneImg", [ + "title" => $pdfTitle, + "imgs" => $imgAry, + ]); + Storage::disk("local")->put("public/" . $pdfPath . $outputPdfFile . ".pdf", $pdf->output()); + return $pdfPath . $outputPdfFile . ".pdf"; + } + } + + // with merge pdf + public function view_transactions_download_report_pickup(Request $req) + { + try { + $now = time(); + $input = [ + "ord_code" => $req->ord_code, + ]; + $rulesInput = [ + "ord_code" => "required|numeric", + ]; + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + return abort(403, $isValidInput->messages()->first()); + } + + $filter = [ + "code" => $req->ord_code, + "get_stts_checker" => 1, + "get_checker_data" => 1, + ]; + $order = Orders::showOrder($filter); + if (count($order) < 1) { + return abort(404, "order not found"); + } + + $pdfPath = ""; + foreach (array_slice(explode("/", $order[0]->ord_pck_seal_img), 0, -1) as $k => $r) { + $pdfPath .= "$r/"; + } + + $pdfMerge = new PDFMerger(); + $availToMergers = []; + + if (strpos($order[0]->ord_pck_seal_img, ".pdf") !== false) { + $onePagePdf = $this->one_page_one_doc( + "only_title", + $pdfPath, + "Data Penjemputan", + "Foto Seal", + "ord_pck_seal_img", + ); + if ($onePagePdf) { + $availToMergers[] = $onePagePdf; + } + } + $onePagePdf = $this->one_page_one_doc( + $order[0]->ord_pck_seal_img, + $pdfPath, + "Data Penjemputan", + "Foto Seal", + "ord_pck_seal_img", + ); + if ($onePagePdf) { + $availToMergers[] = $onePagePdf; + } + + if (strpos($order[0]->ord_pck_drv_armd_img, ".pdf") !== false) { + $onePagePdf = $this->one_page_one_doc( + "only_title", + $pdfPath, + "Data Penjemputan", + "Foto Pengemudi + Armada", + "ord_pck_drv_armd_img", + ); + if ($onePagePdf) { + $availToMergers[] = $onePagePdf; + } + } + $onePagePdf = $this->one_page_one_doc( + $order[0]->ord_pck_drv_armd_img, + $pdfPath, + "Data Penjemputan", + "Foto Pengemudi + Armada", + "ord_pck_drv_armd_img", + ); + if ($onePagePdf) { + $availToMergers[] = $onePagePdf; + } + + if (strpos($order[0]->ord_pck_nopol_img, ".pdf") !== false) { + $onePagePdf = $this->one_page_one_doc( + "only_title", + $pdfPath, + "Data Penjemputan", + "Nomor Polisi Kendaraan", + "ord_pck_nopol_img", + ); + if ($onePagePdf) { + $availToMergers[] = $onePagePdf; + } + } + $onePagePdf = $this->one_page_one_doc( + $order[0]->ord_pck_nopol_img, + $pdfPath, + "Data Penjemputan", + "Nomor Polisi Kendaraan", + "ord_pck_nopol_img", + ); + if ($onePagePdf) { + $availToMergers[] = $onePagePdf; + } + + $ord_pck_docs_client_img = json_decode($order[0]->ord_pck_docs_client_img); + $order[0]->ord_pck_docs_client_imgs = []; + foreach ($ord_pck_docs_client_img as $i => $client_img) { + if (strpos($client_img, ".pdf") !== false) { + $onePagePdf = $this->one_page_one_doc( + "only_title", + $pdfPath, + "Data Penjemputan", + "Dokumen Kelengkapan dari Client", + "ord_pck_doc_client_img_" . $i, + ); + if ($onePagePdf) { + $availToMergers[] = $onePagePdf; + } + } + $onePagePdf = $this->one_page_one_doc( + $client_img, + $pdfPath, + "Data Penjemputan", + "Dokumen Kelengkapan dari Client", + "ord_pck_doc_client_img_" . $i, + ); + if ($onePagePdf) { + $availToMergers[] = $onePagePdf; + } + } + + if (strpos($order[0]->ord_pck_seal_install_img, ".pdf") !== false) { + $onePagePdf = $this->one_page_one_doc( + "only_title", + $pdfPath, + "Data Penjemputan", + "Foto Pemasangan Seal", + "ord_pck_seal_install_img", + ); + if ($onePagePdf) { + $availToMergers[] = $onePagePdf; + } + } + $onePagePdf = $this->one_page_one_doc( + $order[0]->ord_pck_seal_install_img, + $pdfPath, + "Data Penjemputan", + "Foto Pemasangan Seal", + "ord_pck_seal_install_img", + ); + if ($onePagePdf) { + $availToMergers[] = $onePagePdf; + } + + if (strpos($order[0]->ord_pck_goods_img, ".pdf") !== false) { + $onePagePdf = $this->one_page_one_doc( + "only_title", + $pdfPath, + "Data Penjemputan", + "Foto Barang", + "ord_pck_goods_img", + ); + if ($onePagePdf) { + $availToMergers[] = $onePagePdf; + } + } + $onePagePdf = $this->one_page_one_doc( + $order[0]->ord_pck_goods_img, + $pdfPath, + "Data Penjemputan", + "Foto Barang", + "ord_pck_goods_img", + ); + if ($onePagePdf) { + $availToMergers[] = $onePagePdf; + } + + foreach ($availToMergers as $key => $row) { + // Storage::disk('local')->get('public/'.$row); + $pdfMerge->addPdf(storage_path("app/public/" . $row), "all", "vertical"); + } + + if (count($availToMergers) > 0) { + $pdfMerge->merge( + "file", + storage_path("app/public/" . $pdfPath . "download_report_pickup.pdf"), + ); + } + + return response()->file(storage_path("app/public/" . $pdfPath . "download_report_pickup.pdf")); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return abort(500, $apiResp["meta"]["message"]); + } + } + // without merge pdf + public function view_transactions_download_report_pickup_bak1(Request $req) + { + // try { + $now = time(); + $input = [ + "ord_code" => $req->ord_code, + ]; + $rulesInput = [ + "ord_code" => "required|numeric", + ]; + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + return abort(403, $isValidInput->messages()->first()); + } + + $filter = [ + "code" => $req->ord_code, + "get_stts_checker" => 1, + "get_checker_data" => 1, + ]; + $order = Orders::showOrder($filter); + if (count($order) < 1) { + return abort(404, "order not found"); + } + + // $ord_pck_seal_img_size = getimagesize(__DIR__.'/../../../storage/app/public/'.$order[0]->ord_pck_seal_img); + // $order[0]->ord_pck_seal_img_width = $ord_pck_seal_img_size[0]; + // $order[0]->ord_pck_seal_img_height = $ord_pck_seal_img_size[1]; + + // $ord_pck_drv_armd_img_size = getimagesize(__DIR__.'/../../../storage/app/public/'.$order[0]->ord_pck_drv_armd_img); + // $order[0]->ord_pck_drv_armd_img_width = $ord_pck_drv_armd_img_size[0]; + // $order[0]->ord_pck_drv_armd_img_height = $ord_pck_drv_armd_img_size[1]; + + $order[0]->ord_pck_docs_client_imgs = []; + foreach (json_decode($order[0]->ord_pck_docs_client_img) as $i => $client_img) { + // $client_img_size = getimagesize(__DIR__.'/../../../storage/app/public/'.$order[0]->ord_pck_drv_armd_img); + $order[0]->ord_pck_docs_client_imgs[$i] = [ + "img" => $client_img, + // 'width' => $client_img_size[0], + // 'height' => $client_img_size[1], + ]; + } + + // if ($order[0]->ord_pck_seal_install_img) { + // $ord_pck_seal_install_img_size = getimagesize(__DIR__.'/../../../storage/app/public/'.$order[0]->ord_pck_seal_install_img); + // $order[0]->ord_pck_seal_install_img_width = $ord_pck_seal_install_img_size[0]; + // $order[0]->ord_pck_seal_install_img_height = $ord_pck_seal_install_img_size[1]; + // } + + // if ($order[0]->ord_pck_goods_img) { + // $ord_pck_goods_img_size = getimagesize(__DIR__.'/../../../storage/app/public/'.$order[0]->ord_pck_goods_img); + // $order[0]->ord_pck_goods_img_width = $ord_pck_goods_img_size[0]; + // $order[0]->ord_pck_goods_img_height = $ord_pck_goods_img_size[1]; + // } + + $pdf = PDF::loadView("menu_v1._printReportPickup", [ + "order" => $order[0], + ]); + return $pdf->setPaper("a4", "potrait")->stream("laporan_penjemputan.pdf"); + // } catch (\Exception $e) { + // $apiResp = Responses::error($e->getMessage()); + // return abort(500, $apiResp['meta']['message']); + // } + } + + // with merge pdf + public function view_transactions_download_report_drop(Request $req) + { + try { + $now = time(); + $input = [ + "ord_code" => $req->ord_code, + ]; + $rulesInput = [ + "ord_code" => "required|numeric", + ]; + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + return abort(403, $isValidInput->messages()->first()); + } + + $filter = [ + "code" => $req->ord_code, + "get_stts_checker" => 1, + "get_checker_data" => 1, + ]; + $order = Orders::showOrder($filter); + if (count($order) < 1) { + return abort(404, "order not found"); + } + + $pdfPath = ""; + foreach (array_slice(explode("/", $order[0]->ord_drop_arrived_img), 0, -1) as $k => $r) { + $pdfPath .= "$r/"; + } + + $pdfMerge = new PDFMerger(); + $availToMergers = []; + + if (strpos($order[0]->ord_drop_arrived_img, ".pdf") !== false) { + $onePagePdf = $this->one_page_one_doc( + "only_title", + $pdfPath, + "Data Pengantaran", + "Foto mobil tiba di tujuan", + "ord_drop_arrived_img", + ); + if ($onePagePdf) { + $availToMergers[] = $onePagePdf; + } + } + $onePagePdf = $this->one_page_one_doc( + $order[0]->ord_drop_arrived_img, + $pdfPath, + "Data Pengantaran", + "Foto mobil tiba di tujuan", + "ord_drop_arrived_img", + ); + if ($onePagePdf) { + $availToMergers[] = $onePagePdf; + } + + if (strpos($order[0]->ord_drop_handover_img, ".pdf") !== false) { + $onePagePdf = $this->one_page_one_doc( + "only_title", + $pdfPath, + "Data Pengantaran", + "Foto serah terima", + "ord_drop_handover_img", + ); + if ($onePagePdf) { + $availToMergers[] = $onePagePdf; + } + } + $onePagePdf = $this->one_page_one_doc( + $order[0]->ord_drop_handover_img, + $pdfPath, + "Data Pengantaran", + "Foto serah terima", + "ord_drop_handover_img", + ); + if ($onePagePdf) { + $availToMergers[] = $onePagePdf; + } + + if (strpos($order[0]->ord_drop_do_ttd_img, ".pdf") !== false) { + $onePagePdf = $this->one_page_one_doc( + "only_title", + $pdfPath, + "Data Pengantaran", + "Foto DO yg sudah di TTD", + "ord_drop_do_ttd_img", + ); + if ($onePagePdf) { + $availToMergers[] = $onePagePdf; + } + } + $onePagePdf = $this->one_page_one_doc( + $order[0]->ord_drop_do_ttd_img, + $pdfPath, + "Data Pengantaran", + "Foto DO yg sudah di TTD", + "ord_drop_do_ttd_img", + ); + if ($onePagePdf) { + $availToMergers[] = $onePagePdf; + } + + if (strpos($order[0]->ord_drop_spk_img, ".pdf") !== false) { + $onePagePdf = $this->one_page_one_doc( + "only_title", + $pdfPath, + "Data Pengantaran", + "Foto surat jalan di TTD", + "ord_drop_spk_img", + ); + if ($onePagePdf) { + $availToMergers[] = $onePagePdf; + } + } + $onePagePdf = $this->one_page_one_doc( + $order[0]->ord_drop_spk_img, + $pdfPath, + "Data Pengantaran", + "Foto surat jalan di TTD", + "ord_drop_spk_img", + ); + if ($onePagePdf) { + $availToMergers[] = $onePagePdf; + } + + foreach ($availToMergers as $key => $row) { + // Storage::disk('local')->get('public/'.$row); + $pdfMerge->addPdf(storage_path("app/public/" . $row), "all", "vertical"); + } + + if (count($availToMergers) > 0) { + $pdfMerge->merge("file", storage_path("app/public/" . $pdfPath . "download_report_drop.pdf")); + } + + return response()->file(storage_path("app/public/" . $pdfPath . "download_report_drop.pdf")); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return abort(500, $apiResp["meta"]["message"]); + } + } + // without merge pdf + public function view_transactions_download_report_drop_bak1(Request $req) + { + // try { + $now = time(); + $input = [ + "ord_code" => $req->ord_code, + ]; + $rulesInput = [ + "ord_code" => "required|numeric", + ]; + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + return abort(403, $isValidInput->messages()->first()); + } + + $filter = [ + "code" => $req->ord_code, + "get_stts_checker" => 1, + "get_checker_data" => 1, + ]; + $order = Orders::showOrder($filter); + if (count($order) < 1) { + return abort(404, "order not found"); + } + + $pdf = PDF::loadView("menu_v1._printReportDrop", [ + "order" => $order[0], + ]); + return $pdf->setPaper("a4", "potrait")->stream("laporan_pengantaran.pdf"); + // } catch (\Exception $e) { + // $apiResp = Responses::error($e->getMessage()); + // return abort(500, $apiResp['meta']['message']); + // } + } + + // with merge pdf + public function view_transactions_download_report_acdnt(Request $req) + { + try { + $now = time(); + $input = [ + "ord_code" => $req->ord_code, + ]; + $rulesInput = [ + "ord_code" => "required|numeric", + ]; + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + return abort(403, $isValidInput->messages()->first()); + } + + $filter = [ + "code" => $req->ord_code, + "get_stts_checker" => 1, + "get_checker_data" => 1, + "get_accidents" => 1, + ]; + $order = Orders::showOrder($filter); + if (count($order) < 1) { + return abort(404, "order not found"); + } + + $pdfPath = ""; + foreach (array_slice(explode("/", $order[0]->ord_pck_seal_img), 0, -1) as $k => $r) { + $pdfPath .= "$r/"; + } + + $pdfMerge = new PDFMerger(); + $availToMergers = []; + + $pdf = PDF::loadView("menu_v1.reports._printReportAcdntText", [ + "title" => "Data Kecelakaan", + "order" => $order[0], + ]); + Storage::disk("local")->put("public/" . $pdfPath . "printReportAcdntText.pdf", $pdf->output()); + $availToMergers[] = $pdfPath . "printReportAcdntText.pdf"; + + $ord_acdnt_imgs = json_decode($order[0]->ord_acdnt_imgs); + foreach ($ord_acdnt_imgs as $i => $client_img) { + if (strpos($client_img, ".pdf") !== false) { + $onePagePdf = $this->one_page_one_doc( + "only_title", + $pdfPath, + "Data Kecelakaan", + "Foto Pendukung", + "ord_acdnt_img_" . $i, + ); + if ($onePagePdf) { + $availToMergers[] = $onePagePdf; + } + } + $onePagePdf = $this->one_page_one_doc( + $client_img, + $pdfPath, + "Data Kecelakaan", + "Foto Pendukung", + "ord_acdnt_img_" . $i, + ); + if ($onePagePdf) { + $availToMergers[] = $onePagePdf; + } + } + + foreach ($availToMergers as $key => $row) { + // Storage::disk('local')->get('public/'.$row); + $pdfMerge->addPdf(storage_path("app/public/" . $row), "all", "vertical"); + } + + if (count($availToMergers) > 0) { + $pdfMerge->merge( + "file", + storage_path("app/public/" . $pdfPath . "download_report_acdnt.pdf"), + ); + } + + return response()->file(storage_path("app/public/" . $pdfPath . "download_report_acdnt.pdf")); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return abort(500, $apiResp["meta"]["message"]); + } + } + // without merge pdf + public function view_transactions_download_report_acdnt_bak1(Request $req) + { + // try { + $now = time(); + $input = [ + "ord_code" => $req->ord_code, + ]; + $rulesInput = [ + "ord_code" => "required|numeric", + ]; + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + return abort(403, $isValidInput->messages()->first()); + } + + $filter = [ + "code" => $req->ord_code, + "get_stts_checker" => 1, + "get_checker_data" => 1, + ]; + $order = Orders::showOrder($filter); + if (count($order) < 1) { + return abort(404, "order not found"); + } + + $pdf = PDF::loadView("menu_v1._printReportAcdnt", [ + "order" => $order[0], + ]); + return $pdf->setPaper("a4", "potrait")->stream("laporan_pengantaran.pdf"); + // } catch (\Exception $e) { + // $apiResp = Responses::error($e->getMessage()); + // return abort(500, $apiResp['meta']['message']); + // } + } + + public function view_transactions_download_spk(Request $req) + { + // try { + $now = time(); + $input = [ + "ord_code" => $req->ord_code, + ]; + $rulesInput = [ + // 'ord_code' => 'required|numeric', // single + "ord_code" => "required|string", + ]; + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + return abort(403, $isValidInput->messages()->first()); + } + + $codes = explode(",", $req->ord_code); + $limit = count($codes); + if ($limit > 2) { + return redirect(route("view_transactions")); + } + $filter = [ + "codes" => $codes, + "get_checker_data" => 1, + "get_prefer_type_truck" => 1, + "get_additional_vehicles_info" => 1, + "get_client_pt" => 1, + "select_region_pck_drop" => 1, + "get_pic_zone" => 1, + "group_by" => "ord.id", + "limit" => $limit, + ]; + $orders = Orders::showOrder($filter); + if (count($orders) < 1) { + return abort(404, "order not found"); + } + $bladeViewOrders = []; + foreach ($orders as $iOrd => $order) { + // get multiple point (pick,drop) + + $_filter = [ + "id" => $order->ord_id, + "get_pic_zone" => 1, + "limit" => $order->drop_total, + ]; + + if (isset($req->point_id)) { + $_filter["point_id"] = $req->point_id; + } + + $adtPoints = Orders::getPoints($_filter); + if (isset($req->point_id) == false) { + // dd($adtPoints); + array_splice($adtPoints, 0, 1); + } + + $orders[$iOrd]->adtPoints = $adtPoints; + + // formated for blade views + $tmpBladeView = clone $order; + if ($order->ord_pck_docs_client_img) { + $tmpBladeView->ord_pck_docs_client_img = json_decode($order->ord_pck_docs_client_img); + } + // if ($order->ord_acdnt_imgs) $tmpBladeView->ord_acdnt_imgs = json_decode($order->ord_acdnt_imgs); + $bladeViewOrders[] = clone $tmpBladeView; + } + // clients/25/logo_1720525752.jpeg + + $client = DB::table("t_orders as to") + ->leftJoin("t_orders_clients as toc", "toc.ord_id", "to.id") + ->leftJoin("t_clients as tc", "tc.id", "toc.c_pt_id") + ->where("to.code", $codes) + ->select("tc.c_name", "tc.c_logo") + ->first(); + $logo = base_path() . "/public/storage/" . $client->c_logo; + + $_view = isset($req->point_id) ? "menu_v1._printSPKSingle" : "menu_v1._printSPK"; + + $pdf = PDF::loadView($_view, [ + "orders" => $orders, + "client" => $client, + "logo" => $logo, + ]); + return $pdf->setPaper("a4", "potrait")->stream("surat_perintah_kerja.pdf"); + // } catch (\Exception $e) { + // $apiResp = Responses::error($e->getMessage()); + // return abort(500, $apiResp['meta']['message']); + // } + } + public function view_transactions_download_summary(Request $req) + { + // try { + $now = time(); + $input = [ + "ord_code" => $req->ord_code, + ]; + $rulesInput = [ + // 'ord_code' => 'required|numeric', // single + "ord_code" => "required|string", + ]; + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + return abort(403, $isValidInput->messages()->first()); + } + + $codes = explode(",", $req->ord_code); + $limit = count($codes); + if ($limit > 2) { + return redirect(route("view_transactions")); + } + $filter = [ + "codes" => $codes, + "get_checker_data" => 1, + "get_prefer_type_truck" => 1, + "get_additional_vehicles_info" => 1, + "get_client_pt" => 1, + "select_region_pck_drop" => 1, + "get_pic_zone" => 1, + "group_by" => "ord.id", + "limit" => $limit, + ]; + $orders = Orders::showOrder($filter); + if (count($orders) < 1) { + return abort(404, "order not found"); + } + // $bladeViewOrders = []; + // foreach ($orders as $iOrd => $order) { + // // get multiple point (pick,drop) + + // $_filter = [ + // "id" => $order->ord_id, + // "get_pic_zone" => 1, + // "limit" => $order->drop_total, + // ]; + + // if (isset($req->point_id)) { + // $_filter["point_id"] = $req->point_id; + // } + + // $adtPoints = Orders::getPoints($_filter); + // if (isset($req->point_id) == false) { + // // dd($adtPoints); + // array_splice($adtPoints, 0, 1); + // } + + // $orders[$iOrd]->adtPoints = $adtPoints; + + // $tmpBladeView = clone $order; + // if ($order->ord_pck_docs_client_img) { + // $tmpBladeView->ord_pck_docs_client_img = json_decode($order->ord_pck_docs_client_img); + // } + // $bladeViewOrders[] = clone $tmpBladeView; + // } + // dd($orders); + + $client = DB::table("t_orders as to") + ->leftJoin("t_orders_clients as toc", "toc.ord_id", "to.id") + ->leftJoin("t_clients as tc", "tc.id", "toc.c_pt_id") + ->where("to.code", $codes) + ->select("tc.c_name", "tc.c_logo") + ->first(); + $logo = base_path() . "/public/storage/" . $client->c_logo; + + $rawData = DB::table("t_orders_pck_drop as topd") + ->leftJoin("t_orders_pickups as top", "top.id", "topd.pck_id") + ->leftJoin("t_orders_drops as tod", "tod.id", "topd.drop_id") + ->where("topd.ord_code", $codes) + ->selectRaw( + "topd.id, + FROM_UNIXTIME(top.set_pck_at, '%d %M %Y') as pck_date, + FROM_UNIXTIME(top.set_pck_at, '%H:%i:%s') as pck_time, + top.pck_name, + top.pck_addr, + top.pic_name as pck_pic_name, + top.pic_phone_val as pck_pic_phone, + tod.drop_name, + tod.drop_addr, + tod.pic_name as drp_pic_name, + tod.pic_phone_val as drp_pic_phone", + ); + if (isset($req->point_id)) { + $rawData->where("topd.id", $req->point_id); + } + $rawData = $rawData->get(); + + foreach ($rawData as $_data) { + $ehck = DB::table("t_orders_drivers_uploads") + ->select( + "id", // + "checklist_name", + "checklist_desc", + "img", + "updt", + ) + ->where("ord_pck_drop_id", $_data->id) + ->get(); + $data[] = [ + "id" => $_data->id, + "pck_date" => $_data->pck_date, + "pck_time" => $_data->pck_time, + "pck_name" => $_data->pck_name, + "pck_addr" => $_data->pck_addr, + "pck_pic_name" => $_data->pck_pic_name, + "pck_pic_phone" => $_data->pck_pic_phone, + "drp_name" => $_data->drop_name, + "drp_addr" => $_data->drop_addr, + "drp_pic_name" => $_data->drp_pic_name, + "drp_pic_phone" => $_data->drp_pic_phone, + "checklist_array" => $ehck, + ]; + } + // $summary = [ + // "orders" => $orders, + // "client" => $client, + // "logo" => $logo, + // "data" => $data, + // ]; + // dd($summary); + // dd($data); + $pdf = PDF::loadView("menu_v1._printSumarry", [ + "orders" => $orders, + "client" => $client, + "logo" => $logo, + "data" => $data, + ]); + return $pdf->setPaper("a4", "potrait")->stream("surat_perintah_kerja.pdf"); + // } catch (\Exception $e) { + // $apiResp = Responses::error($e->getMessage()); + // return abort(500, $apiResp['meta']['message']); + // } + } + public function view_transactions_download_spk_single_bak(Request $req) + { + // try { + $now = time(); + $input = [ + "ord_code" => $req->ord_code, + ]; + $rulesInput = [ + // 'ord_code' => 'required|numeric', // single + "ord_code" => "required|string", + ]; + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + return abort(403, $isValidInput->messages()->first()); + } + + $codes = explode(",", $req->ord_code); + $limit = count($codes); + if ($limit > 2) { + return redirect(route("view_transactions")); + } + + $filter = [ + "codes" => $codes, + "get_checker_data" => 1, + "get_prefer_type_truck" => 1, + "get_additional_vehicles_info" => 1, + "get_client_pt" => 1, + "select_region_pck_drop" => 1, + "get_pic_zone" => 1, + ]; + $orders = Orders::showOrder($filter); + if (count($orders) < 1) { + return abort(404, "order not found"); + } + $adtPoints = Orders::getPoints([ + "id" => $orders[0]->ord_id, + "limit" => $orders[0]->drop_total, + "get_pic_zone" => 1, + ]); + array_splice($adtPoints, 0, 1); + + $pdf = PDF::loadView("menu_v1._printSPK", [ + "order" => $orders[0], + "adtPoints" => $adtPoints, + ]); + return $pdf->setPaper("a4", "potrait")->stream("surat_perintah_kerja.pdf"); + // } catch (\Exception $e) { + // $apiResp = Responses::error($e->getMessage()); + // return abort(500, $apiResp['meta']['message']); + // } + } + + /** + * API + */ + + public function api_check_packing_list(Request $req) + { + try { + $now = time(); + + $input = [ + "packing_list" => $req->packing_list, + // 'weight' => $req->weight, + // 'cbm' => $req->cbm, + // 'koli' => $req->koli, + // 'Item Code' => $req->input('Item Code'), + // 'Description' => $req->input('Description'), + // 'Weight (kg)' => $req->input('Weight (kg)'), + // 'Qty' => $req->input('Qty'), + // 'Length (cm)' => $req->input('Length (cm)'), + // 'Wide (cm)' => $req->input('Wide (cm)'), + // 'Height (cm)' => $req->input('Height (cm)'), + // 'Volume (m3)' => $req->input('Volume (m3)'), + ]; + $rulesInput = [ + "packing_list" => "required|array", + "packing_list.*.Item Code" => "required|string", + "packing_list.*.Description" => "required|string", + "packing_list.*.Weight (kg)" => "required|numeric|min:0", + // 'packing_list.*.Qty' => 'required|numeric|min:0', + "packing_list.*.Length (cm)" => "required|numeric|min:0", + "packing_list.*.Wide (cm)" => "required|numeric|min:0", + "packing_list.*.Height (cm)" => "required|numeric|min:0", + "packing_list.*.Volume (m3)" => "required|numeric|min:0", + // 'weight' => 'required', + // 'cbm' => 'required', + // 'koli' => 'required', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + // $apiResp = Responses::bad_input('packing list invalid'); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $calc_weight = 0; + // $total_qty = 0; + $total_koli = 0; + $calc_length = 0; + $calc_wide = 0; + $calc_height = 0; + $calc_cbm = 0; + + foreach ($req->packing_list as $k => $v) { + if (count(OrdersItems::getOrderItemByCode($v["Item Code"])) > 0) { + $apiResp = Responses::bad_request( + "Item Code: " . $v["Item Code"] . " not uniq, please reupload your packing list", + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + // if (!is_numeric($v['Qty'])) { + // $v['Qty'] = 0; + // } + // $total_qty += $v['Qty']; + if (!is_numeric($v["Weight (kg)"])) { + $v["Weight (kg)"] = 0; + } + // $calc_weight += $v['Weight (kg)'] * $v['Qty']; + $calc_weight += $v["Weight (kg)"]; + if (!is_numeric($v["Length (cm)"])) { + $v["Length (cm)"] = 0; + } + $calc_length += $v["Length (cm)"]; + if (!is_numeric($v["Wide (cm)"])) { + $v["Wide (cm)"] = 0; + } + $calc_wide += $v["Wide (cm)"]; + if (!is_numeric($v["Height (cm)"])) { + $v["Height (cm)"] = 0; + } + $calc_height += $v["Height (cm)"]; + if (!is_numeric($v["Volume (m3)"])) { + $v["Volume (m3)"] = 0; + } + // $calc_volume = ($v['Length (cm)'] * $v['Wide (cm)'] * $v['Height (cm)']) * $v['Qty']; + $calc_volume = ($v["Length (cm)"] * $v["Wide (cm)"] * $v["Height (cm)"]) / 1000000; + // $v['Volume (m3)'] = $v['Volume (m3)'] * $v['Qty']; + $v["Volume (m3)"] = $v["Volume (m3)"]; + if ($calc_volume > $v["Volume (m3)"]) { + $calc_cbm += $calc_volume; + } else { + $calc_cbm += $v["Volume (m3)"]; + } + + $total_koli++; + } + + // if (is_numeric($req->weight)) { + // if ($calc_weight > $req->weight) { + // // $apiResp = Responses::bad_request('The input weight is less than then total weight of the packing list'); + // $apiResp = Responses::bad_request('Total weight of the packing list is greater than the input weight, please reupload your packing list'); + // return new Response($apiResp, $apiResp['meta']['code']); + // } else { + // $calc_weight = $req->weight; + // } + // } + // if (is_numeric($req->cbm)) { + // if ($calc_cbm > $req->cbm) { + // // $apiResp = Responses::bad_request('The input volume is less than then total volume of the packing list'); + // $apiResp = Responses::bad_request('Total volume of the packing list is greater than the input volume, please reupload your packing list'); + // return new Response($apiResp, $apiResp['meta']['code']); + // } else { + // $calc_cbm = $req->cbm; + // } + // } + // if (is_numeric($req->koli)) { + // if ($total_qty > $req->koli) { + // // $apiResp = Responses::bad_request('The input koli is less than then total koli of the packing list'); + // $apiResp = Responses::bad_request('Total koli of the packing list is greater than the input koli, please reupload your packing list'); + // return new Response($apiResp, $apiResp['meta']['code']); + // } else { + // $total_qty = $total_qty; + // } + // } + if ($calc_weight === 0 && $calc_cbm === 0) { + $apiResp = Responses::bad_request( + "You must fill in at least 1 of weight / dimension / volume on packing list.", + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $apiResp = Responses::success("packing list valid"); + $apiResp["data"] = [ + "calc_weight" => $calc_weight, + "calc_cbm" => $calc_cbm, + // 'total_qty' => $total_qty, + "total_koli" => $total_koli, + ]; + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_checkout_v1(Request $req) + { + try { + $now = time(); + + $input = [ + "pickup_at" => $req->pickup_at, + "pickup_zone_id" => $req->pickup_zone_id, + "drop_zone_id" => $req->drop_zone_id, + "weight" => $req->weight, + "cbm" => $req->cbm, + "koli" => $req->koli, + "truck_type_id" => $req->truck_type_id, + "truck_type_name" => $req->truck_type_name, + "truck_type_weight" => $req->truck_type_weight, + "truck_type_cbm" => $req->truck_type_cbm, + "truck_type_koli" => $req->truck_type_koli, + ]; + $rulesInput = [ + "pickup_at" => "required|integer", + "pickup_zone_id" => "required|integer", + "drop_zone_id" => "required|integer", + "weight" => "nullable", + "cbm" => "nullable", + "koli" => "nullable", + "truck_type_id" => "required|numeric", + "truck_type_name" => "nullable|string", + "truck_type_weight" => "nullable", + "truck_type_cbm" => "nullable", + "truck_type_koli" => "nullable", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + if (!is_numeric($req->weight) && !is_numeric($req->cbm) && !is_numeric($req->koli)) { + $apiResp = Responses::bad_request("You must fill in at least 1 of the packing list."); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + if ($req->weight === 0 && $req->cbm === 0 && $req->koli === 0) { + $apiResp = Responses::bad_request("You must fill in at least 1 of the packing list."); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $pck = Zone::getZoneById($req->pickup_zone_id); + if (count($pck) < 1) { + $apiResp = Responses::bad_request("Pickup zone not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + if ($pck[0]->prid == 0) { + $apiResp = Responses::bad_request( + "Pickup zone province not filled, please recheck input province zone", + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $drop = Zone::getZoneById($req->drop_zone_id); + if (count($drop) < 1) { + $apiResp = Responses::bad_request("Drop zone not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + if ($drop[0]->ktid == 0) { + $apiResp = Responses::bad_request( + "Drop zone city not filled, please recheck input city zone", + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + if ($drop[0]->kcid == 0) { + $apiResp = Responses::bad_request( + "Drop zone district not filled, please recheck input district zone", + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $rates = ConfRates::getRateByDestDistrict($pck[0]->prid, $drop[0]->kcid); + if (count($rates) < 1) { + $rates = ConfRates::getRateByDestCity($pck[0]->prid, $drop[0]->ktid); + } + + if (count($rates) < 1) { + $apiResp = Responses::bad_request("No service available going to drop zone"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + // check maximum weight / cbm truck type yang ada sekarang + $use_price_cbm = 1; + $use_price_weight = 1; + if ($req->truck_type_id && $req->truck_type_id != 0) { + if ($req->truck_type_cbm != 0 && $req->truck_type_cbm > $req->cbm) { + $apiResp = Responses::bad_request("Cbm is over load"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } elseif ($req->truck_type_weight != 0 && $req->truck_type_weight > $req->weight) { + $apiResp = Responses::bad_request("Weight is over load"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } else { + $apiResp = Responses::bad_request("Package list is over load"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } else { + $truck_types = ConfTruckTypes::listTruckTypesRates( + ConfTruckTypes::IS_ACTIVE, + ConfRates::LANE_EARTH, + ); + if (count($truck_types) < 1) { + $apiResp = Responses::bad_request("No vehicle available"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + $is_tt_overload = 1; + foreach ($truck_types as $k => $v) { + if ($v->max_cbm != 0 && $v->max_cbm < $req->cbm) { + $is_tt_overload = 0; + } elseif ($v->max_kg != 0 && $v->max_kg < $req->weight) { + $is_tt_overload = 0; + } + } + if (!$is_tt_overload) { + $apiResp = Responses::bad_request("Package list is over load"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + $client = Clients::getClientById($req->auth->client_group_id); + + $opts = []; + foreach ($rates as $k => $v) { + $opt = [ + "is_best" => 0, + ]; + if ($k === 0) { + $opt["is_best"] = 1; + } + $opt["lead_time_id"] = $v->id; + // $center_time = $v->long_time - $v->fast_time; + $opt["lead_time"] = $v->long_time; + $price = 0; + if (is_numeric($req->cbm) && $req->cbm != 0 && $v->sell_cbm != 0 && $use_price_cbm != 0) { + $price = $req->cbm * $v->sell_cbm; + } else { + if ( + is_numeric($req->weight) && + $req->weight != 0 && + $v->sell_kg != 0 && + $use_price_weight != 0 + ) { + $price = $req->weight * $v->sell_kg; + } else { + if (is_numeric($req->koli) && $req->koli != 0 && $v->sell_cbm != 0) { + $price = $req->koli * Orders::ONE_KG_ONE_CBM * $v->sell_cbm; + } + } + } + if ($price == 0) { + $apiResp = Responses::bad_request("No service provided"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + $opt["price"] = $price; + $opt["real_price"] = $price; + $opt["disc_price"] = 0; + $opt["disc_type"] = $client[0]->disc_type; + $opt["disc_percent"] = 0; + if ($client[0]->disc_type === Clients::DISC_TYPE_FIX) { + $opt["disc_price"] = $client[0]->disc_amount; + $opt["price"] = $opt["price"] - $opt["disc_price"]; + } elseif ($client[0]->disc_type === Clients::DISC_TYPE_PERCENT) { + $opt["disc_percent"] = $client[0]->disc_amount; + $opt["disc_price"] = ($opt["price"] * $client[0]->disc_amount) / 100; + $opt["price"] = $opt["price"] - $opt["disc_price"]; + } + // group by lead_time and sell_price + $isSame = 0; + foreach ($opts as $key => $val) { + if ($val["price"] == $opt["price"] && $val["lead_time"] == $opt["lead_time"]) { + $isSame = 1; + } + } + if ($isSame === 1) { + continue; + } + array_push($opts, $opt); + } + + $apiResp = Responses::success("checkout success"); + $apiResp["data"] = $opts; + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_checkout_v2(Request $req) + { + try { + // $apiResp = Responses::bad_request("Service on maintenance"); + // return new Response($apiResp, $apiResp["meta"]["code"]); + + // $now = time(); + + $input = [ + "pickup_at" => $req->pickup_at, + "pickup_zone_id" => $req->pickup_zone_id, + "drop_zone_id" => $req->drop_zone_id, + "truck_type_id" => $req->truck_type_id, + "truck_type_name" => $req->truck_type_name, + ]; + $rulesInput = [ + "pickup_at" => "required|integer", + "pickup_zone_id" => "required|integer", + "drop_zone_id" => "required|integer", + "truck_type_id" => "required|numeric", + "truck_type_name" => "nullable|string", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $adm_id = 0; + $crt_type_order = Orders::CRT_TYPE_ORDER_CLIENT; + if ($req->auth->role === Users::ROLE_ADMIN) { + $subInput = [ + "uid" => $req->uid, + ]; + $rulesSubInput = [ + "uid" => "required|integer|not_in:0", + ]; + + // validasi subInput + $isValidInput = Validator::make($subInput, $rulesSubInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + $adminAuth = $req->auth; + $req->auth = Users::getUserById($req->uid)[0]; + $req->auth->uid = $req->auth->id; + + $adm_id = $adminAuth->uid; + $crt_type_order = Orders::CRT_TYPE_ORDER_ADMIN; + } + + $pck = Zone::getZoneById($req->pickup_zone_id); + if (count($pck) < 1) { + $apiResp = Responses::bad_request("Pickup zone not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + if ($pck[0]->prid == 0) { + $apiResp = Responses::bad_request( + "Pickup zone province not filled, please recheck input province zone", + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $drop = Zone::getZoneById($req->drop_zone_id); + if (count($drop) < 1) { + $apiResp = Responses::bad_request("Drop zone not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + if ($drop[0]->ktid == 0) { + $apiResp = Responses::bad_request( + "Drop zone city not filled, please recheck input city zone", + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + if ($drop[0]->kcid == 0) { + $apiResp = Responses::bad_request( + "Drop zone district not filled, please recheck input district zone", + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $rates = ConfRates::getRateByDestDistrict($pck[0]->prid, $drop[0]->kcid); + // dd($rates); + if (count($rates) < 1) { + $rates = ConfRates::getRateByDestCity($pck[0]->prid, $drop[0]->ktid); + } + + if (count($rates) < 1) { + $apiResp = Responses::bad_request("No service available going to drop zone"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $client = Clients::getClientById($req->auth->client_group_id); + + $check_truck_type = false; + $ttid = 0; + if ($req->truck_type_id && $req->truck_type_id != 0) { + $check_truck_type = true; + $ttid = (int) $req->truck_type_id; + } + + $opts = []; + foreach ($rates as $k => $v) { + if ($check_truck_type) { + if ($v->vhc_type !== $ttid) { + continue; + } + } + + $opt = [ + "is_best" => 0, + ]; + if ($k === 0) { + $opt["is_best"] = 1; + } + $opt["lead_time_id"] = $v->id; + // $center_time = $v->long_time - $v->fast_time; + $opt["lead_time"] = $v->long_time; + $price = $v->sell_ftl ?? 0; + + // TRIGER JIKA HARGA 0 + // if ($price < 1) { + // $apiResp = Responses::bad_request("No service provided"); + // return new Response($apiResp, $apiResp["meta"]["code"]); + // } + $opt["price"] = $price; + $opt["real_price"] = $price; + $opt["disc_price"] = 0; + $opt["disc_type"] = $client[0]->disc_type; + $opt["disc_percent"] = 0; + if ($client[0]->disc_type === Clients::DISC_TYPE_FIX) { + $opt["disc_price"] = $client[0]->disc_amount; + $opt["price"] = $opt["price"] - $opt["disc_price"]; + } elseif ($client[0]->disc_type === Clients::DISC_TYPE_PERCENT) { + $opt["disc_percent"] = $client[0]->disc_amount; + $opt["disc_price"] = ($opt["price"] * $client[0]->disc_amount) / 100; + $opt["price"] = $opt["price"] - $opt["disc_price"]; + } + // group by lead_time and sell_price + $isSame = 0; + foreach ($opts as $key => $val) { + if ($val["price"] == $opt["price"] && $val["lead_time"] == $opt["lead_time"]) { + $isSame = 1; + } + } + if ($isSame === 1) { + continue; + } + array_push($opts, $opt); + } + // dd(count($opts)); + if (count($opts) < 1 && $check_truck_type) { + $apiResp = Responses::bad_request("No truck type available going to drop zone"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $apiResp = Responses::success("checkout success"); + $apiResp["data"] = $opts; + + if ($req->is_insurance === "true") { + $insurances = Insurances::getInsurancesByRangeBeneficiaryAndActive($req->amt_beneficiary); + if (count($insurances) < 1) { + $apiResp = Responses::bad_request("Total pertangguhan tidak tersedia"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + $apiResp["insurance"] = $insurances[0]; + } + + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_create_order_v1(Request $req) + { + try { + $now = time(); + + $input = [ + "pickup_at" => $req->pickup_at, + "pickup_zone_id" => $req->pickup_zone_id, + "drop_zone_id" => $req->drop_zone_id, + "weight" => $req->weight, + "cbm" => $req->cbm, + "koli" => $req->koli, + "qty" => $req->qty, + "packing_list" => $req->packing_list, + "lead_time" => $req->lead_time, + "price" => $req->price, + "real_price" => $req->real_price, + "disc_price" => $req->disc_price, + "lead_time_id" => $req->lead_time_id, + "truck_type_id" => $req->truck_type_id, + "truck_type_name" => $req->truck_type_name, + "truck_type_weight" => $req->truck_type_weight, + "truck_type_cbm" => $req->truck_type_cbm, + "truck_type_koli" => $req->truck_type_koli, + ]; + $rulesInput = [ + "pickup_at" => "required|integer", + "pickup_zone_id" => "required|integer", + "drop_zone_id" => "required|integer", + "weight" => "nullable", + "cbm" => "nullable", + "koli" => "nullable", + "qty" => "nullable", + "packing_list" => "required|array", + "packing_list.*.Item Code" => "required|string", + "packing_list.*.Description" => "required|string", + "packing_list.*.Weight (kg)" => "required|numeric|min:0", + // 'packing_list.*.Qty' => 'required|numeric|min:0', + "packing_list.*.Length (cm)" => "required|numeric|min:0", + "packing_list.*.Wide (cm)" => "required|numeric|min:0", + "packing_list.*.Height (cm)" => "required|numeric|min:0", + "packing_list.*.Volume (m3)" => "required|numeric|min:0", + "lead_time" => "required|numeric", + "price" => "required|numeric", + "real_price" => "required|numeric", + "disc_price" => "required|numeric", + "lead_time_id" => "required|integer|not_in:0", + "truck_type_id" => "nullable|numeric", + "truck_type_name" => "nullable|string", + "truck_type_weight" => "nullable", + "truck_type_cbm" => "nullable", + "truck_type_koli" => "nullable", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $type_truck_name = $req->truck_type_name; + if ($req->truck_type_id && $req->truck_type_id != 0) { + $type_truck_name = $req->truck_type_name; + } else { + $type_truck_name = ""; + $req->truck_type_id = 0; + } + + if (!is_numeric($req->weight)) { + $req->weight = 0; + } + if (!is_numeric($req->cbm)) { + $req->cbm = 0; + } + if (!is_numeric($req->koli)) { + $req->koli = 0; + } + if (!is_numeric($req->qty)) { + $req->qty = 0; + } + + $nanoid = new Nanoid(); + $code = $nanoid->formattedId("0123456789", 12); + $uniqCode = Orders::getOrderByCode($code); + if (count($uniqCode) > 0) { + $code = $nanoid->formattedId("0123456789", 12); + if (count($uniqCode) > 0) { + $code = $nanoid->formattedId("0123456789", 12); + if (count($uniqCode) > 0) { + $code = $nanoid->formattedId("0123456789", 12); + $apiResp = Responses::bad_request("code has been used, try again"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + } + + $client = Clients::getClientById($req->auth->client_group_id); + $rate = ConfRates::getRateById($req->lead_time_id); + $pck = Zone::getZoneById($req->pickup_zone_id); + // $pck_pic = Clients::getClientById($pck[0]->client_group_id); + $drop = Zone::getZoneById($req->drop_zone_id); + // $drop_pic = Clients::getClientById($drop[0]->client_group_id); + $admins = Users::getUsersActiveByRole(Users::ROLE_ADMIN); + + $admins_data = []; + foreach ($admins as $k => $v) { + array_push($admins_data, [ + "admin_id" => $v->id, + "admin_name" => $v->first_name, + "admin_phone" => $v->phone_code . " " . implode(" ", str_split($v->phone, 4)), + "admin_mail" => $v->email, + "admin_addr" => "", + ]); + } + + DB::beginTransaction(); + + $insOrd = [ + "code" => $code, + "type" => Orders::TYPE_FCL, + "pck_total" => 1, + "drop_total" => 1, + "est_weight" => $req->weight, + "weight" => $req->weight, + "est_cbm" => $req->cbm, + "cbm" => $req->cbm, + "est_koli" => $req->koli, + "koli" => $req->koli, + "est_qty" => $req->qty, + "qty" => $req->qty, + "est_lead_time" => $req->lead_time, + "lead_time" => $req->lead_time, + "est_price" => $req->price, + "price" => $req->price, + "est_real_price" => $req->real_price, + "real_price" => $req->real_price, + "est_disc_price" => $req->disc_price, + "disc_price" => $req->disc_price, + "est_rate_id" => $req->lead_time_id, + "rate_id" => $req->lead_time_id, + "crt" => $now, + "crt_by" => $req->auth->uid, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]; + $ord_id = Orders::addOrder($insOrd); + + if ($pck[0]->boundary_bounds) { + // $pck[0]->boundary_bounds = json_encode($pck[0]->boundary_bounds); + } + if ($pck[0]->boundary_latlngs) { + // $pck[0]->boundary_latlngs = json_encode($pck[0]->boundary_latlngs); + } + + $insPck = [ + "ord_id" => $ord_id, + "ord_code" => $code, + "set_pck_at" => $req->pickup_at, + "stts_pck" => OrdersPickups::STTS_WAIT, + "pck_id" => $pck[0]->id, + "pck_name" => $pck[0]->name, + "pck_desc" => $pck[0]->desc, + "pck_type" => $pck[0]->type, + "pck_workflow" => $pck[0]->workflow_type, + "pck_shiptocode" => $pck[0]->shiptocode, + "pck_prid" => $pck[0]->prid, + "pck_ktid" => $pck[0]->ktid, + "pck_kcid" => $pck[0]->kcid, + "pck_klid" => $pck[0]->klid, + "pck_addr" => $pck[0]->fulladdress, + "pck_cgroup_id" => $pck[0]->client_group_id, + "pck_cdiv_id" => $pck[0]->client_div_id, + "pck_cgp_id" => $pck[0]->client_gp_id, + "pck_hex_color" => $pck[0]->boundary_hex_color, + "pck_shape" => $pck[0]->boundary_type, + "pck_radius" => $pck[0]->boundary_radius, + "pck_bounds" => $pck[0]->boundary_bounds, + "pck_latlngs" => $pck[0]->boundary_latlngs, + "pck_points" => $pck[0]->boundary_points, + // 'pic_name' => $pck_pic[0]->pic_name, + // 'pic_phone_code' => $pck_pic[0]->pic_phone_code, + // 'pic_phone_val' => $pck_pic[0]->pic_phone, + // 'pic_mail' => $pck_pic[0]->pic_mail, + "pic_name" => $req->auth->first_name, + "pic_phone_code" => $req->auth->phone_code, + "pic_phone_val" => $req->auth->phone, + "pic_mail" => $req->auth->email, + "est_weight" => $req->weight, + "weight" => $req->weight, + "est_cbm" => $req->cbm, + "cbm" => $req->cbm, + "est_koli" => $req->koli, + "koli" => $req->koli, + "est_qty" => $req->qty, + "qty" => $req->qty, + ]; + + $pck_id = OrdersPickups::add($insPck); + + if ($drop[0]->boundary_bounds) { + // $drop[0]->boundary_bounds = json_encode($drop[0]->boundary_bounds); + } + if ($drop[0]->boundary_latlngs) { + // $drop[0]->boundary_latlngs = json_encode($drop[0]->boundary_latlngs); + } + + $insDrop = [ + "ord_id" => $ord_id, + "ord_code" => $code, + "stts_drop" => OrdersDrops::STTS_WAIT, + "drop_id" => $drop[0]->id, + "drop_name" => $drop[0]->name, + "drop_desc" => $drop[0]->desc, + "drop_type" => $drop[0]->type, + "drop_workflow" => $drop[0]->workflow_type, + "drop_shiptocode" => $drop[0]->shiptocode, + "drop_prid" => $drop[0]->prid, + "drop_ktid" => $drop[0]->ktid, + "drop_kcid" => $drop[0]->kcid, + "drop_klid" => $drop[0]->klid, + "drop_addr" => $drop[0]->fulladdress, + "drop_cgroup_id" => $drop[0]->client_group_id, + "drop_cdiv_id" => $drop[0]->client_div_id, + "drop_cgp_id" => $drop[0]->client_gp_id, + "drop_hex_color" => $drop[0]->boundary_hex_color, + "drop_shape" => $drop[0]->boundary_type, + "drop_radius" => $drop[0]->boundary_radius, + "drop_bounds" => $drop[0]->boundary_bounds, + "drop_latlngs" => $drop[0]->boundary_latlngs, + "drop_points" => $drop[0]->boundary_points, + // 'pic_name' => $drop_pic[0]->pic_name, + // 'pic_phone_code' => $drop_pic[0]->pic_phone_code, + // 'pic_phone_val' => $drop_pic[0]->pic_phone, + // 'pic_mail' => $drop_pic[0]->pic_mail, + "pic_name" => $req->auth->first_name, + "pic_phone_code" => $req->auth->phone_code, + "pic_phone_val" => $req->auth->phone, + "pic_mail" => $req->auth->email, + "est_weight" => $req->weight, + "weight" => $req->weight, + "est_cbm" => $req->cbm, + "cbm" => $req->cbm, + "est_koli" => $req->koli, + "koli" => $req->koli, + "est_qty" => $req->qty, + "qty" => $req->qty, + ]; + $drop_id = OrdersDrops::add($insDrop); + + $insClient = [ + "ord_id" => $ord_id, + "ord_code" => $code, + "c_id" => $req->auth->uid, + "c_name" => $req->auth->first_name, + "c_phone_code" => $req->auth->phone_code, + "c_phone_val" => $req->auth->phone, + "c_mail" => $req->auth->email, + "c_addr" => $req->auth->fulladdress, + "c_disc_type" => $client[0]->disc_type, + "c_disc_amount" => $client[0]->disc_amount, + "c_pt_id" => $client[0]->id, + "c_pt_div_id" => $req->auth->client_div_id, + "c_pt_gp_id" => $req->auth->client_gp_id, + "c_pt_name" => $client[0]->c_name, + "c_pt_phone_code" => $client[0]->c_phone_code, + "c_pt_phone_val" => $client[0]->c_phone, + "c_pt_mail" => $client[0]->c_mail, + "c_pt_addr" => $client[0]->c_addr_office, + "c_pt_pic_name" => $client[0]->pic_name, + "c_pt_pic_phone_code" => $client[0]->pic_phone_code, + "c_pt_pic_phone_val" => $client[0]->pic_phone, + "c_pt_pic_mail" => $client[0]->pic_mail, + "c_pt_pic_addr" => null, + "prefer_truck_type" => $req->truck_type_id, + ]; + $ord_client_id = OrdersClients::add($insClient); + + foreach ($req->packing_list as $k => $v) { + $insItems = [ + "ord_id" => $ord_id, + "ord_code" => $code, + "pck_id" => $pck_id, + "drop_id" => $drop_id, + "item_code" => $v["Item Code"], + "desc" => $v["Description"], + "unit_weight" => OrdersItems::DEFAULT_WEIGHT_UNIT, + "weight" => $v["Weight (kg)"], + "unit_dimension" => OrdersItems::DEFAULT_DIMENSION_UNIT, + // 'qty' => $v['Qty'] ?? 0, + "length" => $v["Length (cm)"], + "wide" => $v["Wide (cm)"], + "height" => $v["Height (cm)"], + "volume" => $v["Volume (m3)"], + "crt" => $now, + ]; + OrdersItems::add($insItems); + } + + $insRate = [ + "ord_id" => $ord_id, + "ord_code" => $code, + "rate_id" => $rate[0]->id, + "rate_code" => $rate[0]->code, + "origin_prov" => $rate[0]->origin_prov, + "origin_city" => $rate[0]->origin_city, + "origin_district" => $rate[0]->origin_district, + "origin_village" => $rate[0]->origin_village, + "lane" => $rate[0]->lane, + "dest_prov" => $rate[0]->dest_prov, + "dest_city" => $rate[0]->dest_city, + "dest_district" => $rate[0]->dest_district, + "dest_village" => $rate[0]->dest_village, + "fast_time" => $rate[0]->fast_time, + "long_time" => $rate[0]->long_time, + "unit_time" => $rate[0]->unit_time, + "sell_kg" => $rate[0]->sell_kg, + "buy_kg" => $rate[0]->buy_kg, + "margin_kg" => $rate[0]->margin_kg, + "percent_kg" => $rate[0]->percent_kg, + "sell_cbm" => $rate[0]->sell_cbm, + "buy_cbm" => $rate[0]->buy_cbm, + "margin_cbm" => $rate[0]->margin_cbm, + "percent_cbm" => $rate[0]->percent_cbm, + "vdr_id" => $rate[0]->vdr_id, + "vhc_type" => $rate[0]->vhc_type, + ]; + OrdersRates::add($insRate); + + $url = env("API_URL_NODE") . "/order/create"; + $guzReq = new GuzzleClient(); + $respNode = $guzReq->request("POST", $url, [ + "headers" => [ + "Host" => $_SERVER["SERVER_ADDR"], + "User-Agent" => "curl/7.65.3", + "Accept" => "*/*", + "Accept-Encoding" => "gzip, deflate, br", + // 'Content-Type' => 'application/x-www-form-urlencoded; charset=UTF-8', + // 'Connection' => 'keep-alive', + ], + "json" => [ + "trx_code" => $code, + "trx_at" => $now, + "client_id" => $req->auth->uid, + "client_name" => $req->auth->first_name, + "client_phone" => + $req->auth->phone_code . " " . implode(" ", str_split($req->auth->phone, 4)), + "client_mail" => $req->auth->email, + "client_addr" => "", + "client_prefer_type_truck" => $type_truck_name, + "weight" => $req->weight, + "cbm" => $req->cbm, + "koli" => $req->koli, + "pickup_zone_title" => $pck[0]->name, + "pickup_zone_addr" => $pck[0]->fulladdress, + "pickup_at" => $req->pickup_at, + "drop_zone_title" => $drop[0]->name, + "drop_zone_addr" => $drop[0]->fulladdress, + "admins" => $admins_data, + ], + ]); + if ($respNode->getStatusCode() != 200) { + DB::rollBack(); + $apiResp = Responses::bad_request("fail create order 0"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + $body = json_decode($respNode->getBody()->getContents()); + + $apiResp = Responses::created("success create order"); + + DB::commit(); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_create_order_v2(Request $req) + { + try { + // $apiResp = Responses::bad_request("Service on maintenance"); + // return new Response($apiResp, $apiResp["meta"]["code"]); + $now = time(); + + $input = [ + "pickup_at" => $req->pickup_at, + "pickup_zone_id" => $req->pickup_zone_id, + "drop_zone_id" => $req->drop_zone_id, + "lead_time" => $req->lead_time, + "price" => $req->price, + "real_price" => $req->real_price, + "disc_price" => $req->disc_price, + "lead_time_id" => $req->lead_time_id, + "truck_type_id" => $req->truck_type_id, + "truck_type_name" => $req->truck_type_name, + ]; + $rulesInput = [ + "pickup_at" => "required|integer", + "pickup_zone_id" => "required|integer", + "drop_zone_id" => "required|integer", + "lead_time" => "required|numeric", + "price" => "required|numeric", + "real_price" => "required|numeric", + "disc_price" => "required|numeric", + "lead_time_id" => "required|integer|not_in:0", + "truck_type_id" => "nullable|numeric", + "truck_type_name" => "nullable|string", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $adm_id = 0; + $crt_type_order = Orders::CRT_TYPE_ORDER_CLIENT; + if ($req->auth->role === Users::ROLE_ADMIN) { + $subInput = [ + "uid" => $req->uid, + ]; + $rulesSubInput = [ + "uid" => "required|integer|not_in:0", + ]; + + // validasi subInput + $isValidInput = Validator::make($subInput, $rulesSubInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + $adminAuth = $req->auth; + $req->auth = Users::getUserById($req->uid)[0]; + $req->auth->uid = $req->auth->id; + + $adm_id = $adminAuth->uid; + $crt_type_order = Orders::CRT_TYPE_ORDER_ADMIN; + } + + $type_truck_name = $req->truck_type_name; + if ($req->truck_type_id && $req->truck_type_id != 0) { + $type_truck_name = $req->truck_type_name; + } else { + $type_truck_name = ""; + $req->truck_type_id = 0; + } + + $nanoid = new Nanoid(); + $code = $nanoid->formattedId("0123456789", 12); + $doWhile = true; + do { + $uniqCode = Orders::getOrderByCode($code); + if (count($uniqCode) > 0) { + $code = $nanoid->formattedId("0123456789", 12); + } else { + $doWhile = false; + } + } while ($doWhile); + + $client = Clients::getClientById($req->auth->client_group_id); + $rate = ConfRates::getRateById($req->lead_time_id); + $pck = Zone::getZoneById($req->pickup_zone_id); + // $pck_pic = Clients::getClientById($pck[0]->client_group_id); + $drop = Zone::getZoneById($req->drop_zone_id); + // $drop_pic = Clients::getClientById($drop[0]->client_group_id); + $admins = Users::getUsersActiveByRole(Users::ROLE_ADMIN); + $insurance = []; + if ($req->is_insurance === "true") { + $insurance = Insurances::getInsuranceById($req->insurance_id); + if (count($insurance) < 1) { + $apiResp = Responses::bad_request("Insurance not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + $admins_data = []; + foreach ($admins as $k => $v) { + array_push($admins_data, [ + "admin_id" => $v->id, + "admin_name" => $v->first_name, + "admin_phone" => $v->phone_code . " " . implode(" ", str_split($v->phone, 4)), + "admin_mail" => $v->email, + "admin_addr" => "", + ]); + } + DB::beginTransaction(); + + $insOrd = [ + "code" => $code, + "type" => Orders::TYPE_FCL, + "pck_total" => 1, + "drop_total" => 1, + "est_lead_time" => $req->lead_time, + "lead_time" => $req->lead_time, + "est_price" => $req->price, + "price" => $req->price, + "est_real_price" => $req->real_price, + "real_price" => $req->real_price, + "est_disc_price" => $req->disc_price, + "disc_price" => $req->disc_price, + "est_rate_id" => $req->lead_time_id, + "rate_id" => $req->lead_time_id, + "crt_type_order" => $crt_type_order, + "crt" => $now, + "crt_by" => $req->auth->uid, + "crt_adm_by" => $adm_id, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]; + $ord_id = Orders::addOrder($insOrd); + + // if ($pck[0]->boundary_bounds) { + // // $pck[0]->boundary_bounds = json_encode($pck[0]->boundary_bounds); + // } + // if ($pck[0]->boundary_latlngs) { + // // $pck[0]->boundary_latlngs = json_encode($pck[0]->boundary_latlngs); + // } + + $insPck = [ + "ord_id" => $ord_id, + "ord_code" => $code, + "set_pck_at" => $req->pickup_at, + "stts_pck" => OrdersPickups::STTS_WAIT, + "pck_id" => $pck[0]->id, + "pck_name" => $pck[0]->name, + "pck_desc" => $pck[0]->desc, + "pck_type" => $pck[0]->type, + "pck_workflow" => $pck[0]->workflow_type, + "pck_shiptocode" => $pck[0]->shiptocode, + "pck_prid" => $pck[0]->prid, + "pck_ktid" => $pck[0]->ktid, + "pck_kcid" => $pck[0]->kcid, + "pck_klid" => $pck[0]->klid, + "pck_addr" => $pck[0]->fulladdress, + "pck_cgroup_id" => $pck[0]->client_group_id, + "pck_cdiv_id" => $pck[0]->client_div_id, + "pck_cgp_id" => $pck[0]->client_gp_id, + "pck_hex_color" => $pck[0]->boundary_hex_color, + "pck_shape" => $pck[0]->boundary_type, + "pck_radius" => $pck[0]->boundary_radius, + "pck_bounds" => $pck[0]->boundary_bounds, + "pck_latlngs" => $pck[0]->boundary_latlngs, + "pck_points" => $pck[0]->boundary_points, + // 'pic_name' => $pck_pic[0]->pic_name, + // 'pic_phone_code' => $pck_pic[0]->pic_phone_code, + // 'pic_phone_val' => $pck_pic[0]->pic_phone, + // 'pic_mail' => $pck_pic[0]->pic_mail, + "pic_name" => $req->auth->first_name, + "pic_phone_code" => $req->auth->phone_code, + "pic_phone_val" => $req->auth->phone, + "pic_mail" => $req->auth->email, + ]; + + $pck_id = OrdersPickups::add($insPck); + + // if ($drop[0]->boundary_bounds) { + // // $drop[0]->boundary_bounds = json_encode($drop[0]->boundary_bounds); + // } + // if ($drop[0]->boundary_latlngs) { + // // $drop[0]->boundary_latlngs = json_encode($drop[0]->boundary_latlngs); + // } + + $insDrop = [ + "ord_id" => $ord_id, + "ord_code" => $code, + "stts_drop" => OrdersDrops::STTS_WAIT, + "drop_id" => $drop[0]->id, + "drop_name" => $drop[0]->name, + "drop_desc" => $drop[0]->desc, + "drop_type" => $drop[0]->type, + "drop_workflow" => $drop[0]->workflow_type, + "drop_shiptocode" => $drop[0]->shiptocode, + "drop_prid" => $drop[0]->prid, + "drop_ktid" => $drop[0]->ktid, + "drop_kcid" => $drop[0]->kcid, + "drop_klid" => $drop[0]->klid, + "drop_addr" => $drop[0]->fulladdress, + "drop_cgroup_id" => $drop[0]->client_group_id, + "drop_cdiv_id" => $drop[0]->client_div_id, + "drop_cgp_id" => $drop[0]->client_gp_id, + "drop_hex_color" => $drop[0]->boundary_hex_color, + "drop_shape" => $drop[0]->boundary_type, + "drop_radius" => $drop[0]->boundary_radius, + "drop_bounds" => $drop[0]->boundary_bounds, + "drop_latlngs" => $drop[0]->boundary_latlngs, + "drop_points" => $drop[0]->boundary_points, + // 'pic_name' => $drop_pic[0]->pic_name, + // 'pic_phone_code' => $drop_pic[0]->pic_phone_code, + // 'pic_phone_val' => $drop_pic[0]->pic_phone, + // 'pic_mail' => $drop_pic[0]->pic_mail, + "pic_name" => $req->auth->first_name, + "pic_phone_code" => $req->auth->phone_code, + "pic_phone_val" => $req->auth->phone, + "pic_mail" => $req->auth->email, + ]; + $drop_id = OrdersDrops::add($insDrop); + + $insClient = [ + "ord_id" => $ord_id, + "ord_code" => $code, + "c_id" => $req->auth->uid, + "c_name" => $req->auth->first_name, + "c_phone_code" => $req->auth->phone_code, + "c_phone_val" => $req->auth->phone, + "c_mail" => $req->auth->email, + "c_addr" => $req->auth->fulladdress, + "c_disc_type" => $client[0]->disc_type, + "c_disc_amount" => $client[0]->disc_amount, + "c_pt_id" => $client[0]->id, + "c_pt_div_id" => $req->auth->client_div_id, + "c_pt_gp_id" => $req->auth->client_gp_id, + "c_pt_name" => $client[0]->c_name, + "c_pt_phone_code" => $client[0]->c_phone_code, + "c_pt_phone_val" => $client[0]->c_phone, + "c_pt_mail" => $client[0]->c_mail, + "c_pt_addr" => $client[0]->c_addr_office, + "c_pt_pic_name" => $client[0]->pic_name, + "c_pt_pic_phone_code" => $client[0]->pic_phone_code, + "c_pt_pic_phone_val" => $client[0]->pic_phone, + "c_pt_pic_mail" => $client[0]->pic_mail, + "c_pt_pic_addr" => null, + "prefer_truck_type" => $req->truck_type_id, + ]; + $ord_client_id = OrdersClients::add($insClient); + + $insRate = [ + "ord_id" => $ord_id, + "ord_code" => $code, + "rate_id" => $rate[0]->id, + "rate_code" => $rate[0]->code, + "origin_prov" => $rate[0]->origin_prov, + "origin_city" => $rate[0]->origin_city, + "origin_district" => $rate[0]->origin_district, + "origin_village" => $rate[0]->origin_village, + "lane" => $rate[0]->lane, + "dest_prov" => $rate[0]->dest_prov, + "dest_city" => $rate[0]->dest_city, + "dest_district" => $rate[0]->dest_district, + "dest_village" => $rate[0]->dest_village, + "fast_time" => $rate[0]->fast_time, + "long_time" => $rate[0]->long_time, + "unit_time" => $rate[0]->unit_time, + "sell_kg" => $rate[0]->sell_kg, + "buy_kg" => $rate[0]->buy_kg, + "margin_kg" => $rate[0]->margin_kg, + "percent_kg" => $rate[0]->percent_kg, + "sell_cbm" => $rate[0]->sell_cbm, + "buy_cbm" => $rate[0]->buy_cbm, + "margin_cbm" => $rate[0]->margin_cbm, + "percent_cbm" => $rate[0]->percent_cbm, + "sell_ftl" => $rate[0]->sell_ftl, + "buy_ftl" => $rate[0]->buy_ftl, + "margin_ftl" => $rate[0]->margin_ftl, + "percent_ftl" => $rate[0]->percent_ftl, + "vdr_id" => $rate[0]->vdr_id, + "vhc_type" => $rate[0]->vhc_type, + ]; + OrdersRates::add($insRate); + + if (count($insurance) > 0) { + $insInsurance = [ + "ord_id" => $ord_id, + "ord_code" => $code, + "insurance_id" => $insurance[0]->id, + "premi_name" => $insurance[0]->premi_name, + "premi_price" => $insurance[0]->premi_price, + "premi_min_price" => $insurance[0]->premi_min_price, + "premi_max_price" => $insurance[0]->premi_max_price, + "desc" => $insurance[0]->desc, + ]; + OrdersInsurances::add($insInsurance); + } + + // JIKA PAKAI DANA + // $url = env("API_URL_NODE") . "/order/create"; + // $guzReq = new GuzzleClient(); + // $respNode = $guzReq->request("POST", $url, [ + // "headers" => [ + // "Host" => $_SERVER["SERVER_ADDR"], + // "User-Agent" => "curl/7.65.3", + // "Accept" => "*/*", + // "Accept-Encoding" => "gzip, deflate, br", + // // 'Content-Type' => 'application/x-www-form-urlencoded; charset=UTF-8', + // // 'Connection' => 'keep-alive', + // ], + // "json" => [ + // "trx_code" => $code, + // "trx_at" => $now, + // "client_id" => $req->auth->uid, + // "client_name" => $req->auth->first_name, + // "client_phone" => + // $req->auth->phone_code . + // " " . + // implode(" ", str_split($req->auth->phone, 4)), + // "client_mail" => $req->auth->email, + // "client_addr" => "", + // "client_prefer_type_truck" => $type_truck_name, + // "pickup_zone_title" => $pck[0]->name, + // "pickup_zone_addr" => $pck[0]->fulladdress, + // "pickup_at" => $req->pickup_at, + // "drop_zone_title" => $drop[0]->name, + // "drop_zone_addr" => $drop[0]->fulladdress, + // "admins" => $admins_data, + // ], + // ]); + // if ($respNode->getStatusCode() != 200) { + // DB::rollBack(); + // $apiResp = Responses::bad_request("fail create order 0"); + // return new Response($apiResp, $apiResp["meta"]["code"]); + // } + // $body = json_decode($respNode->getBody()->getContents()); + + $apiResp = Responses::created("success create order"); + + DB::commit(); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_list_orders(Request $req) + { + try { + $now = time(); + $input = []; + $rulesInput = []; + + // validasi input + // $isValidInput = Validator::make($input, $rulesInput); + // if (!$isValidInput->passes()) { + // $apiResp = Responses::bad_input($isValidInput->messages()->first()); + // return new Response($apiResp, $apiResp['meta']['code']); + // } + + $filter = [ + "group_by" => "ord_id", + ]; + + if ($req->auth->role == Users::ROLE_ADMIN) { + } elseif ($req->auth->role == Users::ROLE_CLIENT_ADMIN) { + $filter["client_id"] = $req->auth->uid; + } elseif ($req->auth->role == Users::ROLE_VENDOR) { + $filter["vendor_id"] = $req->auth->uid; + } elseif ($req->auth->role == Users::ROLE_CHECKER) { + $filter["get_stts_checker"] = 1; + $filter["chk_id"] = $req->auth->uid; + $filter["chk_type"] = $req->auth->chk_type; + $filter["ready_checker"] = 1; + } else { + $filter["client_id"] = 0; + } + + if ($req->cptid) { + $filter["client_pt_id"] = $req->cptid; + } + if ($req->couple_pck_drop) { + $filter["couple_pck_drop"] = 1; + } + if ($req->order_by === "desc") { + $filter["order_by"] = "ord.id DESC"; + } + + $list = Orders::listOrders($filter); + $newList = []; + $cntK = 0; + foreach ($list as $key => $row) { + $list[$key]->action = "-"; + if ($req->auth->role == Users::ROLE_CHECKER) { + } else { + $isSame = 0; + foreach ($newList as $nlK => $rowL) { + if (!$row->group_code) { + continue; + } + if ($row->group_code === $rowL->group_code) { + $isSame = 1; + $newList[$nlK]->childs[] = clone $list[$key]; + } + } + if ($isSame) { + continue; + } + } + $list[$key]->DT_RowIndex = ++$cntK; + $list[$key]->childs = []; + $newList[] = clone $list[$key]; + } + + $apiResp = Responses::success("success list orders"); + $apiResp["count"] = count($newList); + $apiResp["data"] = $newList; + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_show_order(Request $req, $ord_id) + { + try { + $now = time(); + + $input = [ + "ord_id" => $ord_id, + "get_current_track_vhcs" => $req->get_current_track_vhcs, + "couple_pck_drop" => $req->couple_pck_drop, + ]; + $rulesInput = [ + "ord_id" => "required|integer|not_in:0", + "get_current_track_vhcs" => "nullable|numeric", + "couple_pck_drop" => "nullable|numeric", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $filter = [ + "id" => $ord_id, + ]; + if ($req->couple_pck_drop) { + $filter["couple_pck_drop"] = 1; + } + $order = Orders::showOrder($filter); + if (count($order) < 1) { + $apiResp = Responses::not_found("order not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $apiResp = Responses::success("success detail order"); + $apiResp["data"] = $order[0]; + + if ($req->get_current_track_vhcs) { + // $rate = ConfRates::getRateById($order[0]->rate_id); + $rate = OrdersRates::getById($order[0]->ord_rate_id); + $filter = [ + "status" => Vehicles::STTS_ACTIVE, + "is_in_ord" => Vehicles::IN_ORD_NO, + "active_rates" => $rate[0], + ]; + if ($order[0]->prefer_truck_type != 0) { + $filter["prefer_truck_type"] = $order[0]->prefer_truck_type; + } + $list_current_track_vhcs = Tracks::listCurrentTracks($filter); + $apiResp["list_current_track_vhcs"] = $list_current_track_vhcs; + } + + if ($req->drv_ups) { + $apiResp["drvs_ups"] = OrdersDriversUploads::list([ + "ord_id" => $order[0]->ord_id, + "pck_id" => $order[0]->ord_pck_id, + "drop_id" => $order[0]->ord_drop_id, + "ord_pck_drop_id" => $order[0]->ord_pck_drop_id, + ]); + } + + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_download_package_list(Request $req, $ord_id) + { + try { + $now = time(); + $input = [ + "ord_id" => $ord_id, + ]; + $rulesInput = [ + "ord_id" => "required|integer|not_in:0", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $filter = []; + // if ($req->auth->role != Users::ROLE_CHECKER) { + $filter["get_not_deleted"] = 1; + // } + + $items = OrdersItems::getsByOrdId($ord_id, $filter); + if (count($items) < 1) { + $apiResp = Responses::not_found("order not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $apiResp = Responses::success("success get package list"); + $apiResp["data"] = $items; + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_adm_find_driver(Request $req) + { + try { + $now = time(); + $input = [ + "ord_id" => $req->ord_id, + "boundary_type" => $req->boundary_type, + "boundary_latlngs" => $req->boundary_latlngs, + "boundary_bounds" => $req->boundary_bounds, + "boundary_radius" => $req->boundary_radius, + ]; + $rulesInput = [ + "ord_id" => "required|integer|not_in:0", + "boundary_type" => "required|string|max:25", + "boundary_latlngs" => "required|array", + "boundary_latlngs.*.lat" => "required", + "boundary_latlngs.*.lng" => "required", + "boundary_bounds" => "nullable|array", + "boundary_radius" => "nullable|numeric", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $filter = [ + "id" => $req->ord_id, + "get_prefer_type_truck" => 1, + ]; + $order = Orders::showOrder($filter); + if (count($order) < 1) { + $apiResp = Responses::not_found("order not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + $apiResp = Responses::success("success get order"); + $apiResp["data"] = $order[0]; + + // $rate = ConfRates::getRateById($order[0]->rate_id); + $rate = OrdersRates::getById($order[0]->ord_rate_id); + $filter = [ + "active_rates" => $rate[0], + ]; + if ($order[0]->prefer_truck_type != 0) { + $filter["prefer_truck_type"] = $order[0]->prefer_truck_type; + } + + $lat = $req->boundary_latlngs[0]["lat"]; + $lng = $req->boundary_latlngs[0]["lng"]; + $nearest = Tracks::nearestInCircle($lat, $lng, $req->boundary_radius, $filter); + if (count($nearest) < 1) { + $apiResp = Responses::not_found("no vehicle available"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $found_prefer = 0; + $group_vendors = []; + foreach ($nearest as $k => $v) { + $is_add_vendor = 1; + if ($order[0]->prefer_truck_type !== 0) { + if ($v->type_id === $order[0]->prefer_truck_type) { + $found_prefer = 1; + } else { + // remove from array but no reindex array + // unset($nearest[$k]); + // remove from array and reindex array + array_splice($nearest, $k, 1); + $is_add_vendor = 0; + } + } + if ($is_add_vendor) { + if (!isset($group_vendors[(int) $v->vendor_id])) { + // $token = Str::uuid()->toString(); + $token = (new Nanoid())->generateId(36); + $group_vendors[(int) $v->vendor_id] = [ + "vendor_id" => $v->vendor_id, + "vendor_name" => $v->vendor_name, + "vendor_phone" => + $v->vendor_phone . " " . implode(" ", str_split($v->vendor_phone, 4)), + "vendor_phone_code" => $v->vendor_phone_code, + "vendor_phone_val" => $v->vendor_phone, + "vendor_mail" => $v->vendor_mail, + "vendor_addr" => $v->vendor_addr, + "vendor_bank_id" => $v->bank_id, + "vendor_bank_code" => $v->bank_code, + "vendor_bank_short_name" => $v->bank_short_name, + "vendor_bank_name" => $v->bank_name, + "vendor_bank_acc_number" => $v->bank_acc_number, + "vendor_bank_acc_name" => $v->bank_acc_name, + "vendor_acc_link" => + route("view_user_vendor_transaction_bid_order") . "?token=" . $token, + "vhcs" => $v->id . ",", // string vhc_ids per vendor separated by comma + "token" => $token, + "distance" => $v->distance, + ]; + } else { + $group_vendors[(int) $v->vendor_id]["vhcs"] .= $v->id . ","; + } + } + } + $apiResp["nearest"] = $nearest; + + if ($order[0]->prefer_truck_type != 0) { + if ($found_prefer === 0) { + // $tt = ConfTruckTypes::getTypeById($order[0]->prefer_truck_type); + $apiResp = Responses::not_found( + "no vehicle available with prefered type truck " . $order[0]->prefer_truck_type_name, + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + // return (new Response($apiResp, 400)); + + DB::beginTransaction(); + + Orders::updateOrder($order[0]->ord_id, [ + "confirm_at" => $now, + "confirm_by" => $req->auth->id, + "find_vhc_at" => $now, + "find_vhc_by" => $req->auth->id, + "status" => Orders::STTS_CONFIRM, + "updt" => $now, + "updt_by" => $req->auth->id, + ]); + + $vendors = []; + $ik = 0; + foreach ($group_vendors as $k => $v) { + $checkIsIns = OrdersVendors::getByOrdIdAndVdrId($order[0]->ord_id, $v["vendor_id"]); + if (count($checkIsIns) > 0) { + continue; + } + $vendor = [ + "vendor_id" => $v["vendor_id"], + "vendor_name" => $v["vendor_name"], + "vendor_phone" => $v["vendor_phone"], + "vendor_mail" => $v["vendor_mail"], + "vendor_addr" => $v["vendor_addr"], + "vendor_acc_link" => $v["vendor_acc_link"], + ]; + array_push($vendors, $vendor); + + if (strpos($v["vhcs"], ",") !== false) { + $v["vhcs"] = substr($v["vhcs"], 0, -1); + } + + // $is_mailing_bid = OrdersVendors::IS_MAILING_BID_NOT; + // $is_mailing_bid_at = 0; + // $exp_at = 0; + // $is_exp = OrdersVendors::LINK_NOT_EXP; + // if ($ik === 0) { + $is_mailing_bid = OrdersVendors::IS_MAILING_BID_SEND; + $is_mailing_bid_at = $now; + $exp_at = strtotime("+10 minutes", $now); + // $exp_at = strtotime('+1 day', $now); + $is_exp = OrdersVendors::LINK_WILL_EXP; + // } + + $insVendors = [ + "ord_id" => $order[0]->ord_id, + "ord_code" => $order[0]->ord_code, + "vdr_id" => $v["vendor_id"], + "vdr_name" => $v["vendor_name"], + "vdr_mail" => $v["vendor_mail"], + "vdr_phone_code" => $v["vendor_phone_code"], + "vdr_phone_val" => $v["vendor_phone_val"], + "vdr_addr" => $v["vendor_addr"], + "vdr_bank_id" => $v["vendor_bank_id"], + "vdr_bank_code" => $v["vendor_bank_code"], + "vdr_bank_short_name" => $v["vendor_bank_short_name"], + "vdr_bank_name" => $v["vendor_bank_name"], + "vdr_bank_acc_number" => $v["vendor_bank_acc_number"], + "vdr_bank_acc_name" => $v["vendor_bank_acc_name"], + "find_vhcs" => $v["vhcs"], + "find_radius" => $req->boundary_radius, + "find_shape" => Zone::ZONE_BOUNDARY_CIRCLE, + "find_center_lat" => $req->boundary_latlngs[0]["lat"], + "find_center_lng" => $req->boundary_latlngs[0]["lng"], + "distance" => $v["distance"], + "is_exp" => $is_exp, + "exp_at" => $exp_at, + "bid_token" => $v["token"], + "is_mailing_bid" => $is_mailing_bid, + "is_mailing_bid_at" => $is_mailing_bid_at, + "status" => OrdersVendors::STTS_WAIT, + "crt" => $now, + ]; + OrdersVendors::add($insVendors); + $ik++; + } + + if (count($vendors) > 0) { + // run schedule 3x dalam 10 menit + $url = env("API_URL_NODE") . "/order/delay_blast_order"; + $guzReq = new GuzzleClient(); + $respNode = $guzReq->request("POST", $url, [ + "headers" => [ + "Host" => $_SERVER["SERVER_ADDR"], + "User-Agent" => "curl/7.65.3", + "Accept" => "*/*", + "Accept-Encoding" => "gzip, deflate, br", + // 'Content-Type' => 'application/x-www-form-urlencoded; charset=UTF-8', + // 'Connection' => 'keep-alive', + ], + "json" => [ + "ord_id" => $order[0]->ord_id, + "ord_code" => $order[0]->ord_code, + "base_link" => route("view_user_vendor_transaction_bid_order") . "?token=", + ], + ]); + if ($respNode->getStatusCode() != 200) { + DB::rollBack(); + $apiResp = Responses::bad_request("fail setup scheduler on 10 minutes later"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + // $body = json_decode($respNode->getBody()->getContents()); + + $url = env("API_URL_NODE") . "/order/email_to_vendor"; + $guzReq = new GuzzleClient(); + $respNode = $guzReq->request("POST", $url, [ + "headers" => [ + "Host" => $_SERVER["SERVER_ADDR"], + "User-Agent" => "curl/7.65.3", + "Accept" => "*/*", + "Accept-Encoding" => "gzip, deflate, br", + // 'Content-Type' => 'application/x-www-form-urlencoded; charset=UTF-8', + // 'Connection' => 'keep-alive', + ], + "json" => [ + "trx_code" => $order[0]->ord_code, + "trx_at" => $order[0]->crt, + "client_id" => $order[0]->c_id, + "client_name" => $order[0]->c_name, + "client_phone" => + $order[0]->c_phone_code . + " " . + implode(" ", str_split($order[0]->c_phone_val, 4)), + "client_mail" => $order[0]->c_mail, + "client_addr" => "", + "client_prefer_type_truck" => $order[0]->prefer_truck_type_name ?? "", + // "weight" => $order[0]->weight, + // "cbm" => $order[0]->cbm, + // "koli" => $order[0]->koli, + "pickup_zone_title" => $order[0]->pck_name, + "pickup_zone_addr" => $order[0]->pck_addr, + "pickup_at" => $order[0]->set_pck_at, + "drop_zone_title" => $order[0]->drop_name, + "drop_zone_addr" => $order[0]->drop_addr, + "vendors" => $vendors, + ], + ]); + if ($respNode->getStatusCode() != 200) { + DB::rollBack(); + $apiResp = Responses::bad_request("fail send email to vendor"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + // $body = json_decode($respNode->getBody()->getContents()); + } + + DB::commit(); + $apiResp = Responses::success("success confirm order"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_adm_assign_vendor(Request $req) + { + try { + $now = time(); + $input = [ + "ord_id" => $req->ord_id, + "vendor_id" => $req->vendor_id, + ]; + $rulesInput = [ + "ord_id" => "required|integer|not_in:0", + "vendor_id" => "required|integer|not_in:0", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $filter = [ + "id" => $req->ord_id, + "get_prefer_type_truck" => 1, + ]; + $order = Orders::showOrder($filter); + if (count($order) < 1) { + $apiResp = Responses::not_found("order not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + $apiResp = Responses::success("success get order"); + $apiResp["data"] = $order[0]; + + $vendor = Users::getUserById($req->vendor_id); + if (count($vendor) < 1) { + $apiResp = Responses::not_found("vendor not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $found_prefer = 0; + $group_vendors = []; + + // $token = Str::uuid()->toString(); + $token = (new Nanoid())->generateId(36); + $group_vendors[(int) $vendor[0]->id] = [ + "vendor_id" => $vendor[0]->id, + "vendor_name" => $vendor[0]->first_name, + "vendor_phone" => $vendor[0]->phone . " " . implode(" ", str_split($vendor[0]->phone, 4)), + "vendor_phone_code" => $vendor[0]->phone_code, + "vendor_phone_val" => $vendor[0]->phone, + "vendor_mail" => $vendor[0]->email, + "vendor_addr" => $vendor[0]->fulladdress, + "vendor_bank_id" => $vendor[0]->bank_id, + "vendor_bank_code" => $vendor[0]->bank_code, + "vendor_bank_short_name" => $vendor[0]->bank_short_name, + "vendor_bank_name" => $vendor[0]->bank_name, + "vendor_bank_acc_number" => $vendor[0]->bank_acc_number, + "vendor_bank_acc_name" => $vendor[0]->bank_acc_name, + "vendor_acc_link" => route("view_user_vendor_transaction_bid_order") . "?token=" . $token, + "vhcs" => "", // string vhc_ids per vendor separated by comma + "token" => $token, + ]; + + $vhcs = Vehicles::getVehiclesInVendorIdsActiveNoInOrder( + "" . $vendor[0]->id, + $order[0]->prefer_truck_type, + ); + foreach ($vhcs as $vhc) { + if ($vhc->type_id === $order[0]->prefer_truck_type) { + $found_prefer = 1; + } + $group_vendors[(int) $vendor[0]->id]["vhcs"] .= $vhc->id . ","; + } + + if ($order[0]->prefer_truck_type != 0) { + if ($found_prefer === 0) { + // $tt = ConfTruckTypes::getTypeById($order[0]->prefer_truck_type); + $apiResp = Responses::not_found( + "no vehicle available with prefered type truck " . $order[0]->prefer_truck_type_name, + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + // return (new Response($apiResp, 400)); + + DB::beginTransaction(); + + Orders::updateOrder($order[0]->ord_id, [ + "confirm_at" => $now, + "confirm_by" => $req->auth->id, + "find_vhc_at" => $now, + "find_vhc_by" => $req->auth->id, + "status" => Orders::STTS_CONFIRM, + "updt" => $now, + "updt_by" => $req->auth->id, + ]); + + $vendors = []; + $ik = 0; + foreach ($group_vendors as $k => $v) { + $checkIsIns = OrdersVendors::getByOrdIdAndVdrId($order[0]->ord_id, $v["vendor_id"]); + if (count($checkIsIns) > 0) { + continue; + } + $vendor = [ + "vendor_id" => $v["vendor_id"], + "vendor_name" => $v["vendor_name"], + "vendor_phone" => $v["vendor_phone"], + "vendor_mail" => $v["vendor_mail"], + "vendor_addr" => $v["vendor_addr"], + "vendor_acc_link" => $v["vendor_acc_link"], + ]; + array_push($vendors, $vendor); + + if (strpos($v["vhcs"], ",") !== false) { + $v["vhcs"] = substr($v["vhcs"], 0, -1); + } + + // $is_mailing_bid = OrdersVendors::IS_MAILING_BID_NOT; + // $is_mailing_bid_at = 0; + // $exp_at = 0; + // $is_exp = OrdersVendors::LINK_NOT_EXP; + // if ($ik === 0) { + $is_mailing_bid = OrdersVendors::IS_MAILING_BID_SEND; + $is_mailing_bid_at = $now; + $exp_at = strtotime("+10 minutes", $now); + // $exp_at = strtotime('+1 day', $now); + $is_exp = OrdersVendors::LINK_WILL_EXP; + // } + + $insVendors = [ + "ord_id" => $order[0]->ord_id, + "ord_code" => $order[0]->ord_code, + "vdr_id" => $v["vendor_id"], + "vdr_name" => $v["vendor_name"], + "vdr_mail" => $v["vendor_mail"], + "vdr_phone_code" => $v["vendor_phone_code"], + "vdr_phone_val" => $v["vendor_phone_val"], + "vdr_addr" => $v["vendor_addr"], + "vdr_bank_id" => $v["vendor_bank_id"], + "vdr_bank_code" => $v["vendor_bank_code"], + "vdr_bank_short_name" => $v["vendor_bank_short_name"], + "vdr_bank_name" => $v["vendor_bank_name"], + "vdr_bank_acc_number" => $v["vendor_bank_acc_number"], + "vdr_bank_acc_name" => $v["vendor_bank_acc_name"], + "find_vhcs" => $v["vhcs"], + "is_exp" => $is_exp, + "exp_at" => $exp_at, + "bid_token" => $v["token"], + "is_mailing_bid" => $is_mailing_bid, + "is_mailing_bid_at" => $is_mailing_bid_at, + "status" => OrdersVendors::STTS_WAIT, + "crt" => $now, + ]; + OrdersVendors::add($insVendors); + $ik++; + } + // if (count($vendors) > 0) { + // // run schedule 3x dalam 10 menit + // $url = env("API_URL_NODE") . "/order/delay_blast_order"; + // $guzReq = new GuzzleClient(); + // $respNode = $guzReq->request("POST", $url, [ + // "headers" => [ + // "Host" => $_SERVER["SERVER_ADDR"], + // "User-Agent" => "curl/7.65.3", + // "Accept" => "*/*", + // "Accept-Encoding" => "gzip, deflate, br", + // // 'Content-Type' => 'application/x-www-form-urlencoded; charset=UTF-8', + // // 'Connection' => 'keep-alive', + // ], + // "json" => [ + // "ord_id" => $order[0]->ord_id, + // "ord_code" => $order[0]->ord_code, + // "base_link" => + // route("view_user_vendor_transaction_bid_order") . + // "?token=", + // ], + // ]); + // if ($respNode->getStatusCode() != 200) { + // DB::rollBack(); + // $apiResp = Responses::bad_request( + // "fail setup schedule 3x10 minutes" + // ); + // return new Response($apiResp, $apiResp["meta"]["code"]); + // } + // // $body = json_decode($respNode->getBody()->getContents()); + + // $url = env("API_URL_NODE") . "/order/email_to_vendor"; + // $guzReq = new GuzzleClient(); + // $respNode = $guzReq->request("POST", $url, [ + // "headers" => [ + // "Host" => $_SERVER["SERVER_ADDR"], + // "User-Agent" => "curl/7.65.3", + // "Accept" => "*/*", + // "Accept-Encoding" => "gzip, deflate, br", + // // 'Content-Type' => 'application/x-www-form-urlencoded; charset=UTF-8', + // // 'Connection' => 'keep-alive', + // ], + // "json" => [ + // "trx_code" => $order[0]->ord_code, + // "trx_at" => $order[0]->crt, + // "client_id" => $order[0]->c_id, + // "client_name" => $order[0]->c_name, + // "client_phone" => + // $order[0]->c_phone_code . + // " " . + // implode(" ", str_split($order[0]->c_phone_val, 4)), + // "client_mail" => $order[0]->c_mail, + // "client_addr" => "", + // "client_prefer_type_truck" => + // $order[0]->prefer_truck_type_name ?? "", + // // "weight" => $order[0]->weight, + // // "cbm" => $order[0]->cbm, + // // "koli" => $order[0]->koli, + // "pickup_zone_title" => $order[0]->pck_name, + // "pickup_zone_addr" => $order[0]->pck_addr, + // "pickup_at" => $order[0]->set_pck_at, + // "drop_zone_title" => $order[0]->drop_name, + // "drop_zone_addr" => $order[0]->drop_addr, + // "vendors" => $vendors, + // ], + // ]); + // if ($respNode->getStatusCode() != 200) { + // DB::rollBack(); + // $apiResp = Responses::bad_request( + // "fail send email to vendor" + // ); + // return new Response($apiResp, $apiResp["meta"]["code"]); + // } + // // $body = json_decode($respNode->getBody()->getContents()); + // } + + DB::commit(); + $apiResp = Responses::success("success confirm order"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_want_this_order_v1(Request $req) + { + try { + $now = time(); + $input = [ + "ord_id" => $req->ord_id, + ]; + $rulesInput = [ + "ord_id" => "required|integer|not_in:0", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $order = Orders::showOrder([ + "id" => $req->ord_id, + "get_exp_vendor" => 1, + "vdr_id" => $req->auth->uid, + ]); + if (count($order) < 1) { + $apiResp = Responses::not_found("order not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + // if ($order[0]->vdr_is_exp === OrdersVendors::LINK_WILL_EXP) { + // if ($order[0]->vdr_exp_at < time()) { + // $apiResp = Responses::bad_request("link expired"); + // return new Response($apiResp, $apiResp["meta"]["code"]); + // } + // } + + // validate if another vendor want this order + $otherVendorsWantThisOrder = OrdersVendors::getOtherVendorsWantThisOrder( + $order[0]->ord_id, + $req->auth->uid, + ); + if (count($otherVendorsWantThisOrder) > 0) { + $apiResp = Responses::bad_request( + "There other vendor want this order, if next 10 minutes the vendor not take the order, we will send email again to you", + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + // $sendToNode = [ + // "ord_id" => $order[0]->ord_id, + // "ord_code" => $order[0]->ord_code, + // "current_ord_vdr_id" => $order[0]->ord_vdr_id, + // "next_ord_vdr_id" => [], + // "next_vdr_bid_token" => [], + // "next_vdr_acc_link" => [], + // ]; + + // $nextVendors = OrdersVendors::getNextVendors($order[0]->ord_id, $req->auth->uid); + // foreach ($nextVendors as $k => $v) { + // $sendToNode['next_ord_vdr_id'][] = ['id' => $v->id]; + // $sendToNode['next_vdr_bid_token'][] = ['tkn' => $v->bid_token]; + // $sendToNode['next_vdr_acc_link'][] = ['link' => route('view_user_vendor_transaction_bid_order') . '?token=' . $v->bid_token]; + // } + + DB::beginTransaction(); + + OrdersVendors::updt($order[0]->ord_vdr_id, [ + "is_want" => OrdersVendors::IS_WANT_YES, + "is_want_at" => $now, + "is_exp" => OrdersVendors::LINK_WILL_EXP, + // 'exp_at' => strtotime('+10 minutes', $now), + ]); + + // gaperlu dihit karena sekarang sudah pakai konsep run schedule 3x dalam 10 menit + // $url = env('API_URL_NODE') . '/order/delay_blast_order'; + // $guzReq = new GuzzleClient(); + // $respNode = $guzReq->request('POST', $url, [ + // 'headers' => [ + // 'Host' => $_SERVER['SERVER_ADDR'], + // 'User-Agent' => 'curl/7.65.3', + // 'Accept' => '*/*', + // 'Accept-Encoding' => 'gzip, deflate, br', + // // 'Content-Type' => 'application/x-www-form-urlencoded; charset=UTF-8', + // // 'Connection' => 'keep-alive', + // ], + // 'json' => $sendToNode, + // ]); + // if ($respNode->getStatusCode() != 200) { + // DB::rollBack(); + // $apiResp = Responses::bad_request('fail setup scheduler on 10 minutes later'); + // return (new Response($apiResp, $apiResp['meta']['code'])); + // } + // $body = json_decode($respNode->getBody()->getContents()); + + DB::commit(); + $apiResp = Responses::success("success want this order"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_accept_order_v1(Request $req) + { + try { + $now = time(); + $input = [ + "ord_id" => $req->ord_id, + "vehicle" => $req->vehicle, // id + "driver" => $req->driver, // id + ]; + $rulesInput = [ + "ord_id" => "required|integer|not_in:0", + "vehicle" => "required|integer|not_in:0", + "driver" => "required|integer|not_in:0", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $order = Orders::showOrder([ + "id" => $req->ord_id, + "get_exp_vendor" => 1, + "vdr_id" => $req->auth->uid, + ]); + if (count($order) < 1) { + $apiResp = Responses::not_found("order not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + if ($order[0]->vdr_status !== OrdersVendors::STTS_WAIT) { + // $apiResp = Responses::bad_request('you had respond this order'); + $apiResp = Responses::bad_request("order has been cancel"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + if ($order[0]->status === Orders::STTS_WAIT || $order[0]->status === Orders::STTS_CONFIRM) { + } else { + $apiResp = Responses::bad_request("this order have beend accepted by another vendor"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + // date('Y-m-d H:i:s', $order[0]->vdr_exp_at); + // comment by meus + // if ($order[0]->vdr_is_exp === OrdersVendors::LINK_WILL_EXP) { + // if ($order[0]->vdr_exp_at < time()) { + // $apiResp = Responses::bad_request("link expired"); + // return new Response($apiResp, $apiResp["meta"]["code"]); + // } + // } + $haveBeenAcc = OrdersVendors::getByOrdIdByStatus($req->ord_id, OrdersVendors::STTS_ACC); + if (count($haveBeenAcc) > 0) { + $apiResp = Responses::bad_request("this order have beend accepted by another vendor"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $driver = Drivers::getDriverByIdAllData($req->driver); + if (count($driver) < 1) { + $apiResp = Responses::not_found("driver not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + if ($driver[0]->is_in_ord === Drivers::IN_ORD_YES) { + $apiResp = Responses::not_found("driver telah ditugaskan untuk order lain"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $vehicle = Vehicles::getVehicleByIdAllData($req->vehicle); + if (count($vehicle) < 1) { + $apiResp = Responses::not_found("vehicle not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + if ($vehicle[0]->is_in_ord === Vehicles::IN_ORD_YES) { + $apiResp = Responses::not_found("vehicle telah ditugaskan untuk order lain"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + // $apiResp = Responses::success('success accept order'); + // return (new Response($apiResp, $apiResp['meta']['code'])); + + DB::beginTransaction(); + + Orders::updateOrder($order[0]->ord_id, [ + "status" => Orders::STTS_HAVE_GET_VHC, + ]); + Vehicles::updateVehicle($req->vehicle, [ + "is_in_ord" => Vehicles::IN_ORD_YES, + "ord_id" => $order[0]->ord_id, + "ord_code" => $order[0]->ord_code, + ]); + Drivers::updateDriver($order[0]->drv_id, [ + "is_in_ord" => Drivers::IN_ORD_YES, + "ord_id" => $order[0]->ord_id, + "ord_code" => $order[0]->ord_code, + ]); + OrdersVendors::updt($order[0]->ord_vdr_id, [ + "respond_at" => $now, + "status" => OrdersVendors::STTS_ACC, + ]); + OrdersDrivers::add([ + "ord_id" => $order[0]->ord_id, + "ord_code" => $order[0]->ord_code, + "vdr_id" => $driver[0]->vendor_id, + "drv_id" => $driver[0]->drv_id, + "drv_name" => $driver[0]->fullname, + "drv_mail" => $driver[0]->email, + "drv_name2" => $driver[0]->fullname2, + "drv_phone_code" => $driver[0]->phone_code, + "drv_phone_val" => $driver[0]->phone, + "drv_phone2_code" => $driver[0]->phone2_code, + "drv_phone2_val" => $driver[0]->phone2, + "drv_addr" => $driver[0]->fulladdress, + "drv_cgroup_id" => $driver[0]->client_group_id, + "drv_nik" => $driver[0]->nik, + "drv_dob" => $driver[0]->dob, + "drv_age" => Helper::countAge($driver[0]->dob), + "drv_gender" => $driver[0]->gender, + "drv_blood" => $driver[0]->blood, + "em_fullname" => $driver[0]->em_fullname, + "em_phone_code" => $driver[0]->em_phone_code, + "em_phone_val" => $driver[0]->em_phone, + "em_relationship" => $driver[0]->em_relationship, + "drv_ktp_img" => $driver[0]->ktp_img, + "drv_npwp_img" => $driver[0]->npwp_img, + "drv_npwp_number" => $driver[0]->npwp_number, + "drv_npwp_string" => $driver[0]->npwp_string, + "drv_license_img" => $driver[0]->license_img, + "drv_license_number" => $driver[0]->license_number, + "drv_license_exp" => $driver[0]->license_exp, + ]); + OrdersVehicles::add([ + "ord_id" => $order[0]->ord_id, + "ord_code" => $order[0]->ord_code, + "vhc_id" => $vehicle[0]->vhc_id, + "vhc_name" => $vehicle[0]->name, + "vhc_device_id" => $vehicle[0]->device_id, + "vhc_cat_id" => $vehicle[0]->cat_id, + "vhc_brand_id" => $vehicle[0]->brand_id, + "vhc_type_id" => $vehicle[0]->type_id, + "vhc_model_id" => $vehicle[0]->model_id, + "vhc_c_did" => $vehicle[0]->c_did, + "vhc_a_did" => $vehicle[0]->a_did, + "vhc_nopol1" => $vehicle[0]->nopol1, + "vhc_nopol2" => $vehicle[0]->nopol2, + "vhc_nopol3" => $vehicle[0]->nopol3, + "vhc_is_track_holiday" => $vehicle[0]->is_track_holiday, + "vhc_track_sch_d" => $vehicle[0]->track_sch_d, + "vhc_track_sch_h" => $vehicle[0]->track_sch_h, + "vhc_cgroup_id" => $vehicle[0]->client_group_id, + "vhc_vdr_id" => $vehicle[0]->vendor_id, + "vhc_speed_limit" => $vehicle[0]->speed_limit, + "vhc_fuel_capacity" => $vehicle[0]->fuel_capacity, + "vhc_fuel_drop_treshold" => $vehicle[0]->fuel_drop_treshold, + "vhc_max_pressure" => $vehicle[0]->max_pressure, + "vhc_fvhc_img" => $vehicle[0]->fvhc_img, + "vhc_stnk_img" => $vehicle[0]->stnk_img, + "vhc_stnk_exp" => $vehicle[0]->stnk_exp, + "vhc_vyear" => $vehicle[0]->vyear, + "vhc_cc" => $vehicle[0]->cc, + "vhc_vin" => $vehicle[0]->vin, + "vhc_en" => $vehicle[0]->en, + "vhc_vcolor" => $vehicle[0]->vcolor, + "vhc_fuel_type" => $vehicle[0]->fuel_type, + "vhc_tnkb_color" => $vehicle[0]->tnkb_color, + "vhc_regis_year" => $vehicle[0]->regis_year, + "vhc_tax_exp" => $vehicle[0]->tax_exp, + ]); + + // $url = env("API_URL_NODE") . "/order/email_vendor_acc_order"; + // $guzReq = new GuzzleClient(); + // $respNode = $guzReq->request("POST", $url, [ + // "headers" => [ + // "Host" => $_SERVER["SERVER_ADDR"], + // "User-Agent" => "curl/7.65.3", + // "Accept" => "*/*", + // "Accept-Encoding" => "gzip, deflate, br", + // // 'Content-Type' => 'application/x-www-form-urlencoded; charset=UTF-8', + // // 'Connection' => 'keep-alive', + // ], + // "json" => [ + // "trx_code" => $order[0]->ord_code, + // "trx_at" => $order[0]->crt, + // "client_id" => $order[0]->c_id, + // "client_name" => $order[0]->c_name, + // "client_phone" => + // $order[0]->c_phone_code . + // " " . + // implode(" ", str_split($order[0]->c_phone_val, 4)), + // "client_mail" => $order[0]->c_mail, + // "client_addr" => "", + // "client_prefer_type_truck" => + // $order[0]->prefer_truck_type_name ?? "", + // "weight" => $order[0]->weight, + // "cbm" => $order[0]->cbm, + // "koli" => $order[0]->koli, + // "pickup_zone_title" => $order[0]->pck_name, + // "pickup_zone_addr" => $order[0]->pck_addr, + // "pickup_at" => $order[0]->set_pck_at, + // "drop_zone_title" => $order[0]->drop_name, + // "drop_zone_addr" => $order[0]->drop_addr, + // "vendors" => [ + // [ + // "vendor_id" => $order[0]->vdr_id, + // "vendor_name" => $order[0]->vdr_name, + // "vendor_phone" => + // $order[0]->vdr_phone_code . + // " " . + // implode( + // " ", + // str_split($order[0]->vdr_phone_val, 4) + // ), + // "vendor_mail" => $order[0]->vdr_mail, + // // "vendor_addr" => $order[0]->vdr_addr, + // "vendor_acc_at" => $now, + // ], + // ], + // "drivers" => [ + // [ + // "driver_id" => $driver[0]->id, + // "driver_name" => $driver[0]->fullname, + // "driver_phone" => + // $driver[0]->phone_code . + // " " . + // implode(" ", str_split($driver[0]->phone, 4)), + // "driver_mail" => $driver[0]->email, + // // "driver_addr" => $driver[0]->fulladdress, + // ], + // ], + // ], + // ]); + // if ($respNode->getStatusCode() != 200) { + // DB::rollBack(); + // $apiResp = Responses::bad_request("fail send email to vendor"); + // return new Response($apiResp, $apiResp["meta"]["code"]); + // } + // $body = json_decode($respNode->getBody()->getContents()); + + DB::commit(); + $apiResp = Responses::success("success accept order"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_checker_submit_items(Request $req) + { + try { + $now = time(); + $input = [ + "ord_id" => $req->ord_id, + "type_check" => $req->type_check, + "weight" => $req->weight, + "cbm" => $req->cbm, + // 'qty_total' => $req->qty_total, + "koli" => $req->koli, + "general_base64" => $req->general_base64, + "goods_base64" => $req->goods_base64, + "items" => $req->items, + ]; + $rulesInput = [ + "ord_id" => "required|integer|not_in:0", + "type_check" => "required|integer|not_in:0", + "weight" => "required|numeric", + "cbm" => "required|numeric", + // 'qty_total' => 'required|integer|not_in:0', + "koli" => "required|integer|not_in:0", + "items" => "required|array", + "items.*.id" => "required|numeric", + "items.*.item_code" => "required|string|max:255", + "items.*.desc" => "required|string", + // 'items.*.qty' => 'required|numeric', + "items.*.weight" => "required|numeric", // kg + "items.*.length" => "required|numeric", // m + "items.*.wide" => "required|numeric", // m + "items.*.height" => "required|numeric", // m + "items.*.cbm" => "required|numeric", // m + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + if (count($req->items) < 1) { + $apiResp = Responses::bad_input("at least 1 item left remaining"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $url_general = null; + $url_goods = null; + $calc_weight = $req->weight; // total + $calc_cbm = $req->cbm; // total + $calc_qty = $req->qty_total ?? 0; // total + $calc_koli = $req->koli; // total + + $order = Orders::showOrder([ + "id" => $req->ord_id, + "get_stts_checker" => 1, + // 'chk_id' => $req->auth->uid, + ]); + if (count($order) < 1) { + $apiResp = Responses::not_found("order not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + if ($req->type_check == Users::CHK_TYPE_PICKUP) { + // case jika vehicle harus sedang ditempat + // if ($order[0]->status === Orders::STTS_HAVE_GET_VHC || $order[0]->status === Orders::STTS_PCK || $order[0]->status === Orders::STTS_GO) { + // } else { + // $apiResp = Responses::bad_input('vehicle not in pickup zone'); + // return (new Response($apiResp, $apiResp['meta']['code'])); + // } + // case jika checker bisa submit kapan saja + if ($order[0]->status === Orders::STTS_WAIT || $order[0]->status === Orders::STTS_CONFIRM) { + $apiResp = Responses::bad_input("vehicle not in pickup zone"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } elseif ($req->type_check == Users::CHK_TYPE_DROP) { + // case jika vehicle harus sedang ditempat + // if ($order[0]->status === Orders::STTS_GO || $order[0]->status === Orders::STTS_ARV || $order[0]->status === Orders::STTS_DROP || $order[0]->status === Orders::STTS_CLIENT_PAY) { + // } else { + // $apiResp = Responses::bad_input('vehicle not in drop zone'); + // return (new Response($apiResp, $apiResp['meta']['code'])); + // } + // case jika checker bisa submit kapan saja + if ( + $order[0]->status === Orders::STTS_WAIT || + $order[0]->status === Orders::STTS_CONFIRM || + $order[0]->status === Orders::STTS_PCK + ) { + $apiResp = Responses::bad_input("vehicle not in drop zone"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } else { + $apiResp = Responses::bad_input("location type not valid"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + if ($req->general_base64 != "") { + if ($req->type_check == Users::CHK_TYPE_PICKUP) { + $url_general = + "orders/" . + $order[0]->ord_id . + "/pickups/" . + $order[0]->ord_pck_id . + "/checkers/" . + $req->auth->uid . + "/general_$now.jpeg"; + } elseif ($req->type_check == Users::CHK_TYPE_DROP) { + $url_general = + "orders/" . + $order[0]->ord_id . + "/drops/" . + $order[0]->ord_drop_id . + "/checkers/" . + $req->auth->uid . + "/general_$now.jpeg"; + } + if (!Storage::disk("public")->put($url_general, base64_decode($req->general_base64))) { + $apiResp = Responses::bad_request("fail upload image delivery order"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + if ($req->goods_base64 != "") { + if ($req->type_check == Users::CHK_TYPE_PICKUP) { + $url_goods = + "orders/" . + $order[0]->ord_id . + "/pickups/" . + $order[0]->ord_pck_id . + "/checkers/" . + $req->auth->uid . + "/goods_$now.jpeg"; + } elseif ($req->type_check == Users::CHK_TYPE_DROP) { + $url_goods = + "orders/" . + $order[0]->ord_id . + "/drops/" . + $order[0]->ord_drop_id . + "/checkers/" . + $req->auth->uid . + "/goods_$now.jpeg"; + } + if (!Storage::disk("public")->put($url_goods, base64_decode($req->goods_base64))) { + Storage::disk("public")->delete($url_general); + $apiResp = Responses::bad_request("fail upload image delivery order"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + DB::beginTransaction(); + + // update checker if id > 0 and new items if id == 0 + foreach ($req->items as $k => $v) { + // update + if ($v["id"] > 0) { + if ($req->type_check == Users::CHK_TYPE_PICKUP) { + OrdersItems::updt($v["id"], [ + "chk_pck_id" => $req->auth->uid, + "chk_pck_at" => $now, + ]); + } elseif ($req->type_check == Users::CHK_TYPE_DROP) { + OrdersItems::updt($v["id"], [ + "chk_drop_id" => $req->auth->uid, + "chk_drop_at" => $now, + ]); + } + } + // new data + else { + $insNewItem = [ + "ord_id" => $order[0]->ord_id, + "ord_code" => $order[0]->ord_code, + "pck_id" => $order[0]->ord_pck_id, + "drop_id" => $order[0]->ord_drop_id, + "item_code" => $v["item_code"], + "desc" => $v["desc"], + "unit_weight" => OrdersItems::DEFAULT_WEIGHT_UNIT, + "weight" => $v["weight"], + "unit_dimension" => OrdersItems::DEFAULT_DIMENSION_UNIT, + "qty" => $v["qty"] ?? 0, + "length" => $v["length"], + "wide" => $v["wide"], + "height" => $v["height"], + "volume" => $v["cbm"], + "crt" => $now, + ]; + if ($req->type_check == Users::CHK_TYPE_PICKUP) { + $insNewItem["chk_pck_new"] = $now; + } elseif ($req->type_check == Users::CHK_TYPE_DROP) { + $insNewItem["chk_drop_new"] = $now; + } + OrdersItems::add($insNewItem); + } + } + + // only delete if id > 0 + if ($req->items_deleted && count($req->items_deleted) > 0) { + foreach ($req->items_deleted as $k => $v) { + if ($v["id"] > 0) { + if ($req->type_check == Users::CHK_TYPE_PICKUP) { + OrdersItems::updt($v["id"], [ + "chk_pck_id" => $req->auth->uid, + "chk_pck_at" => $now, + "chk_pck_dlt" => $now, + ]); + } elseif ($req->type_check == Users::CHK_TYPE_DROP) { + OrdersItems::updt($v["id"], [ + "chk_drop_id" => $req->auth->uid, + "chk_drop_at" => $now, + "chk_drop_dlt" => $now, + ]); + } + } + } + } + + if ($req->type_check == Users::CHK_TYPE_PICKUP) { + // case jika sudah drop namun checker pickup belum upload dan harus upload + if ($order[0]->pck_chk_stts == OrdersPickups::CHK_STTS_SUBMIT) { + $updt_stts_order = $order[0]->status; + } else { + $check_updt_stts = [Orders::STTS_HAVE_GET_VHC, Orders::STTS_PCK]; + if (in_array($order[0]->status, $check_updt_stts)) { + $updt_stts_order = Orders::STTS_GO; + } else { + $updt_stts_order = $order[0]->status; + } + } + OrdersPickups::updt($order[0]->ord_pck_id, [ + // pck_* => dicomment pas tracking udah jalan + "pck_at" => $order[0]->pck_at ? $order[0]->pck_at : $now, // leave_at + "pck_enter_at" => $order[0]->pck_enter_at ? $order[0]->pck_enter_at : $now, + "pck_leave_at" => $order[0]->pck_leave_at ? $order[0]->pck_leave_at : $now, + "stts_pck" => OrdersPickups::STTS_PICKED, + "chk_id" => $req->auth->uid, + "chk_at" => $now, + "chk_stts" => OrdersPickups::CHK_STTS_SUBMIT, + "chk_img" => $url_general, + "chk_goods_img" => $url_goods, + "chk_name" => $req->auth->first_name, + "chk_mail" => $req->auth->email, + "chk_addr" => $req->auth->fulladdress, + "chk_phone_code" => $req->auth->phone_code, + "chk_phone_val" => $req->auth->phone, + "weight" => $calc_weight, + "cbm" => $calc_cbm, + "qty" => $calc_qty, + ]); + OrdersDrops::updt($order[0]->ord_drop_id, [ + "est_weight" => $calc_weight, + "est_cbm" => $calc_cbm, + "est_qty" => $calc_qty, + ]); + } elseif ($req->type_check == Users::CHK_TYPE_DROP) { + $check_updt_stts = [ + Orders::STTS_HAVE_GET_VHC, + Orders::STTS_PCK, + Orders::STTS_GO, + Orders::STTS_ARV, + Orders::STTS_DROP, + ]; + if (in_array($order[0]->status, $check_updt_stts)) { + $updt_stts_order = Orders::STTS_CLIENT_PAY; + } else { + $updt_stts_order = $order[0]->status; + } + OrdersDrops::updt($order[0]->ord_drop_id, [ + // drop_* => dicomment pas tracking udah jalan + "drop_at" => $order[0]->drop_at ? $order[0]->drop_at : $now, // leave_at + "drop_enter_at" => $order[0]->drop_enter_at ? $order[0]->drop_enter_at : $now, + "drop_leave_at" => $order[0]->drop_leave_at ? $order[0]->drop_leave_at : $now, + "stts_drop" => OrdersDrops::STTS_DROPED, + "chk_id" => $req->auth->uid, + "chk_at" => $now, + "chk_stts" => OrdersDrops::CHK_STTS_SUBMIT, + "chk_img" => $url_general, + "chk_goods_img" => $url_goods, + "chk_name" => $req->auth->first_name, + "chk_mail" => $req->auth->email, + "chk_addr" => $req->auth->fulladdress, + "chk_phone_code" => $req->auth->phone_code, + "chk_phone_val" => $req->auth->phone, + "weight" => $calc_weight, + "cbm" => $calc_cbm, + "qty" => $calc_qty, + ]); + // Vehicles::updateVehicle($order[0]->vhc_id, [ + // 'is_in_ord' => Vehicles::IN_ORD_NO, + // 'ord_id' => 0, + // 'ord_code' => 0, + // ]); + } + + Orders::updateOrder($order[0]->ord_id, [ + "status" => $updt_stts_order, + "going_at" => $order[0]->going_at ? $order[0]->going_at : $now, + "arrived_at" => $order[0]->arrived_at ? $order[0]->arrived_at : $now, + "weight" => $calc_weight, + "cbm" => $calc_cbm, + "qty" => $calc_qty, + ]); + + DB::commit(); + $apiResp = Responses::success("success submit checker data"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_checker_submit_pickup(Request $req) + { + $now = time(); + $url_seal_img = null; + $url_drv_armd_img = null; + $url_nopol_img = null; + $url_docs_client_img = []; + $url_install_seal_img = null; + $url_goods_img = null; + try { + $input = [ + "ord_id" => $req->ord_id, + "ord_pck_id" => $req->ord_pck_id, + "seal_number" => $req->seal_number, + "seal_img_base64" => $req->seal_img_base64, + "drv_armd_img_base64" => $req->drv_armd_img_base64, + "nopol_img_base64" => $req->nopol_img_base64, + "docs_client_img_base64" => $req->docs_client_img_base64, + "install_seal_img_base64" => $req->install_seal_img_base64, + "goods_img_base64" => $req->goods_img_base64, + ]; + $rulesInput = [ + "ord_id" => "required|integer|not_in:0", + "ord_pck_id" => "nullable|integer|not_in:0", + "seal_number" => "required|numeric", + "seal_img_base64" => "required|string", + "drv_armd_img_base64" => "required|string", + "nopol_img_base64" => "required|string", + "docs_client_img_base64" => "required|array", + "install_seal_img_base64" => "nullable|string", + "goods_img_base64" => "nullable|string", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + if (count($req->docs_client_img_base64) < 1) { + $apiResp = Responses::bad_input("silahkan upload dokumen kelengkapan dari client"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $order = Orders::showOrder([ + "id" => $req->ord_id, + "get_stts_checker" => 1, + // 'chk_id' => $req->auth->uid, + ]); + if (count($order) < 1) { + $apiResp = Responses::not_found("order not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + if ( + $order[0]->status === Orders::STTS_HAVE_GET_VHC || + $order[0]->status === Orders::STTS_PCK || + $order[0]->status === Orders::STTS_GO + ) { + } else { + $apiResp = Responses::bad_input("kendaraan belum berada di zona pickup"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + if ($req->seal_img_base64) { + $clearBase64 = preg_replace( + "/^data:(image|application)\/(png|jpg|jpeg|pdf);base64,/", + "", + $req->seal_img_base64, + ); + $type = "jpeg"; + if (strpos($req->seal_img_base64, "application/pdf") !== false) { + $type = "pdf"; + } + $url_seal_img = + "orders/" . + $order[0]->ord_id . + "/pickups/" . + $order[0]->ord_pck_id . + "/checkers/" . + $req->auth->uid . + "/seal_img_$now.$type"; + if (!Storage::disk("public")->put($url_seal_img, base64_decode($clearBase64))) { + $apiResp = Responses::bad_request("gagal upload foto seal"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + if ($req->drv_armd_img_base64) { + $clearBase64 = preg_replace( + "/^data:(image|application)\/(png|jpg|jpeg|pdf);base64,/", + "", + $req->drv_armd_img_base64, + ); + $type = "jpeg"; + if (strpos($req->drv_armd_img_base64, "application/pdf") !== false) { + $type = "pdf"; + } + $url_drv_armd_img = + "orders/" . + $order[0]->ord_id . + "/pickups/" . + $order[0]->ord_pck_id . + "/checkers/" . + $req->auth->uid . + "/drv_armd_img_$now.$type"; + if (!Storage::disk("public")->put($url_drv_armd_img, base64_decode($clearBase64))) { + Storage::disk("public")->delete($url_seal_img); + $apiResp = Responses::bad_request("gagal upload foto driver armada"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + if ($req->nopol_img_base64) { + $clearBase64 = preg_replace( + "/^data:(image|application)\/(png|jpg|jpeg|pdf);base64,/", + "", + $req->nopol_img_base64, + ); + $type = "jpeg"; + if (strpos($req->nopol_img_base64, "application/pdf") !== false) { + $type = "pdf"; + } + $url_nopol_img = + "orders/" . + $order[0]->ord_id . + "/pickups/" . + $order[0]->ord_pck_id . + "/checkers/" . + $req->auth->uid . + "/nopol_img_$now.$type"; + if (!Storage::disk("public")->put($url_nopol_img, base64_decode($clearBase64))) { + Storage::disk("public")->delete($url_seal_img); + Storage::disk("public")->delete($url_drv_armd_img); + $apiResp = Responses::bad_request("fail upload foto nomor polisi"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + if ($req->docs_client_img_base64 && count($req->docs_client_img_base64) > 0) { + $skip = false; + foreach ($req->docs_client_img_base64 as $i => $img) { + if ($skip) { + continue; + } + $clearBase64 = preg_replace( + "/^data:(image|application)\/(png|jpg|jpeg|pdf);base64,/", + "", + $img, + ); + $type = "jpeg"; + if (strpos($img, "application/pdf") !== false) { + $type = "pdf"; + } + $url_docs_client_img[$i] = + "orders/" . + $order[0]->ord_id . + "/pickups/" . + $order[0]->ord_pck_id . + "/checkers/" . + $req->auth->uid . + "/docs_client_img_$now" . + "_" . + "$i.$type"; + if ( + !Storage::disk("public")->put($url_docs_client_img[$i], base64_decode($clearBase64)) + ) { + Storage::disk("public")->delete($url_seal_img); + Storage::disk("public")->delete($url_drv_armd_img); + Storage::disk("public")->delete($url_nopol_img); + $apiResp = Responses::bad_request("gagal upload foto dokumen kelengkapan client"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + } + if ($req->install_seal_img_base64) { + $clearBase64 = preg_replace( + "/^data:(image|application)\/(png|jpg|jpeg|pdf);base64,/", + "", + $req->install_seal_img_base64, + ); + $type = "jpeg"; + if (strpos($req->install_seal_img_base64, "application/pdf") !== false) { + $type = "pdf"; + } + $url_install_seal_img = + "orders/" . + $order[0]->ord_id . + "/pickups/" . + $order[0]->ord_pck_id . + "/checkers/" . + $req->auth->uid . + "/install_seal_img_$now.$type"; + if (!Storage::disk("public")->put($url_install_seal_img, base64_decode($clearBase64))) { + Storage::disk("public")->delete($url_seal_img); + Storage::disk("public")->delete($url_drv_armd_img); + Storage::disk("public")->delete($url_nopol_img); + foreach ($url_docs_client_img as $path) { + Storage::disk("public")->delete($path); + } + $apiResp = Responses::bad_request("gagal upload foto pemasangan seal"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + if ($req->goods_img_base64) { + $clearBase64 = preg_replace( + "/^data:(image|application)\/(png|jpg|jpeg|pdf);base64,/", + "", + $req->goods_img_base64, + ); + $type = "jpeg"; + if (strpos($req->goods_img_base64, "application/pdf") !== false) { + $type = "pdf"; + } + $url_goods_img = + "orders/" . + $order[0]->ord_id . + "/pickups/" . + $order[0]->ord_pck_id . + "/checkers/" . + $req->auth->uid . + "/goods_img_$now.$type"; + if (!Storage::disk("public")->put($url_goods_img, base64_decode($clearBase64))) { + Storage::disk("public")->delete($url_seal_img); + Storage::disk("public")->delete($url_drv_armd_img); + Storage::disk("public")->delete($url_nopol_img); + foreach ($url_docs_client_img as $path) { + Storage::disk("public")->delete($path); + } + Storage::disk("public")->delete($url_install_seal_img); + $apiResp = Responses::bad_request("gagal upload foto barang"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + DB::beginTransaction(); + + Orders::updateOrder($order[0]->ord_id, [ + "status" => Orders::STTS_GO, + "going_at" => $order[0]->going_at ? $order[0]->going_at : $now, + "chk_stts" => Orders::CHK_STTS_HAS_PICKUP, + ]); + + OrdersPickups::updt($order[0]->ord_pck_id, [ + // pck_* => dicomment pas tracking udah jalan + "pck_at" => $order[0]->pck_at ? $order[0]->pck_at : $now, // leave_at + "pck_enter_at" => $order[0]->pck_enter_at ? $order[0]->pck_enter_at : $now, + "pck_leave_at" => $order[0]->pck_leave_at ? $order[0]->pck_leave_at : $now, + "stts_pck" => OrdersPickups::STTS_PICKED, + "chk_id" => $req->auth->uid, + "chk_at" => $now, + "chk_stts" => OrdersPickups::CHK_STTS_SUBMIT, + "chk_seal_number" => $req->seal_number, + "chk_seal_img" => $url_seal_img, + "chk_drv_armd_img" => $url_drv_armd_img, + "chk_nopol_img" => $url_nopol_img, + "chk_docs_client_img" => json_encode($url_docs_client_img), + "chk_seal_install_img" => $url_install_seal_img, + "chk_goods_img" => $url_goods_img, + "chk_name" => $req->auth->first_name, + "chk_mail" => $req->auth->email, + "chk_addr" => $req->auth->fulladdress, + "chk_phone_code" => $req->auth->phone_code, + "chk_phone_val" => $req->auth->phone, + ]); + + DB::commit(); + $apiResp = Responses::success("success submit laporan penjemputan"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + if ($url_seal_img) { + Storage::disk("public")->delete($url_seal_img); + } + if ($url_drv_armd_img) { + Storage::disk("public")->delete($url_drv_armd_img); + } + if ($url_nopol_img) { + Storage::disk("public")->delete($url_nopol_img); + } + if (count($url_docs_client_img) > 0) { + foreach ($url_docs_client_img as $path) { + Storage::disk("public")->delete($path); + } + } + if ($url_install_seal_img) { + Storage::disk("public")->delete($url_install_seal_img); + } + if ($url_goods_img) { + Storage::disk("public")->delete($url_goods_img); + } + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_checker_submit_drop(Request $req) + { + $now = time(); + $url_arrived_img = null; + $url_handover_img = null; + // $url_do_ttd_img = []; // multiple + $url_do_ttd_img = null; // single + // $url_spk_img = []; // multiple + $url_spk_img = null; // single + try { + $input = [ + "ord_id" => $req->ord_id, + "ord_drop_id" => $req->ord_drop_id, + "arrived_img_base64" => $req->arrived_img_base64, + "handover_img_base64" => $req->handover_img_base64, + "do_ttd_img_base64" => $req->do_ttd_img_base64, + "spk_img_base64" => $req->spk_img_base64, + ]; + $rulesInput = [ + "ord_id" => "required|integer|not_in:0", + "ord_drop_id" => "nullable|integer|not_in:0", + "arrived_img_base64" => "required|string", + "handover_img_base64" => "required|string", + "do_ttd_img_base64" => "required|string", + "spk_img_base64" => "required|string", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $order = Orders::showOrder([ + "id" => $req->ord_id, + "get_stts_checker" => 1, + // 'chk_id' => $req->auth->uid, + ]); + if (count($order) < 1) { + $apiResp = Responses::not_found("order not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + if ( + $order[0]->status === Orders::STTS_GO || + $order[0]->status === Orders::STTS_ARV || + $order[0]->status === Orders::STTS_DROP || + $order[0]->status === Orders::STTS_CLIENT_PAY + ) { + } else { + $apiResp = Responses::bad_input("kendaraan belum berada di zona drop"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + if ($req->arrived_img_base64) { + $clearBase64 = preg_replace( + "/^data:(image|application)\/(png|jpg|jpeg|pdf);base64,/", + "", + $req->arrived_img_base64, + ); + $type = "jpeg"; + if (strpos($req->arrived_img_base64, "application/pdf") !== false) { + $type = "pdf"; + } + $url_arrived_img = + "orders/" . + $order[0]->ord_id . + "/pickups/" . + $order[0]->ord_pck_id . + "/checkers/" . + $req->auth->uid . + "/arrived_img_$now.$type"; + if (!Storage::disk("public")->put($url_arrived_img, base64_decode($clearBase64))) { + $apiResp = Responses::bad_request("gagal upload foto seal"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + if ($req->handover_img_base64) { + $clearBase64 = preg_replace( + "/^data:(image|application)\/(png|jpg|jpeg|pdf);base64,/", + "", + $req->handover_img_base64, + ); + $type = "jpeg"; + if (strpos($req->handover_img_base64, "application/pdf") !== false) { + $type = "pdf"; + } + $url_handover_img = + "orders/" . + $order[0]->ord_id . + "/pickups/" . + $order[0]->ord_pck_id . + "/checkers/" . + $req->auth->uid . + "/handover_img_$now.$type"; + if (!Storage::disk("public")->put($url_handover_img, base64_decode($clearBase64))) { + Storage::disk("public")->delete($url_arrived_img); + $apiResp = Responses::bad_request("gagal upload foto driver armada"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + // single + if ($req->do_ttd_img_base64) { + $clearBase64 = preg_replace( + "/^data:(image|application)\/(png|jpg|jpeg|pdf);base64,/", + "", + $req->do_ttd_img_base64, + ); + $type = "jpeg"; + if (strpos($req->do_ttd_img_base64, "application/pdf") !== false) { + $type = "pdf"; + } + $url_do_ttd_img = + "orders/" . + $order[0]->ord_id . + "/pickups/" . + $order[0]->ord_pck_id . + "/checkers/" . + $req->auth->uid . + "/do_ttd_img_$now.$type"; + if (!Storage::disk("public")->put($url_do_ttd_img, base64_decode($clearBase64))) { + Storage::disk("public")->delete($url_arrived_img); + Storage::disk("public")->delete($url_handover_img); + $apiResp = Responses::bad_request("gagal upload do dt ttd"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + // multiple + // if ($req->do_ttd_img_base64 && count($req->do_ttd_img_base64) > 0) { + // $skip = false; + // foreach ($req->do_ttd_img_base64 as $i => $img) { + // if ($skip) continue; + // $clearBase64 = preg_replace('/^data:(image|application)\/(png|jpg|jpeg|pdf);base64,/', '', $img); + // $type = 'jpeg'; + // if (strpos($img, 'application/pdf') !== false) $type = 'pdf'; + // $url_do_ttd_img[$i] = "orders/" . $order[0]->ord_id . "/pickups/" . $order[0]->ord_pck_id . "/checkers/" . $req->auth->uid . "/do_ttd_img_$now" . "_" . "$i.$type"; + // if (!Storage::disk('public')->put($url_do_ttd_img[$i], base64_decode($clearBase64))) { + // Storage::disk('public')->delete($url_arrived_img); + // Storage::disk('public')->delete($url_handover_img); + // $apiResp = Responses::bad_request('gagal upload do ttd'); + // return (new Response($apiResp, $apiResp['meta']['code'])); + // } + // } + // } + // single + if ($req->spk_img_base64) { + $clearBase64 = preg_replace( + "/^data:(image|application)\/(png|jpg|jpeg|pdf);base64,/", + "", + $req->spk_img_base64, + ); + $type = "jpeg"; + if (strpos($req->spk_img_base64, "application/pdf") !== false) { + $type = "pdf"; + } + $url_spk_img = + "orders/" . + $order[0]->ord_id . + "/pickups/" . + $order[0]->ord_pck_id . + "/checkers/" . + $req->auth->uid . + "/spk_img_$now.$type"; + if (!Storage::disk("public")->put($url_spk_img, base64_decode($clearBase64))) { + Storage::disk("public")->delete($url_arrived_img); + Storage::disk("public")->delete($url_handover_img); + Storage::disk("public")->delete($url_do_ttd_img); + $apiResp = Responses::bad_request("gagal upload foto surat jalan di ttd"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + // multiple + + // kalau devices portable di lepas manual + DB::beginTransaction(); + + $updtOrd = [ + "status" => Orders::STTS_CLIENT_PAY, + "arrived_at" => $order[0]->arrived_at ? $order[0]->arrived_at : $now, + "chk_stts" => Orders::CHK_STTS_HAS_DROP, + ]; + + $checkPaidOff = Finance::checkJustPaidOff($order[0]->ord_id); + if ($checkPaidOff["invc_paid"] === 1) { + $updtOrd["is_invc_paid"] = Orders::IS_PAID_YES; + $updtOrd["invc_paid_at"] = $now; + } + if ($checkPaidOff["vdr_paid"] === 1) { + $updtOrd["is_vdr_paid"] = Orders::IS_PAID_YES; + $updtOrd["vdr_paid_at"] = $now; + } + if ($checkPaidOff["invc_vdr_paid"] === 1 || $checkPaidOff["invc_vdr_paid"] === 2) { + if ( + $order[0]->status === Orders::STTS_GO || + $order[0]->status === Orders::STTS_ARV || + $order[0]->status === Orders::STTS_DROP || + $order[0]->status === Orders::STTS_CLIENT_PAY || + $order[0]->status === Orders::STTS_VENDOR_PAYED + ) { + $updtOrd["status"] = Orders::STTS_CLOSE; + } + } + + if (count($updtOrd) > 0) { + Orders::updateOrder($order[0]->ord_id, $updtOrd); + } + + OrdersDrops::updt($order[0]->ord_drop_id, [ + // drop_* => dicomment pas tracking udah jalan + "drop_at" => $order[0]->drop_at ? $order[0]->drop_at : $now, // leave_at + "drop_enter_at" => $order[0]->drop_enter_at ? $order[0]->drop_enter_at : $now, + "drop_leave_at" => $order[0]->drop_leave_at ? $order[0]->drop_leave_at : $now, + "stts_drop" => OrdersDrops::STTS_DROPED, + "chk_id" => $req->auth->uid, + "chk_at" => $now, + "chk_stts" => OrdersDrops::CHK_STTS_SUBMIT, + "chk_arrived_img" => $url_arrived_img, + "chk_handover_img" => $url_handover_img, + "chk_do_ttd_img" => $url_do_ttd_img, + "chk_spk_img" => $url_spk_img, + "chk_name" => $req->auth->first_name, + "chk_mail" => $req->auth->email, + "chk_addr" => $req->auth->fulladdress, + "chk_phone_code" => $req->auth->phone_code, + "chk_phone_val" => $req->auth->phone, + ]); + + // kalau sudah selesai drop vhc & driver bisa order lagi + $vehicle = Vehicles::getVehicleById($order[0]->vhc_id); + $updtVhc = []; + if ($vehicle[0]->ord_ids) { + $vhc_in_ordis = json_decode($vehicle[0]->ord_ids); + foreach ($vhc_in_ordis as $key => $val) { + if ($val === $order[0]->ord_id) { + if (count($vhc_in_ordis) <= 1) { + $updtVhc = [ + "is_in_ord" => Vehicles::IN_ORD_NO, + "ord_id" => 0, + "ord_code" => 0, + "ord_ids" => null, + ]; + } else { + $updtVhc["ord_ids"] = $vhc_in_ordis; + array_splice($updtVhc["ord_ids"], $key, 1); + $updtVhc["ord_ids"] = json_encode($updtVhc["ord_ids"]); + } + } + } + } + if (count($updtVhc) > 0) { + Vehicles::updateVehicle($order[0]->vhc_id, $updtVhc); + } + $driver = Drivers::getDriverById($order[0]->drv_id); + $updtDrv = []; + if ($driver[0]->ord_ids) { + $drv_in_ordis = json_decode($driver[0]->ord_ids); + foreach ($drv_in_ordis as $key => $val) { + if ($val === $order[0]->ord_id) { + if (count($drv_in_ordis) <= 1) { + $updtDrv = [ + "is_in_ord" => Drivers::IN_ORD_NO, + "ord_id" => 0, + "ord_code" => 0, + "ord_ids" => null, + ]; + } else { + $updtDrv["ord_ids"] = $drv_in_ordis; + array_splice($updtDrv["ord_ids"], $key, 1); + $updtDrv["ord_ids"] = json_encode($updtDrv["ord_ids"]); + } + } + } + } + if (count($updtDrv) > 0) { + Drivers::updateDriver($order[0]->drv_id, $updtDrv); + } + + DB::commit(); + $apiResp = Responses::success("success submit laporan pengantaran"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + if ($url_arrived_img) { + Storage::disk("public")->delete($url_arrived_img); + } + if ($url_handover_img) { + Storage::disk("public")->delete($url_handover_img); + } + if ($url_do_ttd_img) { + Storage::disk("public")->delete($url_do_ttd_img); + } + if ($url_spk_img) { + Storage::disk("public")->delete($url_spk_img); + } + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_checker_submit_accident(Request $req) + { + $now = time(); + $url_accidents_img = []; + try { + $input = [ + "ord_id" => $req->ord_id, + "acdnt_loc" => $req->acdnt_loc, + "acdnt_story" => $req->acdnt_story, + "accidents_img_base64" => $req->accidents_img_base64, + "acdnt_vhc_nopol" => $req->acdnt_vhc_nopol, + "acdnt_vhc_type" => $req->acdnt_vhc_type, + "acdnt_drv_name" => $req->acdnt_drv_name, + "acdnt_drv_phone" => $req->acdnt_drv_phone, + ]; + $rulesInput = [ + "ord_id" => "required|integer|not_in:0", + "acdnt_loc" => "required|string", + "acdnt_story" => "required|string", + "accidents_img_base64" => "nullable|array", + "acdnt_vhc_nopol" => "required|string", + "acdnt_vhc_type" => "required|numeric|not_in:0", + "acdnt_drv_name" => "required|string|max:255", + "acdnt_drv_phone" => "required|numeric", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + if ($req->accidents_img_base64 && count($req->accidents_img_base64) < 1) { + $apiResp = Responses::bad_input("silahkan mengunggah foto pendukung"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + $nopol = explode(" ", strtoupper($req->acdnt_vhc_nopol)); + if (count($nopol) < 3) { + $apiResp = Responses::bad_input("Nomor polisi kendaraan tidak valid"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $order = Orders::showOrder([ + "id" => $req->ord_id, + "get_stts_checker" => 1, + "get_additional_vehicles_info" => 1, + "get_accidents" => 1, + ]); + if (count($order) < 1) { + $apiResp = Responses::not_found("order not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + DB::beginTransaction(); + + if ($order[0]->is_accident === Orders::IS_ACCIDENT_YES) { + $imgs = json_decode($order[0]->ord_acdnt_imgs); + $countImgs = count($imgs); + + if ($req->accidents_img_base64 && count($req->accidents_img_base64) > 0) { + $skip = false; + foreach ($req->accidents_img_base64 as $i => $img) { + if ($skip) { + continue; + } + $clearBase64 = preg_replace( + "/^data:(image|application)\/(png|jpg|jpeg|pdf);base64,/", + "", + $img, + ); + $type = "jpeg"; + if (strpos($img, "application/pdf") !== false) { + $type = "pdf"; + } + $imgs[$i + $countImgs] = + "orders/" . + $order[0]->ord_id . + "/accidents/" . + $order[0]->ord_acdnt_id . + "/accidents_img_$now" . + "_" . + "" . + ($i + $countImgs) . + ".$type"; + if ( + !Storage::disk("public")->put($imgs[$i + $countImgs], base64_decode($clearBase64)) + ) { + $apiResp = Responses::bad_request("gagal upload mengunggah foto pendukung"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + } + + OrdersAccidents::updateAccident($order[0]->ord_acdnt_id, [ + "accident_location" => $req->acdnt_loc, + "accident_story" => $req->acdnt_story, + "accident_imgs" => json_encode($imgs), + "new_nopol1" => $nopol[0], + "new_nopol2" => $nopol[1], + "new_nopol3" => $nopol[2], + "new_vhc_type_id" => $req->acdnt_vhc_type, + "new_drv_name" => $req->acdnt_drv_name, + "new_drv_phone_val" => (int) $req->acdnt_drv_phone, + ]); + } else { + $input = [ + "accidents_img_base64" => $req->accidents_img_base64, + ]; + $rulesInput = [ + "accidents_img_base64" => "required|array", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + Orders::updateOrder($order[0]->ord_id, [ + "is_accident" => Orders::IS_ACCIDENT_YES, + ]); + + $aid = OrdersAccidents::addAccident([ + "ord_id" => $order[0]->ord_id, + "ord_code" => $order[0]->ord_code, + "accident_location" => $req->acdnt_loc, + "accident_story" => $req->acdnt_story, + "accident_imgs" => json_encode($url_accidents_img), + "new_vhc_id" => $order[0]->vhc_id, + "new_nopol1" => $nopol[0], + "new_nopol2" => $nopol[1], + "new_nopol3" => $nopol[2], + "old_nopol1" => $order[0]->vhc_nopol1, + "old_nopol2" => $order[0]->vhc_nopol2, + "old_nopol3" => $order[0]->vhc_nopol3, + "new_vhc_type_id" => $req->acdnt_vhc_type, + "old_vhc_type_id" => $order[0]->vhc_type_id, + "new_drv_name" => $req->acdnt_drv_name, + "new_drv_phone_val" => (int) $req->acdnt_drv_phone, + "old_drv_id" => $order[0]->drv_id, + "old_drv_name" => $order[0]->drv_name, + "old_drv_phone_code" => $order[0]->drv_phone_code, + "old_drv_phone_val" => $order[0]->drv_phone_val, + "crt" => $now, + "crt_by" => $req->auth->uid, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]); + + if ($req->accidents_img_base64 && count($req->accidents_img_base64) > 0) { + $skip = false; + foreach ($req->accidents_img_base64 as $i => $img) { + if ($skip) { + continue; + } + $url_accidents_img[$i] = + "orders/" . + $order[0]->ord_id . + "/accidents/" . + $aid . + "/accidents_img_$now" . + "_" . + "$i.jpeg"; + if (!Storage::disk("public")->put($url_accidents_img[$i], base64_decode($img))) { + $apiResp = Responses::bad_request("gagal upload mengunggah foto pendukung"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + } + + OrdersAccidents::updateAccident($aid, [ + "accident_imgs" => json_encode($url_accidents_img), + ]); + } + + DB::commit(); + $apiResp = Responses::success("success submit laporan kecelakaan"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + if (count($url_accidents_img) > 0) { + foreach ($url_accidents_img as $path) { + Storage::disk("public")->delete($path); + } + } + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_checker_aprv_pck(Request $req) + { + $now = time(); + try { + $input = [ + "ord_id" => $req->ord_id, + "ord_pck_id" => $req->ord_pck_id, + "is_aprv_pck" => $req->is_aprv_pck, + "ord_pck_drop_id" => $req->ord_pck_drop_id, + ]; + $rulesInput = [ + "ord_id" => "required|integer|not_in:0", + "ord_pck_drop_id" => "required|integer|not_in:0", + "ord_pck_id" => "required|integer|not_in:0", + "is_aprv_pck" => "required|numeric", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $order = Orders::showOrder([ + "id" => $req->ord_id, + "get_drv_bank" => 1, + "ord_pck_drop_id" => $req->ord_pck_drop_id, + "couple_pck_drop" => 1, + ]); + if (count($order) < 1) { + $apiResp = Responses::not_found("order not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $drvPhone = DrvPhoneDevices::get(["drv_id" => $order[0]->drv_id]); + if (count($drvPhone) < 1) { + $apiResp = Responses::bad_request("Driver belum pernah melakukan login"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $firstCheckpoint = OrdersCheckpoints::listCheckpoints([ + "sort" => 1, + "ord_id" => $order[0]->ord_id, + ]); + if (count($order) < 1) { + $apiResp = Responses::not_found("checkpoint not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + /** + * approval checker (validasi 4 kondisi) + * Lokasi GPS kendaraan harus didalam zona pickup (GPS Tracker GT06, EElink) + * Lokasi GPS App tracker harus didalam zona pickup (Smartphone driver apps) + * Lokasi GPS kendaraan dan GPS App Tracker harus match + * DONE Driver harus mengunggah foto sampai step 4 + */ + + $lastLocDriverAps = Tracks::gpsLocsAddr([ + "source" => Tracks::SOURCE_SMARTPHONE, + "drv_id" => $order[0]->drv_id, + "order_by" => " tr.id DESC", + "limit" => 1, + ]); + if (count($lastLocDriverAps) < 1) { + $apiResp = Responses::bad_request("Lokasi GPS App Tracker tidak didalam zona pickup"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + $drvAppInsideCircle = Zone::insideOrdZoneCircle( + $lastLocDriverAps[0]->latitude, + $lastLocDriverAps[0]->longitude, + ["zid" => $order[0]->ord_pck_zone_id], + ); + $drvAppInsideShape = Zone::insideOrdZoneShape( + $lastLocDriverAps[0]->latitude, + $lastLocDriverAps[0]->longitude, + ["zid" => $order[0]->ord_pck_zone_id], + ); + if (count($drvAppInsideCircle) < 1 && count($drvAppInsideShape) < 1) { + $apiResp = Responses::bad_request("Lokasi GPS App Tracker tidak didalam zona pickup"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + // $lastLocGpsTracker = Tracks::gpsLocsAddr(['source' => Tracks::SOURCE_GPS_TRACKER, 'vhc_id' => $order[0]->vhc_id, 'order_by' => ' tr.id DESC', 'limit' => 1]); + // if (count($lastLocGpsTracker) < 1) { + // $apiResp = Responses::bad_request('Lokasi GPS Kendaraan tidak didalam zona pickup'); + // return (new Response($apiResp, $apiResp['meta']['code'])); + // } + // $gpsTrackerInsideCircle = Zone::insideOrdZoneCircle($lastLocGpsTracker[0]->latitude, $lastLocGpsTracker[0]->longitude, ['zid' => $order[0]->ord_pck_zone_id]); + // $gpsTrackerInsideShape = Zone::insideOrdZoneShape($lastLocGpsTracker[0]->latitude, $lastLocGpsTracker[0]->longitude, ['zid' => $order[0]->ord_pck_zone_id]); + // if (count($gpsTrackerInsideCircle) < 1 && count($gpsTrackerInsideShape) < 1) { + // $apiResp = Responses::bad_request('Lokasi GPS Kendaraan tidak didalam zona pickup'); + // return (new Response($apiResp, $apiResp['meta']['code'])); + // } + + // $distance = Helper::haversineGreatCircleDistance($lastLocDriverAps[0]->latitude, $lastLocDriverAps[0]->longitude, $lastLocGpsTracker[0]->latitude, $lastLocGpsTracker[0]->longitude); + // // more than 100 meters + // if ($distance > 100) { + // $apiResp = Responses::bad_request('Lokasi GPS kendaraan dan GPS App Tracker harus match'); + // return (new Response($apiResp, $apiResp['meta']['code'])); + // } + + $admins = Users::getUsersActiveByRole(Users::ROLE_FINANCE); + $admins_data = []; + foreach ($admins as $k => $v) { + array_push($admins_data, [ + "admin_id" => $v->id, + "admin_name" => $v->first_name, + "admin_phone" => $v->phone_code . " " . implode(" ", str_split($v->phone, 4)), + "admin_mail" => $v->email, + "admin_addr" => "", + ]); + } + + $dana = Dana::getDanaById(Dana::PK_ID); + if (count($dana) < 1) { + $apiResp = Responses::bad_request("dana error"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + $dana = $dana[0]; + + DB::beginTransaction(); + + $insOrdersAItems = [ + "ord_id" => $order[0]->ord_id, + "ord_code" => $order[0]->ord_code, + "flow_type" => OrdersAItems::FLOW_TYPE_PAYMENT, + "cash_type" => OrdersAItems::TYPE_CASH_OUT, + "a_item_type" => OrdersAItems::A_TYPE_SECONDARY, + "unit_id" => 0, + "unit_type" => UnitTypes::UNIT_TYPE_UNIT, + "amt_base_flat" => $firstCheckpoint[0]->pocket_total, + "unit_qty" => 0, + "amt_tax_type" => 0, + "amt_tax_ppn_percent" => 0, + "amt_tax_ppn_flat" => 0, + "amt_tax_pph_percent" => 0, + "amt_tax_pph_flat" => 0, + "amt_total_tax_flat" => 0, + "amt_result_flat" => $firstCheckpoint[0]->pocket_total, + "amt_total_flat" => $firstCheckpoint[0]->pocket_total, + "only_vdr" => OrdersAItems::ONLY_VDR_YES, + "bank_id" => $order[0]->drv_bank_id, + "bank_name" => $order[0]->drv_bank_name, + "bank_code" => $order[0]->drv_bank_code, + "bank_short_name" => $order[0]->drv_bank_short_name, + "bank_branch_name" => $order[0]->drv_bank_branch_name ?? null, + "bank_acc_name" => $order[0]->drv_bank_acc_name, + "bank_acc_number" => $order[0]->drv_bank_acc_number, + "ref_ord_id" => $order[0]->ord_id, + "ref_ord_code" => $order[0]->ord_code, + "crt" => $now, + "crt_by" => $req->auth->uid, + "updt" => $now, + "updt_by" => $req->auth->uid, + "desc" => "Uang Saku Driver di " . $firstCheckpoint[0]->pck_name, + ]; + + $insOrdersAItems["calc_to_vdr"] = OrdersAItems::CALC_TO_VDR_YES; + $termins = OrdersTermins::listWithFilter([ + "ord_id" => $order[0]->ord_id, + "termin_for" => OrdersTermins::TERMIN_FOR_VENDOR, + "termin_is_paid" => OrdersTermins::IS_PAID_NO, + "in_stts_merge" => [OrdersAItems::STTS_MERGE_NO, OrdersAItems::STTS_MERGE_RESULT], + ]); + $insOrdersAItems["v_termin_id"] = 0; + $insOrdersAItems["ref_v_termin_id"] = 0; + if (count($termins) > 0) { + $insOrdersAItems["v_termin_id"] = $termins[0]->id; + $insOrdersAItems["ref_v_termin_id"] = $termins[0]->id; + } + if ($insOrdersAItems["v_termin_id"] === 0) { + $termins = OrdersTermins::listWithFilter([ + "ord_id" => $order[0]->ord_id, + "termin_for" => OrdersTermins::TERMIN_FOR_VENDOR, + "in_stts_merge" => [OrdersAItems::STTS_MERGE_NO, OrdersAItems::STTS_MERGE_RESULT], + ]); + $insOrdersAItems["v_termin_id"] = $termins[count($termins) - 1]->id; + $insOrdersAItems["ref_v_termin_id"] = $termins[count($termins) - 1]->id; + } + OrdersAItems::add($insOrdersAItems); + + OrdersPckDrop::updt($req->ord_pck_drop_id, [ + "stts" => OrdersPckDrop::STTS_DELIVERY_OTW_DROP, + "is_aprv_pck" => OrdersPckDrop::IS_APRV_YES, + "aprv_pck_by" => $req->auth->id, + "aprv_pck_at" => $now, + ]); + + $url = env("API_DANA_BINGCORP") . "/order/create"; + $guzReq = new GuzzleClient(); + $json = [ + "ord_id" => $order[0]->ord_id, + "ord_code" => $order[0]->ord_code, + "checkpoint_id" => $firstCheckpoint[0]->ord_checkpoint_id, + "bank_code" => $order[0]->drv_bank_code, + "bank_name" => $order[0]->drv_bank_name, + "bank_branch" => $order[0]->drv_bank_branch_name ?? null, + "amt" => $firstCheckpoint[0]->pocket_total, + "acc_name" => $order[0]->drv_bank_acc_name, + "acc_number" => $order[0]->drv_bank_acc_number, + "device_id" => $drvPhone[0]->device_id, + ]; + if ($dana->amt > $firstCheckpoint[0]->pocket_total && $dana->amt > Dana::MINIMUM_AMT) { + try { + $respDana = $guzReq->request("POST", $url, [ + "headers" => [ + // 'Host' => $_SERVER['SERVER_ADDR'] ?? '127.0.0.1', + "User-Agent" => "curl/7.65.3", + "Accept" => "*/*", + "Accept-Encoding" => "gzip, deflate, br", + // 'Content-Type' => 'application/x-www-form-urlencoded; charset=UTF-8', + "Content-Type" => "application/json", + // 'Connection' => 'keep-alive', + ], + "json" => $json, + ]); + $isValidDana = 1; + $bodyDana = json_decode($respDana->getBody()->getContents()); + if ($respDana->getStatusCode() != 200 || $bodyDana->meta->code != 200) { + $isValidDana = 0; + // DB::rollBack(); + OrdersLogsTf::addLogsTf([ + "ord_id" => $order[0]->ord_id, + "ord_code" => $order[0]->ord_code, + "type" => OrdersLogsTf::TYPE_TF_CHECKPOINT, + "checkpoint_id" => $firstCheckpoint[0]->id, + "amount" => $firstCheckpoint[0]->pocket_total, + "stts" => OrdersLogsTf::STTS_FAIL, + "fail_at" => time(), + "note" => $bodyDana->data->note, + "bank_id" => $order[0]->drv_bank_id, + "bank_name" => $order[0]->drv_bank_name, + "bank_code" => $order[0]->drv_bank_code, + "bank_short_name" => $order[0]->drv_bank_short_name, + "bank_branch_name" => $order[0]->drv_bank_branch_name ?? null, + "bank_acc_name" => $order[0]->drv_bank_acc_name, + "bank_acc_number" => $order[0]->drv_bank_acc_number, + "method" => OrdersLogsTf::METHOD_DANA, + "url" => $url, + "ref_code" => $bodyDana->data->dana_reference_no, + "req_data" => json_encode($json), + "resp_data" => json_encode($bodyDana), + "crt" => time(), + "updt" => time(), + ]); + OrdersCheckpoints::updateCheckpoint($firstCheckpoint[0]->id, [ + "pocket_is_paid" => OrdersCheckpoints::IS_TF_FAIL, + "pocket_paid_note" => $bodyDana->data->note, + "bank_id" => $order[0]->drv_bank_id, + "bank_name" => $order[0]->drv_bank_name, + "bank_code" => $order[0]->drv_bank_code, + "bank_short_name" => $order[0]->drv_bank_short_name, + "bank_branch_name" => $order[0]->drv_bank_branch_name ?? null, + "bank_acc_name" => $order[0]->drv_bank_acc_name, + "bank_acc_number" => $order[0]->drv_bank_acc_number, + "tf_method" => OrdersCheckpoints::TF_METHOD_DANA, + "tf_at" => $now, + "tf_url" => $url, + "tf_ref_code" => $bodyDana->data->dana_reference_no, + "tf_note" => $bodyDana->data->note, + "tf_req_data" => json_encode($json), + "tf_resp_data" => json_encode($bodyDana), + ]); + // $apiResp = Responses::bad_request('approval ditolak. gagal transfer ke rekening driver'); + // return (new Response($apiResp, $apiResp['meta']['code'])); + } + + if ($isValidDana === 1) { + OrdersLogsTf::addLogsTf([ + "ord_id" => $order[0]->ord_id, + "ord_code" => $order[0]->ord_code, + "type" => OrdersLogsTf::TYPE_TF_CHECKPOINT, + "checkpoint_id" => $firstCheckpoint[0]->id, + "amount" => $firstCheckpoint[0]->pocket_total, + "stts" => OrdersLogsTf::STTS_PAID, + "paid_at" => time(), + "note" => $bodyDana->data->note, + "bank_id" => $order[0]->drv_bank_id, + "bank_name" => $order[0]->drv_bank_name, + "bank_code" => $order[0]->drv_bank_code, + "bank_short_name" => $order[0]->drv_bank_short_name, + "bank_branch_name" => $order[0]->drv_bank_branch_name ?? null, + "bank_acc_name" => $order[0]->drv_bank_acc_name, + "bank_acc_number" => $order[0]->drv_bank_acc_number, + "method" => OrdersLogsTf::METHOD_DANA, + "url" => $url, + "ref_code" => $bodyDana->data->dana_reference_no, + "req_data" => json_encode($json), + "resp_data" => json_encode($bodyDana), + "crt" => time(), + "updt" => time(), + ]); + OrdersCheckpoints::updateCheckpoint($firstCheckpoint[0]->id, [ + "pocket_is_paid" => OrdersCheckpoints::IS_PAID, + "pocket_paid_at" => $now, + // 'pocket_paid_by' => $req->auth->id, + "bank_id" => $order[0]->drv_bank_id, + "bank_name" => $order[0]->drv_bank_name, + "bank_code" => $order[0]->drv_bank_code, + "bank_short_name" => $order[0]->drv_bank_short_name, + "bank_branch_name" => $order[0]->drv_bank_branch_name ?? null, + "bank_acc_name" => $order[0]->drv_bank_acc_name, + "bank_acc_number" => $order[0]->drv_bank_acc_number, + "tf_method" => OrdersCheckpoints::TF_METHOD_DANA, + "tf_at" => $now, + "tf_url" => $url, + "tf_ref_code" => $bodyDana->data->dana_reference_no ?? 0, + "tf_note" => $bodyDana->data->note ?? 0, + "tf_req_data" => json_encode($json), + "tf_resp_data" => json_encode($bodyDana), + ]); + Dana::updateDana($dana->id, [ + "amt" => DB::raw("amt-" . $firstCheckpoint[0]->pocket_total), + ]); + } + } catch (\GuzzleHttp\Exception\BadResponseException $e) { + $respDana = $e->getResponse(); + $bodyDana = json_decode($respDana->getBody()->getContents()); + // DB::rollBack(); + OrdersLogsTf::addLogsTf([ + "ord_id" => $order[0]->ord_id, + "ord_code" => $order[0]->ord_code, + "type" => OrdersLogsTf::TYPE_TF_CHECKPOINT, + "checkpoint_id" => $firstCheckpoint[0]->id, + "amount" => $firstCheckpoint[0]->pocket_total, + "stts" => OrdersLogsTf::STTS_FAIL, + "fail_at" => time(), + "note" => $bodyDana->data->note, + "bank_id" => $order[0]->drv_bank_id, + "bank_name" => $order[0]->drv_bank_name, + "bank_code" => $order[0]->drv_bank_code, + "bank_short_name" => $order[0]->drv_bank_short_name, + "bank_branch_name" => $order[0]->drv_bank_branch_name ?? null, + "bank_acc_name" => $order[0]->drv_bank_acc_name, + "bank_acc_number" => $order[0]->drv_bank_acc_number, + "method" => OrdersLogsTf::METHOD_DANA, + "url" => $url, + "ref_code" => $bodyDana->data->dana_reference_no, + "req_data" => json_encode($json), + "resp_data" => json_encode($bodyDana), + "crt" => time(), + "updt" => time(), + ]); + OrdersCheckpoints::updateCheckpoint($firstCheckpoint[0]->id, [ + "pocket_is_paid" => OrdersCheckpoints::IS_TF_FAIL, + "pocket_paid_note" => $bodyDana->data->note, + "bank_id" => $order[0]->drv_bank_id, + "bank_name" => $order[0]->drv_bank_name, + "bank_code" => $order[0]->drv_bank_code, + "bank_short_name" => $order[0]->drv_bank_short_name, + "bank_branch_name" => $order[0]->drv_bank_branch_name ?? null, + "bank_acc_name" => $order[0]->drv_bank_acc_name, + "bank_acc_number" => $order[0]->drv_bank_acc_number, + "tf_method" => OrdersCheckpoints::TF_METHOD_DANA, + "tf_at" => $now, + "tf_url" => $url, + "tf_ref_code" => $bodyDana->data->dana_reference_no, + "tf_note" => $bodyDana->data->note, + "tf_req_data" => json_encode($json), + "tf_resp_data" => json_encode($bodyDana), + ]); + // $apiResp = Responses::bad_request('approval ditolak. gagal transfer ke rekening driver'); + // return (new Response($apiResp, $apiResp['meta']['code'])); + } + } else { + $url = env("API_URL_NODE") . "/order/finance_info_dana_amount"; + $guzReq = new GuzzleClient(); + $respNode = $guzReq->request("POST", $url, [ + "headers" => [ + "Host" => $_SERVER["SERVER_ADDR"] ?? "127.0.0.1", + "User-Agent" => "curl/7.65.3", + "Accept" => "*/*", + "Accept-Encoding" => "gzip, deflate, br", + // 'Content-Type' => 'application/x-www-form-urlencoded; charset=UTF-8', + // 'Connection' => 'keep-alive', + ], + "json" => [ + "trx_code" => $order[0]->ord_code, + "drv_name" => $order[0]->drv_name, + "pickup_zone_title" => $order[0]->pck_name, + "pickup_zone_addr" => $order[0]->pck_addr, + "drop_zone_title" => $order[0]->drop_name, + "drop_zone_addr" => $order[0]->drop_addr, + "pocket_total" => + "Rp" . number_format($firstCheckpoint[0]->pocket_total, 0, ",", "."), + "bank_name" => $order[0]->drv_bank_name, + "bank_code" => $order[0]->drv_bank_code, + "bank_branch_name" => $order[0]->drv_bank_branch_name ?? "", + "bank_acc_name" => $order[0]->drv_bank_acc_name, + "bank_acc_no" => $order[0]->drv_bank_acc_number, + "admins" => $admins_data, + ], + ]); + if ($respNode->getStatusCode() != 200) { + DB::rollBack(); + $apiResp = Responses::bad_request("gagal mengirim email ke finance"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + $body = json_decode($respNode->getBody()->getContents()); + } + + DB::commit(); + + $url = env("API_URL_NODE") . "/order/finance_info_tf_pocket"; + $guzReq = new GuzzleClient(); + $respNode = $guzReq->request("POST", $url, [ + "headers" => [ + "Host" => $_SERVER["SERVER_ADDR"] ?? "127.0.0.1", + "User-Agent" => "curl/7.65.3", + "Accept" => "*/*", + "Accept-Encoding" => "gzip, deflate, br", + // 'Content-Type' => 'application/x-www-form-urlencoded; charset=UTF-8', + // 'Connection' => 'keep-alive', + ], + "json" => [ + "trx_code" => $order[0]->ord_code, + "drv_name" => $order[0]->drv_name, + "pickup_zone_title" => $order[0]->pck_name, + "pickup_zone_addr" => $order[0]->pck_addr, + "drop_zone_title" => $order[0]->drop_name, + "drop_zone_addr" => $order[0]->drop_addr, + "pocket_total" => "Rp" . number_format($firstCheckpoint[0]->pocket_total, 0, ",", "."), + "bank_name" => $order[0]->drv_bank_name, + "bank_code" => $order[0]->drv_bank_code, + "bank_branch_name" => $order[0]->drv_bank_branch_name ?? "", + "bank_acc_name" => $order[0]->drv_bank_acc_name, + "bank_acc_no" => $order[0]->drv_bank_acc_number, + "admins" => $admins_data, + ], + ]); + if ($respNode->getStatusCode() != 200) { + DB::rollBack(); + $apiResp = Responses::bad_request("gagal mengirim email ke finance"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + $body = json_decode($respNode->getBody()->getContents()); + + $apiResp = Responses::success("persetujuan diterima"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + // before approval checker + public function api_recreate_pocket(Request $req) + { + $now = time(); + try { + $input = [ + "ord_id" => $req->ord_id, + "pocket_id" => $req->pocket_id, + ]; + $rulesInput = [ + "ord_id" => "required|integer|not_in:0", + "pocket_id" => "required|integer|not_in:0", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $orders = Orders::showOrder([ + "id" => $req->ord_id, + // 'get_drv_bank' => 1, + // 'ord_pck_drop_id' => $req->ord_pck_drop_id, + "couple_pck_drop" => 1, + "join_pockets" => 1, + "group_by" => "ord.id", + ]); + if (count($orders) < 1) { + $apiResp = Responses::not_found("order not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + $order = $orders[0]; + + $pocket = PocketMoney::showPocketById($req->pocket_id); + if (count($pocket) < 1) { + $apiResp = Responses::not_found("uang saku belum dipilih"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + $pocket[0]->checkpoints = Checkpoints::listCheckpoints([ + "pocket_id" => $pocket[0]->id, + ]); + + if ($pocket[0]->id === $order->pocket_id) { + $apiResp = Responses::bad_request("uang saku tidak ada perubahan"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + DB::beginTransaction(); + OrdersPockets::updatePocket($order->ord_pocket_id, [ + // 'ord_id' => $order->ord_id, + // 'ord_code' => $order->ord_code, + "pocket_id" => $pocket[0]->id, + "pocket_code" => $pocket[0]->code, + "pocket_name" => $pocket[0]->name, + "pck_id" => $pocket[0]->pck_id, + "drop_id" => $pocket[0]->drop_id, + "pocket_type" => $pocket[0]->type, + "pocket_flow" => $pocket[0]->flow, + "pocket_is_active" => $pocket[0]->is_active, + "pocket_total" => $pocket[0]->total, + // 'crt' => $now, + // 'crt_by' => $req->auth->uid, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]); + OrdersCheckpoints::deleteCheckpointByOrdPocketId($order->ord_pocket_id); + foreach ($pocket[0]->checkpoints as $checkpoint) { + OrdersCheckpoints::addCheckpoint([ + "ord_id" => $order->ord_id, + "ord_code" => $order->ord_code, + "ord_pocket_id" => $order->ord_pocket_id, + "pocket_id" => $checkpoint->pocket_id, + "pck_id" => $checkpoint->pck_id, + "drop_id" => $checkpoint->drop_id, + "pocket_sort" => $checkpoint->sort, + "pocket_fee" => $checkpoint->pocket_fee, + "pocket_tol_fee" => $checkpoint->tol_fee, + "pocket_fuel_fee" => $checkpoint->fuel_fee, + "pocket_total" => $checkpoint->total, + "crt" => $now, + "crt_by" => $req->auth->uid, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]); + } + + DB::commit(); + + $apiResp = Responses::success("berhasil ganti uang saku"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_change_pic_invoice(Request $req) + { + $now = time(); + try { + $input = [ + "ord_id" => $req->ord_id, + "ord_client_id" => $req->ord_client_id, + "c_pt_name" => $req->c_pt_name, + "c_pt_addr" => $req->c_pt_addr, + "c_pt_pic_name" => $req->c_pt_pic_name, + "c_pt_pic_phone_val" => $req->c_pt_pic_phone_val, + ]; + $rulesInput = [ + "ord_id" => "required|integer|not_in:0", + "ord_client_id" => "required|integer|not_in:0", + "c_pt_name" => "required|string", + "c_pt_addr" => "required|string", + "c_pt_pic_name" => "required|string", + "c_pt_pic_phone_val" => "required|integer|not_in:0", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $orders = Orders::showOrder([ + "id" => $req->ord_id, + // 'get_drv_bank' => 1, + // 'ord_pck_drop_id' => $req->ord_pck_drop_id, + "couple_pck_drop" => 1, + // 'join_pockets' => 1, + "get_client_pt" => 1, + "group_by" => "ord.id", + ]); + if (count($orders) < 1) { + $apiResp = Responses::not_found("order not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + $order = $orders[0]; + + DB::beginTransaction(); + OrdersClients::updt($order->ord_client_id, [ + "c_pt_name" => $req->c_pt_name, + "c_pt_addr" => $req->c_pt_addr, + "c_pt_pic_name" => $req->c_pt_pic_name, + "c_pt_pic_phone_val" => $req->c_pt_pic_phone_val, + ]); + DB::commit(); + + $apiResp = Responses::success("berhasil ganti pic invoice"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_adm_confirm_price(Request $req) + { + try { + $now = time(); + $input = [ + "ord_id" => $req->ord_id, + ]; + $rulesInput = [ + "ord_id" => "required|integer|not_in:0", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $filter = [ + "id" => $req->ord_id, + "get_stts_checker" => 1, + ]; + $order = Orders::showOrder($filter); + if (count($order) < 1) { + $apiResp = Responses::not_found("order not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $updt_stts_order = $order[0]->status; + if ( + $order[0]->status == Orders::STTS_CLIENT_PAY || + $order[0]->status == Orders::STTS_VENDOR_PAYED + ) { + } elseif ($order[0]->status == Orders::STTS_CANCEL) { + $apiResp = Responses::bad_input('can\'t confirm price, order is cancel'); + return new Response($apiResp, $apiResp["meta"]["code"]); + } elseif ($order[0]->status == Orders::STTS_CLOSE) { + $apiResp = Responses::bad_input('can\'t confirm price, transaction is close'); + return new Response($apiResp, $apiResp["meta"]["code"]); + } elseif ($order[0]->pck_chk_stts != OrdersPickups::CHK_STTS_SUBMIT) { + $apiResp = Responses::bad_input( + 'can\'t confirm price, checker pickup has not submitted data', + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + // else { + // $apiResp = Responses::bad_input('can\'t confirm price, order still on going'); + // return new Response($apiResp, $apiResp['meta']['code']); + // } + + DB::beginTransaction(); + + Orders::updateOrder($order[0]->ord_id, [ + "is_fix_price" => Orders::IS_FIX_PRICE_YES, + "fix_price_at" => $now, + "fix_price_by" => $req->auth->id, + "updt" => $now, + "updt_by" => $req->auth->id, + ]); + + DB::commit(); + $apiResp = Responses::success("success confirm price"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_adm_invc_to_client(Request $req) + { + try { + $now = time(); + $input = [ + "ord_id" => $req->ord_id, + ]; + $rulesInput = [ + "ord_id" => "required|integer|not_in:0", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $filter = [ + "id" => $req->ord_id, + "get_stts_checker" => 1, + ]; + $order = Orders::showOrder($filter); + if (count($order) < 1) { + $apiResp = Responses::not_found("order not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $updt_stts_order = $order[0]->status; + if ( + $order[0]->status == Orders::STTS_CLIENT_PAY || + $order[0]->status == Orders::STTS_VENDOR_PAYED + ) { + } elseif ($order[0]->status == Orders::STTS_CANCEL) { + $apiResp = Responses::bad_input('can\'t generate invoice, order is cancel'); + return new Response($apiResp, $apiResp["meta"]["code"]); + } elseif ($order[0]->status == Orders::STTS_CLOSE) { + $apiResp = Responses::bad_input('can\'t generate invoice, transaction is close'); + return new Response($apiResp, $apiResp["meta"]["code"]); + } elseif ($order[0]->pck_chk_stts != OrdersPickups::CHK_STTS_SUBMIT) { + $apiResp = Responses::bad_input( + 'can\'t generate invoice, checker pickup has not submitted data', + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + // else { + // $apiResp = Responses::bad_input('can\'t generate invoice, order still on going'); + // return new Response($apiResp, $apiResp['meta']['code']); + // } + + DB::beginTransaction(); + + Orders::updateOrder($order[0]->ord_id, [ + "invc_to_client_at" => $now, + "invc_to_client_by" => $req->auth->id, + // 'status' => $updt_stts_order, + "updt" => $now, + "updt_by" => $req->auth->id, + ]); + + DB::commit(); + $apiResp = Responses::success("success generate invoice"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_adm_confirm_client_pay(Request $req) + { + try { + $now = time(); + $input = [ + "ord_id" => $req->ord_id, + "ref_number" => $req->ref_number, + ]; + $rulesInput = [ + "ord_id" => "required|integer|not_in:0", + "ref_number" => "required|string|max:45", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $filter = [ + "id" => $req->ord_id, + "get_stts_checker" => 1, + ]; + $order = Orders::showOrder($filter); + if (count($order) < 1) { + $apiResp = Responses::not_found("order not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $updt_stts_order = $order[0]->status; + if ( + $order[0]->status == Orders::STTS_CLIENT_PAY || + $order[0]->status == Orders::STTS_VENDOR_PAYED + ) { + if ($order[0]->confirm_vdr_pay_at != 0) { + $updt_stts_order = Orders::STTS_CLOSE; + } else { + $updt_stts_order = Orders::STTS_VENDOR_PAYED; + } + } elseif ($order[0]->status == Orders::STTS_CANCEL) { + $apiResp = Responses::bad_input('can\'t confirm payment, order is cancel'); + return new Response($apiResp, $apiResp["meta"]["code"]); + } elseif ($order[0]->status == Orders::STTS_CLOSE) { + $apiResp = Responses::bad_input('can\'t confirm payment, transaction is close'); + return new Response($apiResp, $apiResp["meta"]["code"]); + } elseif ($order[0]->pck_chk_stts != OrdersPickups::CHK_STTS_SUBMIT) { + $apiResp = Responses::bad_input( + 'can\'t confirm payment, checker pickup has not submitted data', + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + // else { + // $apiResp = Responses::bad_input('can\'t confirm payment, order still on going'); + // return new Response($apiResp, $apiResp['meta']['code']); + // } + + DB::beginTransaction(); + + Orders::updateOrder($order[0]->ord_id, [ + "confirm_client_pay_at" => $now, + "confirm_client_pay_by" => $req->auth->id, + "confirm_client_pay_ref_number" => $req->ref_number, + "status" => $updt_stts_order, + "updt" => $now, + "updt_by" => $req->auth->id, + ]); + OrdersClients::updt($order[0]->ord_client_id, [ + "pay_at" => $now, + "is_pay" => OrdersClients::IS_PAYED, + ]); + if ($updt_stts_order === Orders::STTS_CLOSE) { + Vehicles::updateVehicle($order[0]->vhc_id, [ + "is_in_ord" => Vehicles::IN_ORD_NO, + "ord_id" => 0, + "ord_code" => 0, + ]); + } + + DB::commit(); + $apiResp = Responses::success("success confirm payment"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_adm_payout_to_vendor(Request $req) + { + try { + $now = time(); + $input = [ + "ord_id" => $req->ord_id, + ]; + $rulesInput = [ + "ord_id" => "required|integer|not_in:0", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $filter = [ + "id" => $req->ord_id, + "get_stts_checker" => 1, + ]; + $order = Orders::showOrder($filter); + if (count($order) < 1) { + $apiResp = Responses::not_found("order not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $updt_stts_order = $order[0]->status; + if ( + $order[0]->status == Orders::STTS_CLIENT_PAY || + $order[0]->status == Orders::STTS_VENDOR_PAYED + ) { + // $updt_stts_order = Orders::STTS_VENDOR_PAYED; + } elseif ($order[0]->status == Orders::STTS_CANCEL) { + $apiResp = Responses::bad_input('can\'t generate instruction payment, order is cancel'); + return new Response($apiResp, $apiResp["meta"]["code"]); + } elseif ($order[0]->status == Orders::STTS_CLOSE) { + $apiResp = Responses::bad_input('can\'t generate instruction payment, transaction is close'); + return new Response($apiResp, $apiResp["meta"]["code"]); + } elseif ($order[0]->drop_chk_stts != OrdersDrops::CHK_STTS_SUBMIT) { + $apiResp = Responses::bad_input( + 'can\'t generate instruction payment, checker drop has not submitted data', + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + // else { + // $apiResp = Responses::bad_input('can\'t generate instruction payment, order still on going'); + // return new Response($apiResp, $apiResp['meta']['code']); + // } + + DB::beginTransaction(); + + Orders::updateOrder($order[0]->ord_id, [ + "payout_to_vdr_at" => $now, + "payout_to_vdr_by" => $req->auth->id, + // 'status' => $updt_stts_order, + "updt" => $now, + "updt_by" => $req->auth->id, + ]); + + DB::commit(); + $apiResp = Responses::success("success generate instruction payment"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_adm_confirm_vendor_pay(Request $req) + { + try { + $now = time(); + $input = [ + "ord_id" => $req->ord_id, + "ref_number" => $req->ref_number, + ]; + $rulesInput = [ + "ord_id" => "required|integer|not_in:0", + "ref_number" => "required|string|max:45", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $filter = [ + "id" => $req->ord_id, + "get_stts_checker" => 1, + ]; + $order = Orders::showOrder($filter); + if (count($order) < 1) { + $apiResp = Responses::not_found("order not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $updt_stts_order = $order[0]->status; + if ( + $order[0]->status == Orders::STTS_CLIENT_PAY || + $order[0]->status == Orders::STTS_VENDOR_PAYED + ) { + if ($order[0]->confirm_client_pay_at != 0) { + $updt_stts_order = Orders::STTS_CLOSE; + } + } elseif ($order[0]->status == Orders::STTS_CANCEL) { + $apiResp = Responses::bad_input('can\'t confirm payout, order is cancel'); + return new Response($apiResp, $apiResp["meta"]["code"]); + } elseif ($order[0]->status == Orders::STTS_CLOSE) { + $apiResp = Responses::bad_input('can\'t confirm payout, transaction is close'); + return new Response($apiResp, $apiResp["meta"]["code"]); + } elseif ($order[0]->drop_chk_stts != OrdersDrops::CHK_STTS_SUBMIT) { + $apiResp = Responses::bad_input('can\'t confirm payout, checker drop has not submitted data'); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + // else { + // $apiResp = Responses::bad_input('can\'t confirm payout, order still on going'); + // return new Response($apiResp, $apiResp['meta']['code']); + // } + + DB::beginTransaction(); + + Orders::updateOrder($order[0]->ord_id, [ + "confirm_vdr_pay_at" => $now, + "confirm_vdr_pay_by" => $req->auth->id, + "confirm_vdr_pay_ref_number" => $req->ref_number, + "status" => $updt_stts_order, + "updt" => $now, + "updt_by" => $req->auth->id, + ]); + OrdersVendors::updt($order[0]->ord_vdr_id, [ + "pay_at" => $now, + "is_pay" => OrdersVendors::IS_PAYED, + ]); + if ($updt_stts_order === Orders::STTS_CLOSE) { + Vehicles::updateVehicle($order[0]->vhc_id, [ + "is_in_ord" => Vehicles::IN_ORD_NO, + "ord_id" => 0, + "ord_code" => 0, + ]); + } + + DB::commit(); + $apiResp = Responses::success("success confirm payout to vendor"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_delete_order(Request $req, $ord_id) + { + try { + $now = time(); + + $input = [ + "ord_id" => $ord_id, + ]; + $rulesInput = [ + "ord_id" => "required|integer|not_in:0", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $filter = [ + "id" => $ord_id, + ]; + $order = Orders::showOrder($filter); + if (count($order) < 1) { + $apiResp = Responses::not_found("order not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $user = Auth::user(); + + DB::beginTransaction(); + + // soft delete + Orders::updateOrder($order[0]->ord_id, [ + "dlt" => $now, + "dlt_by" => $user->id, + ]); + OrdersAccidents::updateAccidentByOrdId($order[0]->ord_id, [ + "dlt" => $now, + "dlt_by" => $user->id, + ]); + OrdersAItems::updtByOrdId($order[0]->ord_id, [ + "dlt" => $now, + "dlt_by" => $user->id, + ]); + // OrdersClients::updtByOrdId($order[0]->ord_id, ['dlt'=>$now,'dlt_by'=>$user->id]); + // OrdersDrivers::updtByOrdId($order[0]->ord_id, ['dlt'=>$now,'dlt_by'=>$user->id]); + // OrdersDrops::updtByOrdId($order[0]->ord_id, ['dlt'=>$now,'dlt_by'=>$user->id]); + // OrdersInsurances::updtByOrdId($order[0]->ord_id, ['dlt'=>$now,'dlt_by'=>$user->id]); + OrdersInvoices::updtByOrdId($order[0]->ord_id, [ + "dlt" => $now, + "dlt_by" => $user->id, + ]); + // OrdersItems::updtByOrdId($order[0]->ord_id, ['dlt'=>$now,'dlt_by'=>$user->id]); + // OrdersPickups::updtByOrdId($order[0]->ord_id, ['dlt'=>$now,'dlt_by'=>$user->id]); + // OrdersRates::updtByOrdId($order[0]->ord_id, ['dlt'=>$now,'dlt_by'=>$user->id]); + OrdersTermins::updtByOrdId($order[0]->ord_id, [ + "dlt" => $now, + "dlt_by" => $user->id, + ]); + // OrdersVehicles::updtByOrdId($order[0]->ord_id, ['dlt'=>$now,'dlt_by'=>$user->id]); + // OrdersVendors::updtByOrdId($order[0]->ord_id, ['dlt'=>$now,'dlt_by'=>$user->id]); + OrdersPckDrop::updtByOrdId($order[0]->ord_id, [ + "dlt" => $now, + "dlt_by" => $user->id, + ]); + OrdersPockets::updtByOrdId($order[0]->ord_id, [ + "dlt" => $now, + "dlt_by" => $user->id, + ]); + OrdersCheckpoints::updtByOrdId($order[0]->ord_id, [ + "dlt" => $now, + "dlt_by" => $user->id, + ]); + + DB::commit(); + + $apiResp = Responses::success("success delete order"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } +} diff --git a/app/Http/Controllers/TransactionSpcController.php b/app/Http/Controllers/TransactionSpcController.php new file mode 100755 index 0000000..4818923 --- /dev/null +++ b/app/Http/Controllers/TransactionSpcController.php @@ -0,0 +1,1850 @@ +where("id", Auth::user()->id) + ->get(); + + $vehicles = DB::table("t_vehicles as tv") + ->leftJoin("t_users as tu", "tu.id", "tv.vendor_id") + ->where("tu.id", Auth::user()->id) + ->where("tv.status", 1) + ->whereNull("tv.dlt") + ->select("tv.*") + ->groupBy("tv.vendor_id") + ->get(); + + $drivers = DB::table("t_drivers as td") + ->leftJoin("t_users as tu", "tu.id", "td.vendor_id") + ->where("tu.id", Auth::user()->id) + ->where("td.status", 1) + ->where("td.is_in_ord", 2) + ->whereNull("td.dlt") + ->select("td.*") + ->get(); + + // select * from t_zones tz where tz.client_group_id = 21 and tz.workflow_type = 1 and tz.status = 1 + $pickupzone = DB::table("t_zones as tz") // + ->where("tz.client_group_id", Auth::user()->client_id) + ->where("tz.workflow_type", 1) + ->where("tz.status", 1) + ->whereNull("tz.dlt") + ->get(); + + // dd($pickupzone); + $dropzone = DB::table("t_zones as tz") // + ->where("tz.client_group_id", Auth::user()->client_id) + ->where("tz.workflow_type", 2) + ->where("tz.status", 1) + ->whereNull("tz.dlt") + ->get(); + + $checklist = DB::table("t_conf_checklists") + ->where("status", 1) + ->whereNull("dlt") + ->get(); + + $data = [ + "uclients" => Users::listUsers([ + "role" => Users::ROLE_VENDOR, + "status" => Users::STATUS_ACTIVE, + "id" => Auth::user()->id, + ]), + "truck_types" => ConfTruckTypes::listTruckTypes(ConfTruckTypes::IS_ACTIVE, [ + "is_publish" => ConfTruckTypes::IS_PUBLISH, + ]), + "devices" => Devices::listDevices([ + "is_active" => Devices::IS_ACTIVE, + "type" => Devices::TYPE_PORTABLE, + "is_idle_yes" => 1, + "is_available" => Devices::IS_AVAIL, + ]), + "vendors" => $vendors, + "vehicles" => $vehicles, + "drivers" => $drivers, + "pickup_zone" => $pickupzone, + "drop_zone" => $dropzone, + "checklist" => $checklist, + "banks" => Banks::listBanks(["is_active" => Banks::IS_ACTIVE]), + ]; + // dd($data); + return view("menu_v1._addTransactionsSpcMultiple", $data); + // return view('menu_v1._addTransactionsSpcSingle', $data); + } + + /** + * CASE SEMI AUTOMATIC + * Vendor + * phone belum digunakan, email digunakan ? AMAN + * phone digunakan, email belum digunakan ? AMAN + * phone digunakan, emaill digunakan ? AMAN + * Driver + * driver lock on phone1 ? AMAN + * driver in order ? AMAN + * driver phone1 used but from current input its different name driver ? AMAN + * driver ditemukan tapi beda vendor ? + * Vehicle + * device_id used on vhc and nopol same ? + * device_id used on vhc but nopol not same ? AMAN + * device_id not used on any vhc and nopol not used ? AMAN + * device_id not used on any vhc but nopol used ? AMAN + * vehilce ditemukan tapi beda vendor ? + * Rates + * rates yang sama ? AMAN + * Other + * kir_exp / tax_exp not input on DB when new vhc AMAN + * show suggestion beluman + */ + + // multiple + public function api_trx_spc_checkout_v1(Request $req) + { + $vhs = DB::table("t_vehicles as tv") + ->leftJoin("t_vehicles_types as tvt", "tvt.id", "tv.type_id") + ->leftJoin("t_vehicles_detail as tvd", "tvd.vid", "tv.id") + ->where("tv.id", $req->id_kendaraan) + ->select( + "tv.*", + "tvt.id as truck_type_id", + "tvt.name as truck_type_name", + "tvd.tax_exp as vhc_stnk_taxexp", + "tvd.kir_exp as vhc_kir_exp" + ) + ->first(); + $drv = DB::table("t_drivers as td") + ->leftJoin("t_drivers_detail as tdd", "tdd.did", "td.id") + ->where("td.id", $req->id_pengemudi) + ->first(); + // $points = $req->add_pickup_date; + $vdr = DB::table("t_users as tu") + ->leftJoin("t_clients as tc", "tc.id", "tu.client_id") + ->where("tu.id", Auth::user()->id) + ->first(); + // dd($req->all(), $vdr, $vhs, $drv, $points); + // dd($req->all()); + try { + $now = time(); + + $input = [ + "uid" => $req->add_client, + // "points" => $req->points, + // "points" => [1], + "truck_type_id" => $vhs->truck_type_id, + "truck_type_name" => $vhs->truck_type_name, + "is_insurance" => "NO", + "is_client_pkp" => 0, + "amt_beneficiary" => 0, + "vdr_name" => $vdr->c_name, + "vdr_phone" => "+" . $vdr->c_phone_code . $vdr->c_phone, + "vdr_email" => $vdr->c_mail, + "vdr_addr" => $vdr->c_addr_office, + "vdr_bank_id" => 0, + "vdr_bank_code" => 0, + "vdr_bank_short" => "vdr_bank_short", + "vdr_bank_name" => "vdr_bank_name", + "vdr_kcp" => "vdr_kcp", + "vdr_bank_acc_number" => 0, + "vdr_bank_acc_name" => "vdr_bank_acc_name", + "is_vdr_bcng" => 0, + "device_id" => $vhs->device_id, + "vhc_nopol" => $vhs->nopol1 . " " . $vhs->nopol2 . " " . $vhs->nopol3, + "vhc_stnk_taxexp" => $vhs->vhc_stnk_taxexp, + "vhc_kir_exp" => $vhs->vhc_kir_exp, + "drv_name" => $drv->fullname, + "drv_phone" => "+" . $drv->phone_code . $drv->phone, + "drv_phone2" => "+" . $drv->phone2_code . $drv->phone2, + "drv_bank_id" => $drv->bank_id, + "drv_bank_code" => $drv->bank_code, + "drv_bank_name" => $drv->bank_name, + "drv_kcp" => $drv->bank_branch_name, + "drv_bank_acc_number" => $drv->bank_acc_number, + "drv_bank_acc_name" => $drv->bank_acc_name, + "sell_price" => 0, + "buy_price" => 0, + "buy_price_tax_type" => 0, + "buy_price_tax_ppn_percent" => 0, + "buy_price_tax_ppn_flat" => 0, + "buy_price_tax_pph_percent" => 0, + "buy_price_tax_pph_flat" => 0, + "buy_price_total_tax" => 0, + "margin_price" => 0, + "percent_price" => 0, + "lead_time" => 1, + "termin1_amt_type" => 0, + "termin1_amt" => 0, + "termin1_calc_percent" => 0, + "termin1_date" => "$now", + "termin1_time" => "$now", + "termin1_at" => $now, + "termin2_amt_type" => $now, + "termin2_amt" => $now, + "termin2_calc_percent" => $now, + "sell_termin1_amt_type" => $now, + "sell_termin1_amt" => $now, + "sell_termin1_calc_percent" => $now, + "sell_termin1_date" => "$now", + "sell_termin1_time" => "$now", + "sell_termin1_at" => $now, + "sell_termin2_amt_type" => 0, + "sell_termin2_amt" => 0, + "sell_termin2_calc_percent" => 0, + // "pocket_id" => $req->pocket_id, + // "pocket_type" => $req->pocket_type, + // "pocket_checkpoints" => $req->pocket_checkpoints, + ]; + $rulesInput = [ + "uid" => "required|integer|not_in:0", + // "points" => "required|array|min:1", + // "points.*.pickup_at" => "required|integer", + // "points.*.pickup_zone_id" => "required|integer", + // "points.*.pickup_zone_pic_name" => "required|string", + // "points.*.pickup_zone_pic_phone" => "required|numeric", + // "points.*.drop_zone_id" => "required|integer", + // "points.*.drop_zone_pic_name" => "required|string", + // "points.*.drop_zone_pic_phone" => "required|numeric", + "truck_type_id" => "required|integer|not_in:0", + "truck_type_name" => "required|string", + "is_insurance" => "nullable|string", + "is_client_pkp" => "nullable|numeric", + "amt_beneficiary" => "nullable|numeric", + "vdr_name" => "required|string", + "vdr_phone" => "required|numeric", + "vdr_email" => "required|email", + "vdr_addr" => "required|string|min:35", + "vdr_bank_id" => "required|integer", + "vdr_bank_code" => "required|numeric", + "vdr_bank_short" => "required|string", + "vdr_bank_name" => "required|string", + "vdr_kcp" => "required|string", + "vdr_bank_acc_number" => "required|numeric", + "vdr_bank_acc_name" => "required|string|max:255", + "is_vdr_bcng" => "nullable|numeric", + "device_id" => "nullable|numeric", + "vhc_nopol" => "required|string", + "vhc_stnk_taxexp" => "required|date_format:Y-m-d", + "vhc_kir_exp" => "required|date_format:Y-m-d", + "drv_name" => "required|string", + "drv_phone" => "required|numeric", + "drv_phone2" => "nullable|numeric", + "drv_bank_id" => "nullable|numeric", + "drv_bank_code" => "nullable|string", + "drv_bank_name" => "nullable|string", + "drv_kcp" => "nullable|string", + "drv_bank_short_name" => "nullable|string", + "drv_bank_acc_number" => "nullable|string", + "drv_bank_acc_name" => "nullable|string", + "sell_price" => "required|numeric", + "buy_price" => "required|numeric", + "buy_price_tax_type" => "required|numeric", + "buy_price_tax_ppn_percent" => "required|numeric", + "buy_price_tax_ppn_flat" => "required|numeric", + "buy_price_tax_pph_percent" => "required|numeric", + "buy_price_tax_pph_flat" => "required|numeric", + "buy_price_total_tax" => "required|numeric", + "margin_price" => "required|numeric", + "lead_time" => "required|integer|not_in:0", + "termin1_amt_type" => "nullable|numeric", + "termin1_amt" => "nullable|numeric", + "termin1_calc_percent" => "nullable|numeric", + "termin1_date" => "nullable|string", + "termin1_time" => "nullable|string", + "termin1_at" => "nullable|numeric", + "termin2_amt_type" => "nullable|numeric", + "termin2_amt" => "nullable|numeric", + "termin2_calc_percent" => "nullable|numeric", + "sell_termin1_amt_type" => "nullable|numeric", + "sell_termin1_amt" => "nullable|numeric", + "sell_termin1_calc_percent" => "nullable|numeric", + "sell_termin1_date" => "nullable|string", + "sell_termin1_time" => "nullable|string", + "sell_termin1_at" => "nullable|numeric", + "sell_termin2_amt_type" => "nullable|numeric", + "sell_termin2_amt" => "nullable|numeric", + "sell_termin2_calc_percent" => "nullable|numeric", + // "pocket_id" => "nullable|integer", + // "pocket_type" => "nullable|numeric", + // "pocket_checkpoints" => "nullable|array", + ]; + // $req->margin_price = 0; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $pckZids = []; + foreach ($req->add_pickup_zone as $i => $point) { + $pckZids[] = $point; + } + $dropZids = []; + foreach ($req->add_drop_zone as $i => $point) { + $dropZids[] = $point; + } + // dd($pckZids); + + $pcks = Zone::getZoneByIds($pckZids); + // dd($pcks); + if (count($pcks) < 1) { + $apiResp = Responses::bad_request("Lokasi penjemputan tidak ditemukan"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + foreach ($pcks as $i => $pck) { + if ($pck->prid == 0 || $pck->ktid == 0 || $pck->kcid == 0 || $pck->klid == 0) { + $apiResp = Responses::bad_request( + "Zonasi wilayah(provinsi, kecamatan, ...) lokasi penjemputan " . + $pck->name . + " belum lengkap" + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + $drops = Zone::getZoneByIds($dropZids); + if (count($drops) < 1) { + $apiResp = Responses::bad_request("Lokasi pengantaran"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + foreach ($drops as $i => $drop) { + if ($drop->prid == 0 || $drop->ktid == 0 || $drop->kcid == 0 || $drop->klid == 0) { + $apiResp = Responses::bad_request( + "Zonasi wilayah(provinsi, kecamatan, ...) lokasi pengantaran " . + $drop->name . + " belum lengkap" + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + $client = Clients::getClientById($req->auth->client_group_id); + $insurance = StaticInsurances::listStaticInsurances([ + "is_active" => StaticInsurances::IS_ACTIVE, + ]); + + $opts = []; + $opt = [ + "is_best" => 1, + ]; + $opt["lead_time_id"] = 0; + // $center_time = $v->long_time - $v->fast_time; + $opt["lead_time"] = $req->lead_time; // long_time + $price = $req->sell_price ?? 0; + $opt["price"] = $price; + $opt["real_price"] = $price; + $opt["disc_price"] = 0; + $opt["disc_type"] = $client[0]->disc_type; + $opt["disc_percent"] = 0; + if ($client[0]->disc_type === Clients::DISC_TYPE_FIX) { + $opt["disc_price"] = $client[0]->disc_amount; + $opt["price"] = $opt["price"] - $opt["disc_price"]; + } elseif ($client[0]->disc_type === Clients::DISC_TYPE_PERCENT) { + $opt["disc_percent"] = $client[0]->disc_amount; + $opt["disc_price"] = ($opt["price"] * $client[0]->disc_amount) / 100; + $opt["price"] = $opt["price"] - $opt["disc_price"]; + } + array_push($opts, $opt); + + $apiResp = Responses::success("checkout success"); + $apiResp["data"] = $opts; + + if ($req->is_insurance === "true") { + // $insurances = Insurances::getInsurancesByRangeBeneficiaryAndActive($req->amt_beneficiary); + // if (count($insurances) < 1) { + // $apiResp = Responses::bad_request('Total pertangguhan tidak tersedia'); + // return new Response($apiResp, $apiResp['meta']['code']); + // } + // $apiResp['insurance'] = $insurances[0]; + $beneficiary = $req->amt_beneficiary ?? 0; // nilai pertangguhan + $calcPercent = ($beneficiary * $insurance[0]->amt_percent) / 100; + $flatPercent = $beneficiary - $calcPercent; + $apiResp["insurance"] = [ + "premi_price" => $calcPercent, + ]; + } + + // $apiResp["exist_data"] = [ + // "vdr_id" => $existVdrId, + // "drv_id" => $existDrvId, + // "vhc_id" => $existVhcId, + // ]; + // dd($apiResp); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + // multiple + /** + * DONE jangan lupa insert t_pocket, t_checkpoint + * DONE tambahan field t_vendors => is_vdr_bcng + * DONE tambahin field t_zones => boundary_diameter, boundary_area, boundary_ha + * tambahin field t_drivers => bank driver + */ + public function api_trx_spc_create_order_v1(Request $req) + { + $vhs = DB::table("t_vehicles as tv") + ->leftJoin("t_vehicles_types as tvt", "tvt.id", "tv.type_id") + ->leftJoin("t_vehicles_detail as tvd", "tvd.vid", "tv.id") + ->where("tv.id", $req->id_kendaraan) + ->select( + "tv.*", + "tvt.id as truck_type_id", + "tvt.name as truck_type_name", + "tvd.tax_exp as vhc_stnk_taxexp", + "tvd.kir_exp as vhc_kir_exp" + ) + ->first(); + $drv = DB::table("t_drivers as td") + ->leftJoin("t_drivers_detail as tdd", "tdd.did", "td.id") + ->where("td.id", $req->id_pengemudi) + ->select("td.*", "tdd.*", "td.id as id") + ->first(); + + $vdr = DB::table("t_clients as tc") + ->leftJoin("t_users as tu", "tc.id", "tu.client_id") + ->where("tu.id", Auth::user()->id) + ->first(); + try { + $now = time(); + + $input = [ + "uid" => $req->add_client, + // "points" => $req->points, + // "points" => [1], + "truck_type_id" => $vhs->truck_type_id, + "truck_type_name" => $vhs->truck_type_name, + "is_insurance" => "NO", + "is_client_pkp" => 0, + "amt_beneficiary" => 0, + "vdr_id" => $vdr->id, + "vdr_name" => $vdr->c_name, + "vdr_phone" => "+" . $vdr->c_phone_code . $vdr->c_phone, + "vdr_email" => $vdr->c_mail, + "vdr_addr" => $vdr->c_addr_office, + "vdr_bank_id" => 0, + "vdr_bank_code" => 0, + "vdr_bank_short" => "vdr_bank_short", + "vdr_bank_name" => "vdr_bank_name", + "vdr_kcp" => "vdr_kcp", + "vdr_bank_acc_number" => 0, + "vdr_bank_acc_name" => "vdr_bank_acc_name", + "is_vdr_bcng" => 0, + "device_id" => $vhs->device_id, + "vhc_id" => $vhs->id, + "vhc_nopol" => $vhs->nopol1 . " " . $vhs->nopol2 . " " . $vhs->nopol3, + "vhc_stnk_taxexp" => $vhs->vhc_stnk_taxexp, + "vhc_kir_exp" => $vhs->vhc_kir_exp, + "drv_id" => $drv->id, + "drv_name" => $drv->fullname, + "drv_phone" => "+" . $drv->phone_code . $drv->phone, + "drv_phone2" => "+" . $drv->phone2_code . $drv->phone2, + "drv_bank_id" => $drv->bank_id, + "drv_bank_code" => $drv->bank_code, + "drv_bank_name" => $drv->bank_name, + "drv_kcp" => $drv->bank_branch_name, + "drv_bank_acc_number" => $drv->bank_acc_number, + "drv_bank_acc_name" => $drv->bank_acc_name, + "sell_price" => 0, + "buy_price" => 0, + "buy_price_tax_type" => 0, + "buy_price_tax_ppn_percent" => 0, + "buy_price_tax_ppn_flat" => 0, + "buy_price_tax_pph_percent" => 0, + "buy_price_tax_pph_flat" => 0, + "buy_price_total_tax" => 0, + "margin_price" => 0, + "percent_price" => 0, + "lead_time" => 1, + "termin1_amt_type" => 0, + "termin1_amt" => 0, + "termin1_calc_percent" => 0, + "termin1_date" => "$now", + "termin1_time" => "$now", + "termin1_at" => $now, + "termin2_amt_type" => $now, + "termin2_amt" => $now, + "termin2_calc_percent" => $now, + "sell_termin1_amt_type" => $now, + "sell_termin1_amt" => $now, + "sell_termin1_calc_percent" => $now, + "sell_termin1_date" => "$now", + "sell_termin1_time" => "$now", + "sell_termin1_at" => $now, + "sell_termin2_amt_type" => 0, + "sell_termin2_amt" => 0, + "sell_termin2_calc_percent" => 0, + // "pocket_id" => $req->pocket_id, + // "pocket_type" => $req->pocket_type, + // "pocket_checkpoints" => $req->pocket_checkpoints, + ]; + $rulesInput = [ + "uid" => "required|integer|not_in:0", + // "points" => "required|array|min:1", + // "points.*.pickup_at" => "required|integer", + // "points.*.pickup_zone_id" => "required|integer", + // "points.*.pickup_zone_pic_name" => "required|string", + // "points.*.pickup_zone_pic_phone" => "required|numeric", + // "points.*.drop_zone_id" => "required|integer", + // "points.*.drop_zone_pic_name" => "required|string", + // "points.*.drop_zone_pic_phone" => "required|numeric", + "truck_type_id" => "required|integer|not_in:0", + "truck_type_name" => "required|string", + "is_insurance" => "nullable|string", + "is_client_pkp" => "nullable|numeric", + "amt_beneficiary" => "nullable|numeric", + "vdr_id" => "required|numeric", + "vdr_name" => "required|string", + "vdr_phone" => "required|numeric", + "vdr_email" => "required|email", + "vdr_addr" => "required|string|min:35", + // "vdr_bank_id" => "required|integer|not_in:0", + // "vdr_bank_code" => "required|numeric", + // "vdr_bank_short" => "required|string", + // "vdr_bank_name" => "required|string", + // "vdr_kcp" => "required|string", + // "vdr_bank_acc_number" => "required|numeric", + // "vdr_bank_acc_name" => "required|string|max:255", + "is_vdr_bcng" => "nullable|numeric", + "device_id" => "nullable|numeric", + "vhc_id" => "required|numeric", + "vhc_nopol" => "required|string", + "vhc_stnk_taxexp" => "required|date_format:Y-m-d", + "vhc_kir_exp" => "required|date_format:Y-m-d", + "drv_id" => "required|numeric", + "drv_name" => "required|string", + "drv_phone" => "required|numeric", + "drv_phone2" => "nullable|numeric", + "drv_bank_id" => "nullable|numeric", + "drv_bank_code" => "nullable|string", + "drv_bank_name" => "nullable|string", + "drv_kcp" => "nullable|string", + "drv_bank_short_name" => "nullable|string", + "drv_bank_acc_number" => "nullable|string", + "drv_bank_acc_name" => "nullable|string", + "sell_price" => "required|numeric", + "buy_price" => "required|numeric", + "buy_price_tax_type" => "required|numeric", + "buy_price_tax_ppn_percent" => "required|numeric", + "buy_price_tax_ppn_flat" => "required|numeric", + "buy_price_tax_pph_percent" => "required|numeric", + "buy_price_tax_pph_flat" => "required|numeric", + "buy_price_total_tax" => "required|numeric", + "margin_price" => "required|numeric", + // 'margin_price' => 'required', + // 'percent_price' => 'required|numeric', + "lead_time" => "required|integer|not_in:0", + "termin1_amt_type" => "nullable|numeric", + "termin1_amt" => "nullable|numeric", + "termin1_calc_percent" => "nullable|numeric", + "termin1_date" => "nullable|string", + "termin1_time" => "nullable|string", + "termin1_at" => "nullable|numeric", + "termin2_amt_type" => "nullable|numeric", + "termin2_amt" => "nullable|numeric", + "termin2_calc_percent" => "nullable|numeric", + "sell_termin1_amt_type" => "nullable|numeric", + "sell_termin1_amt" => "nullable|numeric", + "sell_termin1_calc_percent" => "nullable|numeric", + "sell_termin1_date" => "nullable|string", + "sell_termin1_time" => "nullable|string", + "sell_termin1_at" => "nullable|numeric", + "sell_termin2_amt_type" => "nullable|numeric", + "sell_termin2_amt" => "nullable|numeric", + "sell_termin2_calc_percent" => "nullable|numeric", + // "pocket_id" => "nullable|integer", + // "pocket_type" => "nullable|numeric", + // "pocket_checkpoints" => "nullable|array", + ]; + // $req->margin_price = 0; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + // dd($isValidInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $clientAuth = Users::getUserById($req->add_client)[0]; + $clientAuth->uid = $clientAuth->id; + // dd($clientAuth); + + $adm_id = $req->auth->uid; + $crt_type_order = Orders::CRT_TYPE_ORDER_ADMIN_SPECIAL; + + $type_truck_name = $req->truck_type_name; + if ($req->truck_type_id && $req->truck_type_id != 0) { + $type_truck_name = $req->truck_type_name; + } else { + $type_truck_name = ""; + $req->truck_type_id = 0; + } + + $vdr_id = (int) $vdr->id; + $vhc_id = (int) $vhs->id; + $drv_id = (int) $drv->id; + $device_id = str_pad($vhs->device_id, Vehicles::MAX_DEVICE_ID, "0", STR_PAD_LEFT); + $req->vhc_nopol = $vhs->nopol1 . " " . $vhs->nopol2 . " " . $vhs->nopol3; + $nopol = explode(" ", strtoupper($req->vhc_nopol)); + // dd($nopol); + if (count($nopol) < 3) { + $apiResp = Responses::bad_input("Nomor polisi kendaraan tidak valid"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + // dd($req->add_pickup_date . " " . $req->add_pickup_time_hour . ":" . $req->add_pickup_time_minute); + $pckZids = []; + $dropZids = []; + $pickupAt = strtotime( + $req->add_pickup_date . + " " . + $req->add_pickup_time_hour . + ":" . + $req->add_pickup_time_minute . + ":00" + ); + // foreach ($req->points as $i => $point) { + // $pckZids[] = $point["pickup_zone_id"]; + // $dropZids[] = $point["drop_zone_id"]; + // $pickupAt[] = $point["pickup_at"]; + // } + foreach ($req->add_pickup_zone as $i => $point) { + $pckZids[] = $point; + } + // foreach ($req->add_pickup_zone as $i => $point) { + // // $pickupAt[] = $point; + // // dd($i); + + // $time = + // $req->add_pickup_date[$i] . + // " " . + // $req->add_pickup_time_hour[$i] . + // ":" . + // $req->add_pickup_time_minute[$i] . + // ":00"; + // $pickupAt[] = strtotime($time); + // } + foreach ($req->add_drop_zone as $i => $point) { + $dropZids[] = $point; + } + $pcks = Zone::getZoneByIds($pckZids); + if (count($pcks) < 1) { + $apiResp = Responses::not_found("Lokasi penjemputan tidak ditemukan"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + if (empty($pcks[0]->boundary_points)) { + $apiResp = Responses::bad_request("Lokasi penjemputan tidak valid"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + $drops = Zone::getZoneByIds($dropZids); + if (count($drops) < 1) { + $apiResp = Responses::not_found("Lokasi pengantaran tidak ditemukan"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + if (empty($drops[0]->boundary_points)) { + $apiResp = Responses::bad_request("Lokasi pengantaran tidak valid"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + $req->points = []; + foreach ($req->add_pickup_zone as $i => $point) { + $pointData = []; + $pointData["pickup_at"] = $pickupAt; + $pointData["pickup_zone_id"] = $pckZids[$i]; + $pointData["pickup_zone_pic_name"] = $req->add_pickup_pic_name[$i]; + $pointData["pickup_zone_pic_phone"] = $req->add_pickup_pic_phone[$i]; + $pointData["drop_zone_id"] = $dropZids[$i]; + $pointData["drop_zone_pic_name"] = $req->add_drop_pic_name[$i]; + $pointData["drop_zone_pic_phone"] = $req->add_drop_pic_phone[$i]; + $req->points[] = $pointData; + } + $pckPoints = []; + $dropPoints = []; + $checklist = []; + foreach ($req->points as $iPoint => $point) { + foreach ($pcks as $iPck => $pck) { + if ($point["pickup_zone_id"] == $pck->id) { + if ($pck->prid == 0 || $pck->ktid == 0 || $pck->kcid == 0 || $pck->klid == 0) { + $apiResp = Responses::bad_request( + "Zonasi wilayah(provinsi, kecamatan, ...) lokasi penjemputan " . + $pck->name . + " belum lengkap" + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + $pcks[$iPck]->inpt_set_pck_at = $req->points[$iPoint]["pickup_at"]; + $pcks[$iPck]->inpt_pic_name = $req->points[$iPoint]["pickup_zone_pic_name"]; + $pcks[$iPck]->inpt_pic_phone_code = 62; + $pcks[$iPck]->inpt_pic_phone_val = + (int) $req->points[$iPoint]["pickup_zone_pic_phone"]; + $pcks[$iPck]->inpt_pic_mail = null; + $pckPoints[$iPoint] = clone $pcks[$iPck]; + } + } + foreach ($drops as $iDrop => $drop) { + if ($point["drop_zone_id"] == $drop->id) { + if ($drop->prid == 0 || $drop->ktid == 0 || $drop->kcid == 0 || $drop->klid == 0) { + $apiResp = Responses::bad_request( + "Zonasi wilayah(provinsi, kecamatan, ...) lokasi pengantaran " . + $drop->name . + " belum lengkap" + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + $drops[$iDrop]->inpt_pic_name = $req->points[$iPoint]["drop_zone_pic_name"]; + $drops[$iDrop]->inpt_pic_phone_code = 62; + $drops[$iDrop]->inpt_pic_phone_val = + (int) $req->points[$iPoint]["drop_zone_pic_phone"]; + $drops[$iDrop]->inpt_pic_mail = null; + $dropPoints[$iPoint] = clone $drops[$iDrop]; + } + } + } + // dd($req->checklist, $pckPoints, $dropPoints); + // $lowestPickupAt = min($pickupAt); + // $longestPickupAt = max($pickupAt); + + $nanoid = new Nanoid(); + + // $ord_code = $nanoid->formattedId('0123456789', 12); + // $doWhile = true; + // do { + // $uniqOrdCode = Orders::getOrderByCode($ord_code); + // if (count($uniqOrdCode) > 0) { + // $ord_code = $nanoid->formattedId('0123456789', 12); + // } else { + // $doWhile = false; + // } + // } while ($doWhile); + if ( + ($req->sell_termin2_amt_type == OrdersTermins::AMT_TYPE_FLAT || + $req->sell_termin2_amt_type == OrdersTermins::AMT_TYPE_PERCENT) && + $req->sell_termin2_amt > 0 + ) { + $ord_code_type = 6; + } else { + if ($req->sell_termin1_at < $req->points[0]["pickup_at"]) { + $ord_code_type = 5; + } else { + $ord_code_type = 7; + } + } + $ord_code = Helper::gnrtOrdCode($ord_code_type); + + $rate_code = $nanoid->formattedId("123456789", 6); + $doWhile = true; + do { + $uniqRateCode = ConfRates::getRateByCode($rate_code); + if (count($uniqRateCode) > 0) { + $rate_code = $nanoid->formattedId("123456789", 6); + } else { + $doWhile = false; + } + } while ($doWhile); + + $client = Clients::getClientById($clientAuth->client_group_id); + + // $rate = ConfRates::getRateById($req->lead_time_id); + // $pck_pic = Clients::getClientById($pckPoints[0]->client_group_id); + // $drop_pic = Clients::getClientById($dropPoints[0]->client_group_id); + $admins = Users::getUsersActiveByRole(Users::ROLE_ADMIN); + $device = Devices::getDeviceByDeviceId($device_id); + if (count($device) < 1 || $device === false) { + $device = []; + $device[0] = new \StdClass(); + $device[0]->id = 0; + $device[0]->name = "-"; + $device[0]->type = Devices::TYPE_BUILT_IN; + $device[0]->simcard_code = 62; + $device[0]->simcard = 0; + } + + $admins_data = []; + foreach ($admins as $k => $v) { + array_push($admins_data, [ + "admin_id" => $v->id, + "admin_name" => $v->first_name, + "admin_phone" => $v->phone_code . " " . implode(" ", str_split($v->phone, 4)), + "admin_mail" => $v->email, + "admin_addr" => "", + ]); + } + + $rate_id = 0; + DB::beginTransaction(); + $vendor = Users::getUserById($vdr->id); + + $buy_price = $req->buy_price_total_tax; + if ($req->buy_price_tax_type == OrdersAItems::AMT_TAX_TYPE_INCLUDE) { + $buy_price = $req->buy_price_base; + } elseif ($req->buy_price_tax_type == OrdersAItems::AMT_TAX_TYPE_EXCLUDE) { + $buy_price = $req->buy_price_total_tax; + } + $insOrd = [ + "code" => $ord_code, + "type" => Orders::TYPE_FCL, + "pck_total" => count($pckPoints), + "drop_total" => count($dropPoints), + "est_lead_time" => 0, + "lead_time" => 0, + "est_price" => 0, + "price" => 0, + "est_real_price" => 0, + "real_price" => 0, + "est_disc_price" => 0, + "disc_price" => 0, + "est_buy_price" => 0, + "buy_price" => 0, + "est_real_buy_price" => 0, + "real_buy_price" => 0, + "est_disc_buy_price" => $req->disc_buy_price ?? 0, + "disc_buy_price" => $req->disc_buy_price ?? 0, + "est_rate_id" => $rate_id, + "rate_id" => $rate_id, + "status" => Orders::STTS_HAVE_GET_VHC, + "crt_type_order" => $crt_type_order, + "crt" => $now, + "crt_by" => Auth::user()->id, + "crt_adm_by" => Auth::user()->id, + "updt" => $now, + "updt_by" => Auth::user()->id, + "confirm_at" => $now, + "confirm_by" => Auth::user()->id, + // 'find_vhc_at' => $now, + // 'find_vhc_by' => $req->auth->id, + ]; + $ord_id = Orders::addOrder($insOrd); + $driver = Drivers::showDriverById($drv_id); + $vehicle = Vehicles::showVehicleById($vhc_id); + if ($device[0]->id > 0) { + Devices::updateDevice($device[0]->id, [ + "is_assigned" => Devices::IS_ASSIGNED, + "is_available" => Devices::IS_UNAVAIL, + ]); + } + $pck_ids = []; + foreach ($pckPoints as $i => $pck) { + $insPck = [ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "set_pck_at" => $pck->inpt_set_pck_at, + "stts_pck" => OrdersPickups::STTS_WAIT, + "pck_id" => $pck->id, + "pck_name" => $pck->name, + "pck_desc" => $pck->desc, + "pck_type" => $pck->type, + "pck_workflow" => $pck->workflow_type, + "pck_shiptocode" => $pck->shiptocode, + "pck_prid" => $pck->prid, + "pck_ktid" => $pck->ktid, + "pck_kcid" => $pck->kcid, + "pck_klid" => $pck->klid, + "pck_addr" => $pck->fulladdress, + "pck_cgroup_id" => $pck->client_group_id, + "pck_cdiv_id" => $pck->client_div_id, + "pck_cgp_id" => $pck->client_gp_id, + "pck_hex_color" => $pck->boundary_hex_color, + "pck_shape" => $pck->boundary_type, + "pck_radius" => $pck->boundary_radius, + "pck_diameter" => $pck->boundary_diameter, + "pck_area" => $pck->boundary_area, + "pck_ha" => $pck->boundary_ha, + "pck_bounds" => $pck->boundary_bounds, + "pck_latlngs" => $pck->boundary_latlngs, + "pck_points" => $pck->boundary_points, + "pic_name" => $pck->inpt_pic_name, + "pic_phone_code" => $pck->inpt_pic_phone_code, + "pic_phone_val" => $pck->inpt_pic_phone_val, + "pic_mail" => $pck->inpt_pic_mail, + // 'pic_name' => $clientAuth->first_name, + // 'pic_phone_code' => $clientAuth->phone_code, + // 'pic_phone_val' => $clientAuth->phone, + // 'pic_mail' => $clientAuth->email, + ]; + $pck_id = OrdersPickups::add($insPck); + $pck_ids[] = $pck_id; + } + + $drop_ids = []; + $pck_drop_ids = []; + foreach ($dropPoints as $i => $drop) { + $insDrop = [ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "stts_drop" => OrdersDrops::STTS_WAIT, + "drop_id" => $drop->id, + "drop_name" => $drop->name, + "drop_desc" => $drop->desc, + "drop_type" => $drop->type, + "drop_workflow" => $drop->workflow_type, + "drop_shiptocode" => $drop->shiptocode, + "drop_prid" => $drop->prid, + "drop_ktid" => $drop->ktid, + "drop_kcid" => $drop->kcid, + "drop_klid" => $drop->klid, + "drop_addr" => $drop->fulladdress, + "drop_cgroup_id" => $drop->client_group_id, + "drop_cdiv_id" => $drop->client_div_id, + "drop_cgp_id" => $drop->client_gp_id, + "drop_hex_color" => $drop->boundary_hex_color, + "drop_shape" => $drop->boundary_type, + "drop_radius" => $drop->boundary_radius, + "drop_diameter" => $drop->boundary_diameter, + "drop_area" => $drop->boundary_area, + "drop_ha" => $drop->boundary_ha, + "drop_bounds" => $drop->boundary_bounds, + "drop_latlngs" => $drop->boundary_latlngs, + "drop_points" => $drop->boundary_points, + "pic_name" => $drop->inpt_pic_name, + "pic_phone_code" => $drop->inpt_pic_phone_code, + "pic_phone_val" => $drop->inpt_pic_phone_val, + "pic_mail" => $drop->inpt_pic_mail, + // 'pic_name' => $clientAuth->first_name, + // 'pic_phone_code' => $clientAuth->phone_code, + // 'pic_phone_val' => $clientAuth->phone, + // 'pic_mail' => $clientAuth->email, + ]; + $drop_id = OrdersDrops::add($insDrop); + $drop_ids[] = $drop_id; + + $pck_drop_id = OrdersPckDrop::add([ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "pck_id" => $pck_ids[$i], + "drop_id" => $drop_ids[$i], + "is_active" => 1, + "stts" => OrdersPckDrop::STTS_DELIVERY_OTW_PICKUP, + "crt" => $now, + "crt_by" => Auth::user()->id, + "updt" => $now, + "updt_by" => Auth::user()->id, + ]); + + foreach ($req->checklist[$i] as $_checklist) { + $checklist = DB::table("t_conf_checklists") + ->where("id", $_checklist) + ->first(); + $dt_insert = [ + "did" => $drv_id, + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "pck_id" => $pck_ids[$i], + "drop_id" => $drop_ids[$i], + "ord_pck_drop_id" => $pck_drop_id, + "checklist_id" => $checklist->id, + "checklist_name" => $checklist->name, + "checklist_desc" => $checklist->desc, + "crt" => $now, + "crt_by" => Auth::user()->id, + "updt" => $now, + "updt_by" => Auth::user()->id, + ]; + $insertChecklist = DB::table("t_orders_drivers_uploads")->insert($dt_insert); + } + } + + $insClient = [ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "c_id" => $clientAuth->uid, + "c_name" => $clientAuth->first_name, + "c_phone_code" => $clientAuth->phone_code, + "c_phone_val" => $clientAuth->phone, + "c_mail" => $clientAuth->email, + "c_addr" => $clientAuth->fulladdress, + "c_disc_type" => $client[0]->disc_type, + "c_disc_amount" => $client[0]->disc_amount, + "c_pt_id" => $client[0]->id, + "c_pt_div_id" => $clientAuth->client_div_id, + "c_pt_gp_id" => $clientAuth->client_gp_id, + "c_pt_name" => $client[0]->c_name, + "c_pt_phone_code" => $client[0]->c_phone_code, + "c_pt_phone_val" => $client[0]->c_phone, + "c_pt_mail" => $client[0]->c_mail, + "c_pt_addr" => $client[0]->c_addr_office, + "c_pt_pic_name" => $client[0]->pic_name, + "c_pt_pic_phone_code" => $client[0]->pic_phone_code, + "c_pt_pic_phone_val" => $client[0]->pic_phone, + "c_pt_pic_mail" => $client[0]->pic_mail, + "c_pt_pic_addr" => null, + "prefer_truck_type" => $req->truck_type_id, + "is_pkp" => 0, + ]; + $ord_client_id = OrdersClients::add($insClient); + + // if ($req->is_vdr_bcng != Users::IS_VDR_BCNG_YES) { + // $insRate = [ + // "ord_id" => $ord_id, + // "ord_code" => $ord_code, + // "rate_id" => $rate_id, + // "rate_code" => $rate_code, + // "origin_prov" => $insRate["origin_prov"], + // "origin_city" => $insRate["origin_city"], + // "origin_district" => $insRate["origin_district"], + // "origin_village" => $insRate["origin_village"], + // "lane" => $insRate["lane"], + // "dest_prov" => $insRate["dest_prov"], + // "dest_city" => $insRate["dest_city"], + // "dest_district" => $insRate["dest_district"], + // "dest_village" => $insRate["dest_village"], + // "fast_time" => $insRate["fast_time"], + // "long_time" => $insRate["long_time"], + // "unit_time" => $insRate["unit_time"], + // "sell_kg" => $insRate["sell_kg"], + // "buy_kg" => $insRate["buy_kg"], + // "margin_kg" => $insRate["margin_kg"], + // "percent_kg" => $insRate["percent_kg"], + // "sell_cbm" => $insRate["sell_cbm"], + // "buy_cbm" => $insRate["buy_cbm"], + // "margin_cbm" => $insRate["margin_cbm"], + // "percent_cbm" => $insRate["percent_cbm"], + // "sell_ftl" => $insRate["sell_ftl"], + // "buy_ftl" => $insRate["buy_ftl"], + // "margin_ftl" => $insRate["margin_ftl"], + // "percent_ftl" => $insRate["percent_ftl"], + // "vdr_id" => $insRate["vdr_id"], + // "vhc_type" => $insRate["vhc_type"], + // "crt_type" => $insRate["crt_type"], + // ]; + // OrdersRates::add($insRate); + // } + + if ($req->is_insurance == "true") { + // if (count($insurance) > 0) { + $insurance = StaticInsurances::listStaticInsurances([ + "is_active" => StaticInsurances::IS_ACTIVE, + ]); + $beneficiary = $req->amt_beneficiary ?? 0; // nilai pertangguhan + $calcPercent = ($beneficiary * $insurance[0]->amt_percent) / 100; + $flatPercent = $beneficiary - $calcPercent; + $insInsurance = [ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "insurance_id" => 0, + "premi_name" => $insurance[0]->desc, + "premi_price" => $calcPercent, + "amt_beneficiary" => $beneficiary, + "amt_percent" => $insurance[0]->amt_percent, + "amt_type" => OrdersInsurances::AMT_TYPE_PERCENT, + "premi_min_price" => $beneficiary, + "premi_max_price" => $beneficiary, + "desc" => $insurance[0]->desc, + ]; + OrdersInsurances::add($insInsurance); + } + + $vdrCompany = Clients::getClientById($vendor[0]->client_group_id); + $insVendors = [ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "vdr_id" => $vendor[0]->id, + "vdr_name" => $vendor[0]->first_name, + "vdr_mail" => $vendor[0]->email, + "vdr_phone_code" => $vendor[0]->phone_code, + "vdr_phone_val" => $vendor[0]->phone, + "vdr_addr" => $vendor[0]->fulladdress, + "vdr_cgroup_id" => $vendor[0]->client_group_id, + "vdr_pt_name" => $vdrCompany[0]->c_name, + "vdr_pt_phone_code" => $vdrCompany[0]->c_phone_code, + "vdr_pt_phone_val" => $vdrCompany[0]->c_phone, + "vdr_pt_mail" => $vdrCompany[0]->c_mail, + "vdr_pt_addr" => $vdrCompany[0]->c_addr_office, + "vdr_pt_pic_name" => $vdrCompany[0]->pic_name, + "vdr_pt_pic_phone_code" => $vdrCompany[0]->pic_phone_code, + "vdr_pt_pic_phone_val" => $vdrCompany[0]->pic_phone, + "vdr_pt_pic_mail" => $vdrCompany[0]->pic_mail, + "vdr_bank_id" => $vendor[0]->bank_id, + "vdr_bank_code" => $vendor[0]->bank_code, + "vdr_bank_short_name" => $vendor[0]->bank_short_name, + "vdr_bank_name" => $vendor[0]->bank_name, + "vdr_bank_branch_name" => $vendor[0]->bank_branch_name, + "vdr_bank_acc_number" => $vendor[0]->bank_acc_number, + "vdr_bank_acc_name" => $vendor[0]->bank_acc_name, + "is_vdr_bcng" => 0, + "find_vhcs" => $vhc_id, + "find_radius" => 0, + "find_shape" => Zone::ZONE_BOUNDARY_CIRCLE, + "find_center_lat" => 0, + "find_center_lng" => 0, + "distance" => 0, + "is_exp" => OrdersVendors::LINK_NOT_EXP, + "exp_at" => 0, // strtotime('+10 minutes', $now), // strtotime('+1 day', $now) + "bid_token" => (new Nanoid())->generateId(36), + "is_mailing_bid" => OrdersVendors::IS_MAILING_BID_NOT, + "is_mailing_bid_at" => 0, + "is_want" => OrdersVendors::IS_WANT_YES, + "is_want_at" => $now, + "status" => OrdersVendors::STTS_ACC, + "respond_at" => $now, + "is_pkp" => 0, + "crt" => $now, + ]; + OrdersVendors::add($insVendors); + + OrdersDrivers::add([ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "vdr_id" => $driver[0]->vendor_id, + "drv_id" => $driver[0]->id, + "drv_name" => $driver[0]->fullname, + "drv_mail" => $driver[0]->email, + "drv_name2" => $driver[0]->fullname2, + "drv_phone_code" => $driver[0]->phone_code, + "drv_phone_val" => $driver[0]->phone, + "drv_phone2_code" => $driver[0]->phone2_code, + "drv_phone2_val" => $driver[0]->phone2, + "drv_addr" => $driver[0]->fulladdress, + "drv_cgroup_id" => $driver[0]->client_group_id, + "drv_nik" => $driver[0]->nik, + "drv_dob" => $driver[0]->dob, + "drv_age" => Helper::countAge($driver[0]->dob), + "drv_gender" => $driver[0]->gender, + "drv_blood" => $driver[0]->blood, + "em_fullname" => $driver[0]->em_fullname, + "em_phone_code" => $driver[0]->em_phone_code, + "em_phone_val" => $driver[0]->em_phone, + "em_relationship" => $driver[0]->em_relationship, + "drv_ktp_img" => $driver[0]->ktp_img, + "drv_npwp_img" => $driver[0]->npwp_img, + "drv_npwp_number" => $driver[0]->npwp_number, + "drv_npwp_string" => $driver[0]->npwp_string, + "drv_license_img" => $driver[0]->license_img, + "drv_license_number" => $driver[0]->license_number, + "drv_license_exp" => $driver[0]->license_exp, + "drv_bank_id" => $req->drv_bank_id ?? 0, + "drv_bank_code" => $req->drv_bank_code ?? null, + "drv_bank_short_name" => $req->drv_bank_short ?? null, + "drv_bank_name" => $req->drv_bank_name ?? null, + "drv_bank_branch_name" => $req->drv_bank_branch_name ?? null, + "drv_bank_acc_number" => $req->drv_bank_acc_number ?? null, + "drv_bank_acc_name" => $req->drv_bank_acc_name ?? null, + ]); + OrdersVehicles::add([ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "vhc_id" => $vehicle[0]->vid, + "vhc_name" => $vehicle[0]->name, + "vhc_dvc_id" => $device[0]->id, + "vhc_dvc_name" => $device[0]->name, + "vhc_dvc_type" => $device[0]->type, + "vhc_device_id" => $vehicle[0]->device_id, + "vhc_simcard_code" => $device[0]->simcard_code, + "vhc_simcard" => $device[0]->simcard, + "vhc_cat_id" => $vehicle[0]->cat_id, + "vhc_brand_id" => $vehicle[0]->brand_id, + "vhc_type_id" => $vehicle[0]->type_id, + "vhc_model_id" => $vehicle[0]->model_id, + "vhc_c_did" => $vehicle[0]->c_did, + "vhc_a_did" => $vehicle[0]->a_did, + "vhc_nopol1" => $vehicle[0]->nopol1, + "vhc_nopol2" => $vehicle[0]->nopol2, + "vhc_nopol3" => $vehicle[0]->nopol3, + "vhc_is_track_holiday" => $vehicle[0]->is_track_holiday, + "vhc_track_sch_d" => $vehicle[0]->track_sch_d, + "vhc_track_sch_h" => $vehicle[0]->track_sch_h, + "vhc_cgroup_id" => $vehicle[0]->client_group_id, + "vhc_vdr_id" => $vehicle[0]->vendor_id, + "vhc_speed_limit" => $vehicle[0]->speed_limit, + "vhc_fuel_capacity" => $vehicle[0]->fuel_capacity, + "vhc_fuel_drop_treshold" => $vehicle[0]->fuel_drop_treshold, + "vhc_max_pressure" => $vehicle[0]->max_pressure, + "vhc_fvhc_img" => $vehicle[0]->fvhc_img, + "vhc_stnk_img" => $vehicle[0]->stnk_img, + "vhc_stnk_exp" => $vehicle[0]->stnk_exp, + "vhc_vyear" => $vehicle[0]->vyear, + "vhc_cc" => $vehicle[0]->cc, + "vhc_vin" => $vehicle[0]->vin, + "vhc_en" => $vehicle[0]->en, + "vhc_vcolor" => $vehicle[0]->vcolor, + "vhc_fuel_type" => $vehicle[0]->fuel_type, + "vhc_tnkb_color" => $vehicle[0]->tnkb_color, + "vhc_regis_year" => $vehicle[0]->regis_year, + "vhc_tax_exp" => $vehicle[0]->tax_exp, + ]); + + if ($req->is_vdr_bcng == Users::IS_VDR_BCNG_YES) { + // $req->pocket_id + // $req->pocket_type + // $req->pocket_checkpoints + $pocket = PocketMoney::showPocketById($req->pocket_id); + if (count($pocket) < 1) { + $apiResp = Responses::not_found("uang saku belum dipilih"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + $ord_pocket_id = OrdersPockets::addPocket([ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "pocket_id" => $pocket[0]->id, + "pocket_code" => $pocket[0]->code, + "pocket_name" => $pocket[0]->name, + "pck_id" => $pocket[0]->pck_id, + "drop_id" => $pocket[0]->drop_id, + "pocket_type" => $pocket[0]->type, + "pocket_flow" => $pocket[0]->flow, + "pocket_is_active" => $pocket[0]->is_active, + "pocket_total" => $pocket[0]->total, + "crt" => $now, + "crt_by" => $req->auth->uid, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]); + // order_pocket_id + $pocket[0]->checkpoints = Checkpoints::listCheckpoints([ + "pocket_id" => $pocket[0]->id, + ]); + foreach ($pocket[0]->checkpoints as $checkpoint) { + OrdersCheckpoints::addCheckpoint([ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "ord_pocket_id" => $ord_pocket_id, + "pocket_id" => $checkpoint->pocket_id, + "pck_id" => $checkpoint->pck_id, + "drop_id" => $checkpoint->drop_id, + "pocket_sort" => $checkpoint->sort, + "pocket_fee" => $checkpoint->pocket_fee, + "pocket_tol_fee" => $checkpoint->tol_fee, + "pocket_fuel_fee" => $checkpoint->fuel_fee, + "pocket_total" => $checkpoint->total, + "crt" => $now, + "crt_by" => $req->auth->uid, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]); + } + } + $main_item_dec = ""; + // $main_item_dec = + // "Pengantaran Logistik
" . + // ucwords(strtolower($pckPoints[0]->prid_name)) . + // " - " . + // ucwords(strtolower($dropPoints[0]->prid_name)) . + // "
" . + // date("d F Y", $insPck["set_pck_at"]); + // $main_item_dec = + // "Pengantaran Logistik
" . + // ucwords(strtolower($pckPoints[0]->prid_name)) . + // " - " . + // ucwords(strtolower($dropPoints[0]->prid_name)) . + // "
" . + // strftime("%d %B %Y", $insPck["set_pck_at"]); + // $main_item_dec = + // "Pengantaran Logistik
" . + // ucwords(strtolower($pckPoints[0]->ktid_name)) . + // " - " . + // ucwords(strtolower($dropPoints[0]->ktid_name)) . + // "
" . + // ucwords(strtolower($dropPoints[0]->name)) . + // ", " . + // ucwords(strtolower($dropPoints[0]->prid_name)) . + // " - " . + // $dropPoints[0]->shiptocode . + // "
" . + // strftime("%d %m %Y", $insPck["set_pck_at"]) . + // "
" . + // $req->note_tonase; + + if ($req->is_vdr_bcng == Users::IS_VDR_BCNG_YES) { + $req->termin1_amt_type = OrdersTermins::AMT_TYPE_PERCENT; + $req->buy_price = 0; + $req->buy_price_tax_type = 0; + $req->buy_price_tax_ppn_percent = 0; + $req->buy_price_tax_ppn_flat = 0; + $req->buy_price_tax_pph_percent = 0; + $req->buy_price_tax_pph_flat = 0; + $req->buy_price_total_tax = 0; + $req->termin1_amt = 0; + $req->termin1_calc_percent = 0; + $req->termin1_at = 0; + $req->termin1_calc_percent_base = 0; + } + + $v_termin_sequence = 0; + $v_termin1_id = 0; + $v_termin2_id = 0; + + if ( + $req->termin1_amt_type == OrdersTermins::AMT_TYPE_FLAT || + $req->termin1_amt_type == OrdersTermins::AMT_TYPE_PERCENT + ) { + ++$v_termin_sequence; + $insTerminsVdr1 = [ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "flow_type" => OrdersTermins::FLOW_TYPE_PAYMENT, + "cash_type" => OrdersTermins::TYPE_CASH_OUT, + "sequence" => $v_termin_sequence, + "termin_base_flat" => $req->buy_price, + "termin_tax_type" => $req->buy_price_tax_type, + "termin_tax_ppn_percent" => $req->buy_price_tax_ppn_percent ?? 0, + "termin_tax_ppn_flat" => $req->buy_price_tax_ppn_flat ?? 0, + "termin_tax_pph_percent" => $req->buy_price_tax_pph_percent ?? 0, + "termin_tax_pph_flat" => $req->buy_price_tax_pph_flat ?? 0, + "termin_total_tax_flat" => $req->buy_price_total_tax ?? 0, + "termin_amt_type" => $req->termin1_amt_type ?? 0, + "termin_amt" => $req->termin1_amt ?? 0, + "termin_calc_percent" => $req->termin1_calc_percent ?? 0, + "termin_result_flat" => + $req->termin1_amt_type == OrdersTermins::AMT_TYPE_FLAT + ? $req->termin1_amt + : $req->termin1_calc_percent, + "termin_ddln_at" => $req->termin1_at ?? 0, + "termin_ddln_type" => OrdersTermins::DDLN_TERMIN_TYPE_TIME, + "termin_for" => OrdersTermins::TERMIN_FOR_VENDOR, + "crt" => $now, + "crt_by" => $req->auth->uid, + "crt_type" => OrdersTermins::CRT_TYPE_ADMIN, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]; + // dd($insTerminsVdr1); + $v_termin1_id = OrdersTermins::add($insTerminsVdr1); + $qty = 1; + $amt_base_flat = + $req->termin1_amt_type == OrdersTermins::AMT_TYPE_FLAT + ? $req->termin1_amt + : $req->termin1_calc_percent_base; + $yang_dijadiin_summary = $insTerminsVdr1["termin_result_flat"]; + if ($req->buy_price_tax_type == OrdersAItems::AMT_TAX_TYPE_INCLUDE) { + // $yang_dijadiin_summary = $amt_base_flat; + $yang_dijadiin_summary = $insTerminsVdr1["termin_result_flat"]; + } elseif ($req->buy_price_tax_type == OrdersAItems::AMT_TAX_TYPE_EXCLUDE) { + $yang_dijadiin_summary = $insTerminsVdr1["termin_result_flat"]; + } + OrdersAItems::add([ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "flow_type" => OrdersAItems::FLOW_TYPE_PAYMENT, + "cash_type" => OrdersAItems::TYPE_CASH_OUT, + "v_termin_id" => $v_termin1_id, + "a_item_type" => OrdersAItems::A_TYPE_PRIMARY, + // 'desc' => $main_item_dec . "
Pembayaran termin 1", + "desc" => $main_item_dec, + "unit_id" => 0, + "unit_type" => UnitTypes::UNIT_TYPE_PAKET, + "unit_qty" => $qty, + "amt_base_flat" => $amt_base_flat, + "amt_tax_type" => $req->buy_price_tax_type, + "amt_tax_ppn_percent" => $req->buy_price_tax_ppn_percent ?? 0, + "amt_tax_ppn_flat" => $req->buy_price_tax_ppn_flat ?? 0, + "amt_tax_pph_percent" => $req->buy_price_tax_pph_percent ?? 0, + "amt_tax_pph_flat" => $req->buy_price_tax_pph_flat ?? 0, + "amt_total_tax_flat" => $insTerminsVdr1["termin_result_flat"], + "amt_result_flat" => $insTerminsVdr1["termin_result_flat"], + "amt_total_flat" => $yang_dijadiin_summary * $qty, + "ddln_pay_at" => $insTerminsVdr1["termin_ddln_at"], + "ddln_pay_type" => OrdersAItems::DDLN_PAY_TYPE_TIME, + "img_proof_submission" => null, + "img_proof_payment" => null, + "bank_id" => $insVendors["vdr_bank_id"], + "bank_code" => $insVendors["vdr_bank_code"], + "bank_name" => $insVendors["vdr_bank_name"], + "bank_short_name" => $insVendors["vdr_bank_short_name"], + "bank_acc_number" => $insVendors["vdr_bank_acc_number"], + "bank_acc_name" => $insVendors["vdr_bank_acc_name"], + "invc_to_client" => OrdersAItems::INVC_TO_CLIENT_NO, + "calc_to_vdr" => OrdersAItems::CALC_TO_VDR_YES, + "only_vdr" => OrdersAItems::ONLY_VDR_YES, + "ref_ord_id" => $ord_id, + "ref_ord_code" => $ord_code, + "ref_v_termin_id" => $v_termin1_id, + "crt" => $now, + "crt_by" => $req->auth->uid, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]); + } + if ( + ($req->termin2_amt_type == OrdersTermins::AMT_TYPE_FLAT || + $req->termin2_amt_type == OrdersTermins::AMT_TYPE_PERCENT) && + $req->termin2_amt > 0 + ) { + ++$v_termin_sequence; + $insTerminsVdr2 = [ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "flow_type" => OrdersTermins::FLOW_TYPE_PAYMENT, + "cash_type" => OrdersTermins::TYPE_CASH_OUT, + "sequence" => $v_termin_sequence, + "termin_base_flat" => $req->buy_price, + "termin_tax_type" => $req->buy_price_tax_type, + "termin_tax_ppn_percent" => $req->buy_price_tax_ppn_percent ?? 0, + "termin_tax_ppn_flat" => $req->buy_price_tax_ppn_flat ?? 0, + "termin_tax_pph_percent" => $req->buy_price_tax_pph_percent ?? 0, + "termin_tax_pph_flat" => $req->buy_price_tax_pph_flat ?? 0, + "termin_total_tax_flat" => $req->buy_price_total_tax ?? 0, + "termin_amt_type" => $req->termin2_amt_type ?? 0, + "termin_amt" => $req->termin2_amt ?? 0, + "termin_calc_percent" => $req->termin2_calc_percent ?? 0, + "termin_result_flat" => + $req->termin2_amt_type == OrdersTermins::AMT_TYPE_FLAT + ? $req->termin2_amt + : $req->termin2_calc_percent, + "termin_ddln_at" => $req->termin2_at ?? 0, + "termin_ddln_type" => OrdersTermins::DDLN_TERMIN_TYPE_ORD_FINISH, + "termin_for" => OrdersTermins::TERMIN_FOR_VENDOR, + "crt" => $now, + "crt_by" => $req->auth->uid, + "crt_type" => OrdersTermins::CRT_TYPE_ADMIN, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]; + $v_termin2_id = OrdersTermins::add($insTerminsVdr2); + $qty = 1; + $amt_base_flat = + $req->termin2_amt_type == OrdersTermins::AMT_TYPE_FLAT + ? $req->termin2_amt + : $req->termin2_calc_percent_base; + $yang_dijadiin_summary = $insTerminsVdr2["termin_result_flat"]; + if ($req->buy_price_tax_type == OrdersAItems::AMT_TAX_TYPE_INCLUDE) { + // $yang_dijadiin_summary = $amt_base_flat; + $yang_dijadiin_summary = $insTerminsVdr2["termin_result_flat"]; + } elseif ($req->buy_price_tax_type == OrdersAItems::AMT_TAX_TYPE_EXCLUDE) { + $yang_dijadiin_summary = $insTerminsVdr2["termin_result_flat"]; + } + OrdersAItems::add([ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "flow_type" => OrdersAItems::FLOW_TYPE_PAYMENT, + "cash_type" => OrdersAItems::TYPE_CASH_OUT, + "v_termin_id" => $v_termin2_id, + "a_item_type" => OrdersAItems::A_TYPE_PRIMARY, + // 'desc' => $main_item_dec . "
Pembayaran termin 2", + "desc" => $main_item_dec, + "unit_id" => 0, + "unit_type" => UnitTypes::UNIT_TYPE_PAKET, + "unit_qty" => $qty, + "amt_base_flat" => $amt_base_flat, + "amt_tax_type" => $req->buy_price_tax_type, + "amt_tax_ppn_percent" => $req->buy_price_tax_ppn_percent ?? 0, + "amt_tax_ppn_flat" => $req->buy_price_tax_ppn_flat ?? 0, + "amt_tax_pph_percent" => $req->buy_price_tax_pph_percent ?? 0, + "amt_tax_pph_flat" => $req->buy_price_tax_pph_flat ?? 0, + "amt_total_tax_flat" => $insTerminsVdr2["termin_result_flat"], + "amt_result_flat" => $insTerminsVdr2["termin_result_flat"], + "amt_total_flat" => $yang_dijadiin_summary * $qty, + "ddln_pay_at" => $insTerminsVdr2["termin_ddln_at"], + "ddln_pay_type" => OrdersAItems::DDLN_PAY_TYPE_ORD_FINISH, + "img_proof_submission" => null, + "img_proof_payment" => null, + "bank_id" => $insVendors["vdr_bank_id"], + "bank_code" => $insVendors["vdr_bank_code"], + "bank_name" => $insVendors["vdr_bank_name"], + "bank_short_name" => $insVendors["vdr_bank_short_name"], + "bank_acc_number" => $insVendors["vdr_bank_acc_number"], + "bank_acc_name" => $insVendors["vdr_bank_acc_name"], + "invc_to_client" => OrdersAItems::INVC_TO_CLIENT_NO, + "calc_to_vdr" => OrdersAItems::CALC_TO_VDR_YES, + "only_vdr" => OrdersAItems::ONLY_VDR_YES, + "ref_ord_id" => $ord_id, + "ref_ord_code" => $ord_code, + "ref_v_termin_id" => $v_termin2_id, + "crt" => $now, + "crt_by" => $req->auth->uid, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]); + } + if ($v_termin_sequence === 0) { + $req->termin1_amt_type = OrdersTermins::AMT_TYPE_FLAT; + $req->termin1_amt = $req->buy_price; + $req->termin1_amt_at = strtotime("+2 days", $now); + $req->termin1_calc_percent = 0; + ++$v_termin_sequence; + $insTerminsVdr1 = [ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "flow_type" => OrdersTermins::FLOW_TYPE_PAYMENT, + "cash_type" => OrdersTermins::TYPE_CASH_OUT, + "sequence" => $v_termin_sequence, + "termin_base_flat" => $req->buy_price, + "termin_tax_type" => $req->buy_price_tax_type, + "termin_tax_ppn_percent" => $req->buy_price_tax_ppn_percent ?? 0, + "termin_tax_ppn_flat" => $req->buy_price_tax_ppn_flat ?? 0, + "termin_tax_pph_percent" => $req->buy_price_tax_pph_percent ?? 0, + "termin_tax_pph_flat" => $req->buy_price_tax_pph_flat ?? 0, + "termin_total_tax_flat" => $req->buy_price_total_tax ?? 0, + "termin_amt_type" => $req->termin1_amt_type ?? 0, + "termin_amt" => $req->termin1_amt ?? 0, + "termin_calc_percent" => $req->termin1_calc_percent ?? 0, + "termin_result_flat" => + $req->termin1_amt_type == OrdersTermins::AMT_TYPE_FLAT + ? $req->termin1_amt + : $req->termin1_calc_percent, + "termin_ddln_at" => $req->termin1_at ?? 0, + "termin_ddln_type" => OrdersTermins::DDLN_TERMIN_TYPE_ORD_FINISH, + "termin_for" => OrdersTermins::TERMIN_FOR_VENDOR, + "crt" => $now, + "crt_by" => $req->auth->uid, + "crt_type" => OrdersTermins::CRT_TYPE_ADMIN, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]; + $v_termin1_id = OrdersTermins::add($insTerminsVdr1); + $qty = 1; + $amt_base_flat = + $req->termin1_amt_type == OrdersTermins::AMT_TYPE_FLAT + ? $req->termin1_amt + : $req->termin1_calc_percent_base; + $yang_dijadiin_summary = $insTerminsVdr1["termin_result_flat"]; + if ($req->buy_price_tax_type == OrdersAItems::AMT_TAX_TYPE_INCLUDE) { + // $yang_dijadiin_summary = $amt_base_flat; + $yang_dijadiin_summary = $insTerminsVdr1["termin_result_flat"]; + } elseif ($req->buy_price_tax_type == OrdersAItems::AMT_TAX_TYPE_EXCLUDE) { + $yang_dijadiin_summary = $insTerminsVdr1["termin_result_flat"]; + } + OrdersAItems::add([ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "flow_type" => OrdersAItems::FLOW_TYPE_PAYMENT, + "cash_type" => OrdersAItems::TYPE_CASH_OUT, + "v_termin_id" => $v_termin1_id, + "a_item_type" => OrdersAItems::A_TYPE_PRIMARY, + // 'desc' => $main_item_dec . "
Pembayaran termin 1", + "desc" => $main_item_dec, + "unit_id" => 0, + "unit_type" => UnitTypes::UNIT_TYPE_PAKET, + "unit_qty" => $qty, + "amt_base_flat" => $amt_base_flat, + "amt_tax_type" => $req->buy_price_tax_type, + "amt_tax_ppn_percent" => $req->buy_price_tax_ppn_percent ?? 0, + "amt_tax_ppn_flat" => $req->buy_price_tax_ppn_flat ?? 0, + "amt_tax_pph_percent" => $req->buy_price_tax_pph_percent ?? 0, + "amt_tax_pph_flat" => $req->buy_price_tax_pph_flat ?? 0, + "amt_total_tax_flat" => $insTerminsVdr1["termin_result_flat"], + "amt_result_flat" => $insTerminsVdr1["termin_result_flat"], + "amt_total_flat" => $yang_dijadiin_summary * $qty, + "ddln_pay_at" => $insTerminsVdr1["termin_ddln_at"], + "ddln_pay_type" => OrdersAItems::DDLN_PAY_TYPE_ORD_FINISH, + "img_proof_submission" => null, + "img_proof_payment" => null, + "bank_id" => $insVendors["vdr_bank_id"], + "bank_code" => $insVendors["vdr_bank_code"], + "bank_name" => $insVendors["vdr_bank_name"], + "bank_short_name" => $insVendors["vdr_bank_short_name"], + "bank_acc_number" => $insVendors["vdr_bank_acc_number"], + "bank_acc_name" => $insVendors["vdr_bank_acc_name"], + "invc_to_client" => OrdersAItems::INVC_TO_CLIENT_NO, + "calc_to_vdr" => OrdersAItems::CALC_TO_VDR_YES, + "only_vdr" => OrdersAItems::ONLY_VDR_YES, + "ref_ord_id" => $ord_id, + "ref_ord_code" => $ord_code, + "ref_v_termin_id" => $v_termin1_id, + "crt" => $now, + "crt_by" => $req->auth->uid, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]); + } + + $c_termin_sequence = 0; + $c_termin1_id = 0; + $c_termin2_id = 0; + if ( + $req->sell_termin1_amt_type == OrdersTermins::AMT_TYPE_FLAT || + $req->sell_termin1_amt_type == OrdersTermins::AMT_TYPE_PERCENT + ) { + ++$c_termin_sequence; + $insTerminsC1 = [ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "flow_type" => OrdersTermins::FLOW_TYPE_BILLING, + "cash_type" => OrdersTermins::TYPE_CASH_IN, + "sequence" => $c_termin_sequence, + "termin_base_flat" => $req->sell_price, + "termin_tax_type" => OrdersAItems::AMT_TAX_TYPE_EXCLUDE, + "termin_tax_ppn_percent" => OrdersAItems::PPN_PERCENT, + "termin_tax_pph_percent" => OrdersAItems::PPH_PERCENT, + "termin_amt_type" => $req->sell_termin1_amt_type ?? 0, + "termin_amt" => $req->sell_termin1_amt ?? 0, + "termin_calc_percent" => $req->sell_termin1_calc_percent ?? 0, + "termin_result_flat" => + $req->sell_termin1_amt_type == OrdersTermins::AMT_TYPE_FLAT + ? $req->sell_termin1_amt + : $req->sell_termin1_calc_percent, + "termin_ddln_at" => $req->sell_termin1_at ?? 0, + "termin_ddln_type" => OrdersTermins::DDLN_TERMIN_TYPE_TIME, + "termin_for" => OrdersTermins::TERMIN_FOR_CLIENT, + "crt" => $now, + "crt_by" => $req->auth->uid, + "crt_type" => OrdersTermins::CRT_TYPE_ADMIN, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]; + $c_termin1_id = OrdersTermins::add($insTerminsC1); + $qty = 1; + OrdersAItems::add([ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "flow_type" => OrdersAItems::FLOW_TYPE_BILLING, + "cash_type" => OrdersAItems::TYPE_CASH_IN, + "c_termin_id" => $c_termin1_id, + "a_item_type" => OrdersAItems::A_TYPE_PRIMARY, + // 'desc' => $main_item_dec . "
Pembayaran termin 1", + "desc" => $main_item_dec, + "unit_id" => 0, + "unit_type" => UnitTypes::UNIT_TYPE_PAKET, + "unit_qty" => $qty, + "amt_bill_base_flat" => $insTerminsC1["termin_result_flat"], + "amt_bill_result_flat" => $insTerminsC1["termin_result_flat"], + "amt_bill_total_flat" => $insTerminsC1["termin_result_flat"] * $qty, + "ddln_pay_at" => $insTerminsC1["termin_ddln_at"], + "ddln_pay_type" => OrdersAItems::DDLN_PAY_TYPE_TIME, + "img_proof_submission" => null, + "img_proof_payment" => null, + "bank_id" => Banks::DFT_BANK_ID, + "bank_code" => Banks::DFT_BANK_CODE, + "bank_name" => Banks::DFT_BANK_NAME, + "bank_short_name" => Banks::DFT_BANK_SHORT_NAME, + "bank_acc_number" => Banks::DFT_BANK_ACC_NUMBER, + "bank_acc_name" => Banks::DFT_BANK_ACC_NAME, + "invc_to_client" => OrdersAItems::INVC_TO_CLIENT_YES, + "calc_to_vdr" => OrdersAItems::CALC_TO_VDR_NO, + "only_client" => OrdersAItems::ONLY_CLIENT_YES, + "ref_ord_id" => $ord_id, + "ref_ord_code" => $ord_code, + "ref_c_termin_id" => $c_termin1_id, + "crt" => $now, + "crt_by" => $req->auth->uid, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]); + } + if ( + ($req->sell_termin2_amt_type == OrdersTermins::AMT_TYPE_FLAT || + $req->sell_termin2_amt_type == OrdersTermins::AMT_TYPE_PERCENT) && + $req->sell_termin2_amt > 0 + ) { + ++$c_termin_sequence; + $insTerminsC2 = [ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "flow_type" => OrdersTermins::FLOW_TYPE_BILLING, + "cash_type" => OrdersTermins::TYPE_CASH_IN, + "sequence" => $c_termin_sequence, + "termin_base_flat" => $req->sell_price, + "termin_tax_type" => OrdersAItems::AMT_TAX_TYPE_EXCLUDE, + "termin_tax_ppn_percent" => OrdersAItems::PPN_PERCENT, + "termin_tax_pph_percent" => OrdersAItems::PPH_PERCENT, + "termin_amt_type" => $req->sell_termin2_amt_type ?? 0, + "termin_amt" => $req->sell_termin2_amt ?? 0, + "termin_calc_percent" => $req->sell_termin2_calc_percent ?? 0, + "termin_result_flat" => + $req->sell_termin2_amt_type == OrdersTermins::AMT_TYPE_FLAT + ? $req->sell_termin2_amt + : $req->sell_termin2_calc_percent, + "termin_ddln_at" => $req->sell_termin2_at ?? 0, + "termin_ddln_type" => OrdersTermins::DDLN_TERMIN_TYPE_ORD_FINISH, + "termin_for" => OrdersTermins::TERMIN_FOR_CLIENT, + "crt" => $now, + "crt_by" => $req->auth->uid, + "crt_type" => OrdersTermins::CRT_TYPE_ADMIN, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]; + $c_termin2_id = OrdersTermins::add($insTerminsC2); + $qty = 1; + OrdersAItems::add([ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "flow_type" => OrdersAItems::FLOW_TYPE_BILLING, + "cash_type" => OrdersAItems::TYPE_CASH_IN, + "c_termin_id" => $c_termin2_id, + "a_item_type" => OrdersAItems::A_TYPE_PRIMARY, + // 'desc' => $main_item_dec . "
Pembayaran termin 2", + "desc" => $main_item_dec, + "unit_id" => 0, + "unit_type" => UnitTypes::UNIT_TYPE_PAKET, + "unit_qty" => $qty, + "amt_bill_base_flat" => $insTerminsC2["termin_result_flat"], + "amt_bill_result_flat" => $insTerminsC2["termin_result_flat"], + "amt_bill_total_flat" => $insTerminsC2["termin_result_flat"] * $qty, + "ddln_pay_at" => $insTerminsC2["termin_ddln_at"], + "ddln_pay_type" => OrdersAItems::DDLN_PAY_TYPE_ORD_FINISH, + "img_proof_submission" => null, + "img_proof_payment" => null, + "bank_id" => Banks::DFT_BANK_ID, + "bank_code" => Banks::DFT_BANK_CODE, + "bank_name" => Banks::DFT_BANK_NAME, + "bank_short_name" => Banks::DFT_BANK_SHORT_NAME, + "bank_acc_number" => Banks::DFT_BANK_ACC_NUMBER, + "bank_acc_name" => Banks::DFT_BANK_ACC_NAME, + "invc_to_client" => OrdersAItems::INVC_TO_CLIENT_YES, + "calc_to_vdr" => OrdersAItems::CALC_TO_VDR_NO, + "only_client" => OrdersAItems::ONLY_CLIENT_YES, + "ref_ord_id" => $ord_id, + "ref_ord_code" => $ord_code, + "ref_c_termin_id" => $c_termin2_id, + "crt" => $now, + "crt_by" => $req->auth->uid, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]); + } + if ($c_termin_sequence === 0) { + $req->sell_termin1_amt_type = OrdersTermins::AMT_TYPE_FLAT; + $req->sell_termin1_amt = $req->sell_price; + $req->sell_termin1_amt_at = strtotime("+2 days", $now); + $req->sell_termin1_calc_percent = 0; + ++$c_termin_sequence; + $insTerminsC1 = [ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "flow_type" => OrdersTermins::FLOW_TYPE_BILLING, + "cash_type" => OrdersTermins::TYPE_CASH_IN, + "sequence" => $c_termin_sequence, + "termin_base_flat" => $req->sell_price, + "termin_tax_type" => OrdersAItems::AMT_TAX_TYPE_EXCLUDE, + "termin_tax_ppn_percent" => OrdersAItems::PPN_PERCENT, + "termin_tax_pph_percent" => OrdersAItems::PPH_PERCENT, + "termin_amt_type" => $req->sell_termin1_amt_type ?? 0, + "termin_amt" => $req->sell_termin1_amt ?? 0, + "termin_calc_percent" => $req->sell_termin1_calc_percent ?? 0, + "termin_result_flat" => + $req->sell_termin1_amt_type == OrdersTermins::AMT_TYPE_FLAT + ? $req->sell_termin1_amt + : $req->sell_termin1_calc_percent, + "termin_ddln_at" => $req->sell_termin1_at ?? 0, + "termin_ddln_type" => OrdersTermins::DDLN_TERMIN_TYPE_ORD_FINISH, + "termin_for" => OrdersTermins::TERMIN_FOR_CLIENT, + "crt" => $now, + "crt_by" => $req->auth->uid, + "crt_type" => OrdersTermins::CRT_TYPE_ADMIN, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]; + $c_termin1_id = OrdersTermins::add($insTerminsC1); + $qty = 1; + OrdersAItems::add([ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "flow_type" => OrdersAItems::FLOW_TYPE_BILLING, + "cash_type" => OrdersAItems::TYPE_CASH_IN, + "c_termin_id" => $c_termin1_id, + "a_item_type" => OrdersAItems::A_TYPE_PRIMARY, + // 'desc' => $main_item_dec . "
Pembayaran termin 1", + "desc" => $main_item_dec, + "unit_id" => 0, + "unit_type" => UnitTypes::UNIT_TYPE_PAKET, + "unit_qty" => $qty, + "amt_bill_base_flat" => $insTerminsC1["termin_result_flat"], + "amt_bill_result_flat" => $insTerminsC1["termin_result_flat"], + "amt_bill_total_flat" => $insTerminsC1["termin_result_flat"] * $qty, + "ddln_pay_at" => $insTerminsC1["termin_ddln_at"], + "ddln_pay_type" => OrdersAItems::DDLN_PAY_TYPE_ORD_FINISH, + "img_proof_submission" => null, + "img_proof_payment" => null, + "bank_id" => Banks::DFT_BANK_ID, + "bank_code" => Banks::DFT_BANK_CODE, + "bank_name" => Banks::DFT_BANK_NAME, + "bank_short_name" => Banks::DFT_BANK_SHORT_NAME, + "bank_acc_number" => Banks::DFT_BANK_ACC_NUMBER, + "bank_acc_name" => Banks::DFT_BANK_ACC_NAME, + "invc_to_client" => OrdersAItems::INVC_TO_CLIENT_YES, + "calc_to_vdr" => OrdersAItems::CALC_TO_VDR_NO, + "only_client" => OrdersAItems::ONLY_CLIENT_YES, + "ref_ord_id" => $ord_id, + "ref_ord_code" => $ord_code, + "ref_c_termin_id" => $c_termin1_id, + "crt" => $now, + "crt_by" => $req->auth->uid, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]); + } + + // $url = env("API_URL_NODE") . "/order/create"; + // $guzReq = new GuzzleClient(); + // $respNode = $guzReq->request("POST", $url, [ + // "headers" => [ + // "Host" => $_SERVER["SERVER_ADDR"] ?? "127.0.0.1", + // "User-Agent" => "curl/7.65.3", + // "Accept" => "*/*", + // "Accept-Encoding" => "gzip, deflate, br", + // // 'Content-Type' => 'application/x-www-form-urlencoded; charset=UTF-8', + // // 'Connection' => 'keep-alive', + // ], + // "json" => [ + // "trx_code" => $ord_code, + // "trx_at" => $now, + // "client_id" => $clientAuth->uid, + // "client_name" => $clientAuth->first_name, + // "client_phone" => + // $clientAuth->phone_code . " " . implode(" ", str_split($clientAuth->phone, 4)), + // "client_mail" => $clientAuth->email, + // "client_addr" => "", + // "client_prefer_type_truck" => $type_truck_name, + // "pickup_zone_title" => $pckPoints[0]->name, + // "pickup_zone_addr" => $pckPoints[0]->fulladdress, + // "pickup_at" => $req->points[0]["pickup_at"], + // "drop_zone_title" => $dropPoints[0]->name, + // "drop_zone_addr" => $dropPoints[0]->fulladdress, + // "admins" => $admins_data, + // ], + // ]); + // if ($respNode->getStatusCode() != 200) { + // DB::rollBack(); + // $apiResp = Responses::bad_request("fail create order 0"); + // return new Response($apiResp, $apiResp["meta"]["code"]); + // } + // $body = json_decode($respNode->getBody()->getContents()); + + $apiResp = Responses::created("success create order"); + + DB::commit(); + // return new Response($apiResp, $apiResp["meta"]["code"]); + return redirect("user/vendor/transactions"); + } catch (\Exception $e) { + DB::rollBack(); + // dd($e); + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } +} diff --git a/app/Http/Controllers/TransactionSpcController.php.bak b/app/Http/Controllers/TransactionSpcController.php.bak new file mode 100755 index 0000000..60ff282 --- /dev/null +++ b/app/Http/Controllers/TransactionSpcController.php.bak @@ -0,0 +1,2280 @@ +where("id", Auth::user()->id) + ->get(); + + $vehicles = DB::table("t_vehicles as tv") + ->leftJoin("t_users as tu", "tu.id", "tv.vendor_id") + ->where("tu.id", Auth::user()->id) + ->where("tv.status", 1) + ->whereNull("tv.dlt") + ->select("tv.*") + ->get(); + + $drivers = DB::table("t_drivers as td") + ->leftJoin("t_users as tu", "tu.id", "td.vendor_id") + ->where("tu.id", Auth::user()->id) + ->where("td.status", 1) + // ->where("td.is_in_ord", 1) + ->whereNull("td.dlt") + ->select("td.*") + ->get(); + + $data = [ + "uclients" => Users::listUsers([ + "role" => Users::ROLE_VENDOR, + "status" => Users::STATUS_ACTIVE, + "id" => Auth::user()->id, + ]), + "truck_types" => ConfTruckTypes::listTruckTypes( + ConfTruckTypes::IS_ACTIVE, + ["is_publish" => ConfTruckTypes::IS_PUBLISH] + ), + "devices" => Devices::listDevices([ + "is_active" => Devices::IS_ACTIVE, + "type" => Devices::TYPE_PORTABLE, + "is_idle_yes" => 1, + "is_available" => Devices::IS_AVAIL, + ]), + "vendors" => $vendors, + "vehicles" => $vehicles, + "drivers" => $drivers, + "banks" => Banks::listBanks(["is_active" => Banks::IS_ACTIVE]), + ]; + return view("menu_v1._addTransactionsSpcMultiple", $data); + // return view('menu_v1._addTransactionsSpcSingle', $data); + } + + /** + * CASE SEMI AUTOMATIC + * Vendor + * phone belum digunakan, email digunakan ? AMAN + * phone digunakan, email belum digunakan ? AMAN + * phone digunakan, emaill digunakan ? AMAN + * Driver + * driver lock on phone1 ? AMAN + * driver in order ? AMAN + * driver phone1 used but from current input its different name driver ? AMAN + * driver ditemukan tapi beda vendor ? + * Vehicle + * device_id used on vhc and nopol same ? + * device_id used on vhc but nopol not same ? AMAN + * device_id not used on any vhc and nopol not used ? AMAN + * device_id not used on any vhc but nopol used ? AMAN + * vehilce ditemukan tapi beda vendor ? + * Rates + * rates yang sama ? AMAN + * Other + * kir_exp / tax_exp not input on DB when new vhc AMAN + * show suggestion beluman + */ + + // multiple + public function api_trx_spc_checkout_v1(Request $req) + { + try { + $now = time(); + + $input = [ + "uid" => $req->uid, + "points" => $req->points, + "truck_type_id" => $req->truck_type_id, + "truck_type_name" => $req->truck_type_name, + "is_insurance" => $req->is_insurance, + "is_client_pkp" => $req->is_client_pkp, + "amt_beneficiary" => $req->amt_beneficiary, + "vdr_name" => $req->vdr_name, + "vdr_phone" => $req->vdr_phone, + "vdr_email" => $req->vdr_email, + "vdr_addr" => $req->vdr_addr, + "vdr_bank_id" => $req->vdr_bank_id, + "vdr_bank_code" => $req->vdr_bank_code, + "vdr_bank_short" => $req->vdr_bank_short, + "vdr_bank_name" => $req->vdr_bank_name, + "vdr_kcp" => $req->vdr_bank_branch_name, + "vdr_bank_acc_number" => $req->vdr_bank_acc_number, + "vdr_bank_acc_name" => $req->vdr_bank_acc_name, + "is_vdr_bcng" => $req->is_vdr_bcng, + "device_id" => $req->device_id, + "vhc_nopol" => $req->vhc_nopol, + "vhc_stnk_taxexp" => $req->vhc_stnk_taxexp, + "vhc_kir_exp" => $req->vhc_kir_exp, + "drv_name" => $req->drv_name, + "drv_phone" => $req->drv_phone, + "drv_phone2" => $req->drv_phone2, + "drv_bank_id" => $req->drv_bank_id, + "drv_bank_code" => $req->drv_bank_code, + "drv_bank_name" => $req->drv_bank_name, + "drv_kcp" => $req->drv_bank_branch_name, + "drv_bank_acc_number" => $req->drv_bank_acc_number, + "drv_bank_acc_name" => $req->drv_bank_acc_name, + "sell_price" => $req->sell_price, + "buy_price" => $req->buy_price, + "buy_price_tax_type" => $req->buy_price_tax_type, + "buy_price_tax_ppn_percent" => $req->buy_price_tax_ppn_percent, + "buy_price_tax_ppn_flat" => $req->buy_price_tax_ppn_flat, + "buy_price_tax_pph_percent" => $req->buy_price_tax_pph_percent, + "buy_price_tax_pph_flat" => $req->buy_price_tax_pph_flat, + "buy_price_total_tax" => $req->buy_price_total_tax, + "margin_price" => $req->margin_price, + "percent_price" => $req->percent_price, + "lead_time" => $req->lead_time, + "termin1_amt_type" => $req->termin1_amt_type, + "termin1_amt" => $req->termin1_amt, + "termin1_calc_percent" => $req->termin1_calc_percent, + "termin1_date" => $req->termin1_date, + "termin1_time" => $req->termin1_time, + "termin1_at" => $req->termin1_at, + "termin2_amt_type" => $req->termin2_amt_type, + "termin2_amt" => $req->termin2_amt, + "termin2_calc_percent" => $req->termin2_calc_percent, + "sell_termin1_amt_type" => $req->sell_termin1_amt_type, + "sell_termin1_amt" => $req->sell_termin1_amt, + "sell_termin1_calc_percent" => $req->sell_termin1_calc_percent, + "sell_termin1_date" => $req->sell_termin1_date, + "sell_termin1_time" => $req->sell_termin1_time, + "sell_termin1_at" => $req->sell_termin1_at, + "sell_termin2_amt_type" => $req->sell_termin2_amt_type, + "sell_termin2_amt" => $req->sell_termin2_amt, + "sell_termin2_calc_percent" => $req->sell_termin2_calc_percent, + "pocket_id" => $req->pocket_id, + "pocket_type" => $req->pocket_type, + "pocket_checkpoints" => $req->pocket_checkpoints, + ]; + $rulesInput = [ + "uid" => "required|integer|not_in:0", + "points" => "required|array|min:1", + "points.*.pickup_at" => "required|integer", + "points.*.pickup_zone_id" => "required|integer", + "points.*.pickup_zone_pic_name" => "required|string", + "points.*.pickup_zone_pic_phone" => "required|numeric", + "points.*.drop_zone_id" => "required|integer", + "points.*.drop_zone_pic_name" => "required|string", + "points.*.drop_zone_pic_phone" => "required|numeric", + "truck_type_id" => "required|integer|not_in:0", + "truck_type_name" => "required|string", + "is_insurance" => "nullable|string", + "is_client_pkp" => "nullable|numeric", + "amt_beneficiary" => "nullable|numeric", + "vdr_name" => "required|string", + "vdr_phone" => "required|numeric", + "vdr_email" => "required|email", + "vdr_addr" => "required|string|min:35", + "vdr_bank_id" => "required|integer|not_in:0", + "vdr_bank_code" => "required|numeric", + "vdr_bank_short" => "required|string", + "vdr_bank_name" => "required|string", + "vdr_kcp" => "required|string", + "vdr_bank_acc_number" => "required|numeric", + "vdr_bank_acc_name" => "required|string|max:255", + "is_vdr_bcng" => "nullable|numeric", + "device_id" => "nullable|numeric", + "vhc_nopol" => "required|string", + "vhc_stnk_taxexp" => "required|date_format:Y-m-d", + "vhc_kir_exp" => "required|date_format:Y-m-d", + "drv_name" => "required|string", + "drv_phone" => "required|numeric", + "drv_phone2" => "nullable|numeric", + "drv_bank_id" => "nullable|numeric", + "drv_bank_code" => "nullable|string", + "drv_bank_name" => "nullable|string", + "drv_kcp" => "nullable|string", + "drv_bank_short_name" => "nullable|string", + "drv_bank_acc_number" => "nullable|string", + "drv_bank_acc_name" => "nullable|string", + "sell_price" => "required|numeric", + "buy_price" => "required|numeric", + "buy_price_tax_type" => "required|numeric", + "buy_price_tax_ppn_percent" => "required|numeric", + "buy_price_tax_ppn_flat" => "required|numeric", + "buy_price_tax_pph_percent" => "required|numeric", + "buy_price_tax_pph_flat" => "required|numeric", + "buy_price_total_tax" => "required|numeric", + "margin_price" => "required|numeric", + "lead_time" => "required|integer|not_in:0", + "termin1_amt_type" => "nullable|numeric", + "termin1_amt" => "nullable|numeric", + "termin1_calc_percent" => "nullable|numeric", + "termin1_date" => "nullable|string", + "termin1_time" => "nullable|string", + "termin1_at" => "nullable|numeric", + "termin2_amt_type" => "nullable|numeric", + "termin2_amt" => "nullable|numeric", + "termin2_calc_percent" => "nullable|numeric", + "sell_termin1_amt_type" => "nullable|numeric", + "sell_termin1_amt" => "nullable|numeric", + "sell_termin1_calc_percent" => "nullable|numeric", + "sell_termin1_date" => "nullable|string", + "sell_termin1_time" => "nullable|string", + "sell_termin1_at" => "nullable|numeric", + "sell_termin2_amt_type" => "nullable|numeric", + "sell_termin2_amt" => "nullable|numeric", + "sell_termin2_calc_percent" => "nullable|numeric", + "pocket_id" => "nullable|integer", + "pocket_type" => "nullable|numeric", + "pocket_checkpoints" => "nullable|array", + ]; + // $req->margin_price = 0; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input( + $isValidInput->messages()->first() + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $nopol = explode(" ", strtoupper($req->vhc_nopol)); + if (count($nopol) < 3) { + $apiResp = Responses::bad_input( + "Nomor polisi kendaraan tidak valid" + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + $device_id = str_pad( + $req->device_id, + Vehicles::MAX_DEVICE_ID, + "0", + STR_PAD_LEFT + ); + + if ($req->drv_name) { + if (!$req->drv_phone) { + $apiResp = Responses::bad_input( + "No Telepon driver ke-1 belum diisi" + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + if ($req->drv_phone2) { + if (!$req->drv_name) { + $apiResp = Responses::bad_input( + "Nama driver ke-2 belum diisi" + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + $existVdrId = 0; + $vdr = null; + $uniqPhone = Users::getUserByPhone($req->vdr_phone); + if (count($uniqPhone) > 0) { + $existVdrId = $uniqPhone[0]->id; + $vdr = $uniqPhone[0]; + $uniqMail = Users::getUserByEmail($req->vdr_email); + if (count($uniqMail) > 0) { + if ($uniqMail[0]->id !== $uniqPhone[0]->id) { + // email vendor tidak sesuai dengan akun yang terdata pada nomor telepon vendor + $apiResp = Responses::bad_request( + "email vendor telah digunakan" + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + } + if ($existVdrId === 0) { + $uniqMail = Users::getUserByEmail($req->vdr_email); + if (count($uniqMail) > 0) { + $existVdrId = $uniqMail[0]->id; + $vdr = $uniqMail[0]; + } + } + + $existDrvId = 0; + $drv = null; + $uniqPhone = Drivers::getDriverByPhone($req->drv_phone); + if (count($uniqPhone) > 0) { + if ( + strpos( + strtolower($uniqPhone[0]->fullname), + strtolower($req->drv_name) + ) === false + ) { + $apiResp = Responses::bad_request( + "no telepon driver sudah digunakan oleh driver " . + $uniqPhone[0]->fullname + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + // if ($uniqPhone[0]->is_in_ord === Drivers::IN_ORD_YES) { + // $apiResp = Responses::bad_request('driver ' . $uniqPhone[0]->fullname . ' sedang berada dalam order lain'); + // return (new Response($apiResp, $apiResp['meta']['code'])); + // } + $existDrvId = $uniqPhone[0]->id; + $drv = $uniqPhone[0]; + } + + $existVhcId = 0; + $vhc = null; + if ( + $device_id !== + str_pad(0, Vehicles::MAX_DEVICE_ID, "0", STR_PAD_LEFT) + ) { + $uniqVhcByDevice = Vehicles::getVehicleByDeviceId($device_id); + } else { + $uniqVhcByDevice = []; + } + if (count($uniqVhcByDevice) > 0) { + $uniqPlatNo = Vehicles::getVehicleByPlatNo( + $nopol[0], + $nopol[1], + $nopol[2] + ); + if (count($uniqPlatNo) > 0) { + if ($uniqVhcByDevice[0]->id !== $uniqPlatNo[0]->id) { + $apiResp = Responses::bad_request( + "plat number has been used" + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + // if ($uniqPlatNo[0]->is_in_ord === Vehicles::IN_ORD_YES) { + // $apiResp = Responses::bad_request('kendaraan ' . $uniqPlatNo[0]->nopol1 . ' ' . $uniqPlatNo[0]->nopol2 . ' ' . $uniqPlatNo[0]->nopol3 . ' sedang berada dalam order lain'); + // return (new Response($apiResp, $apiResp['meta']['code'])); + // } + } + // if ($uniqVhcByDevice[0]->is_in_ord === Vehicles::IN_ORD_YES) { + // $apiResp = Responses::bad_request('kendaraan ' . $uniqVhcByDevice[0]->nopol1 . ' ' . $uniqVhcByDevice[0]->nopol2 . ' ' . $uniqVhcByDevice[0]->nopol3 . ' sedang berada dalam order lain'); + // return (new Response($apiResp, $apiResp['meta']['code'])); + // } + $existVhcId = $uniqVhcByDevice[0]->id; + $vhc = $uniqVhcByDevice[0]; + } + if ($existVhcId === 0) { + $uniqPlatNo = Vehicles::getVehicleByPlatNo( + $nopol[0], + $nopol[1], + $nopol[2] + ); + if (count($uniqPlatNo) > 0) { + // if ($uniqPlatNo[0]->is_in_ord === Vehicles::IN_ORD_YES) { + // $apiResp = Responses::bad_request('kendaraan ' . $uniqPlatNo[0]->nopol1 . ' ' . $uniqPlatNo[0]->nopol2 . ' ' . $uniqPlatNo[0]->nopol3 . ' sedang berada dalam order lain'); + // return (new Response($apiResp, $apiResp['meta']['code'])); + // } + $existVhcId = $uniqPlatNo[0]->id; + $vhc = $uniqPlatNo[0]; + } + } + + if ($existDrvId !== 0 && $existVdrId !== $drv->vendor_id) { + $uVendor = Users::getUserById($drv->vendor_id)[0]; + $apiResp = Responses::bad_request( + "data driver sudah termasuk dalam vendor: " . + $uVendor->first_name + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + if ($existVhcId !== 0 && $existVdrId !== $vhc->vendor_id) { + $uVendor = Users::getUserById($vhc->vendor_id)[0]; + $apiResp = Responses::bad_request( + "data kendaraan sudah termasuk dalam vendor: " . + $uVendor->first_name + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $pckZids = []; + $dropZids = []; + foreach ($req->points as $i => $point) { + $pckZids[] = $point["pickup_zone_id"]; + $dropZids[] = $point["drop_zone_id"]; + } + + $pcks = Zone::getZoneByIds($pckZids); + if (count($pcks) < 1) { + $apiResp = Responses::bad_request( + "Lokasi penjemputan tidak ditemukan" + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + foreach ($pcks as $i => $pck) { + if ( + $pck->prid == 0 || + $pck->ktid == 0 || + $pck->kcid == 0 || + $pck->klid == 0 + ) { + $apiResp = Responses::bad_request( + "Zonasi wilayah(provinsi, kecamatan, ...) lokasi penjemputan " . + $pck->name . + " belum lengkap" + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + $drops = Zone::getZoneByIds($dropZids); + if (count($drops) < 1) { + $apiResp = Responses::bad_request("Lokasi pengantaran"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + foreach ($drops as $i => $drop) { + if ( + $drop->prid == 0 || + $drop->ktid == 0 || + $drop->kcid == 0 || + $drop->klid == 0 + ) { + $apiResp = Responses::bad_request( + "Zonasi wilayah(provinsi, kecamatan, ...) lokasi pengantaran " . + $drop->name . + " belum lengkap" + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + if ($req->is_vdr_bcng == Users::IS_VDR_BCNG_YES) { + // $req->pocket_id + // $req->pocket_type + // $req->pocket_checkpoints + $pocket = PocketMoney::showPocketById($req->pocket_id); + if (count($pocket) < 1) { + $apiResp = Responses::not_found("uang saku belum dipilih"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + $pocket[0]->checkpoints = Checkpoints::listCheckpoints([ + "pocket_id" => $pocket[0]->id, + ]); + } + + $client = Clients::getClientById($req->auth->client_group_id); + $insurance = StaticInsurances::listStaticInsurances([ + "is_active" => StaticInsurances::IS_ACTIVE, + ]); + + $opts = []; + $opt = [ + "is_best" => 1, + ]; + $opt["lead_time_id"] = 0; + // $center_time = $v->long_time - $v->fast_time; + $opt["lead_time"] = $req->lead_time; // long_time + $price = $req->sell_price ?? 0; + $opt["price"] = $price; + $opt["real_price"] = $price; + $opt["disc_price"] = 0; + $opt["disc_type"] = $client[0]->disc_type; + $opt["disc_percent"] = 0; + if ($client[0]->disc_type === Clients::DISC_TYPE_FIX) { + $opt["disc_price"] = $client[0]->disc_amount; + $opt["price"] = $opt["price"] - $opt["disc_price"]; + } elseif ($client[0]->disc_type === Clients::DISC_TYPE_PERCENT) { + $opt["disc_percent"] = $client[0]->disc_amount; + $opt["disc_price"] = + ($opt["price"] * $client[0]->disc_amount) / 100; + $opt["price"] = $opt["price"] - $opt["disc_price"]; + } + array_push($opts, $opt); + + $apiResp = Responses::success("checkout success"); + $apiResp["data"] = $opts; + + if ($req->is_insurance === "true") { + // $insurances = Insurances::getInsurancesByRangeBeneficiaryAndActive($req->amt_beneficiary); + // if (count($insurances) < 1) { + // $apiResp = Responses::bad_request('Total pertangguhan tidak tersedia'); + // return new Response($apiResp, $apiResp['meta']['code']); + // } + // $apiResp['insurance'] = $insurances[0]; + $beneficiary = $req->amt_beneficiary ?? 0; // nilai pertangguhan + $calcPercent = + ($beneficiary * $insurance[0]->amt_percent) / 100; + $flatPercent = $beneficiary - $calcPercent; + $apiResp["insurance"] = [ + "premi_price" => $calcPercent, + ]; + } + + $apiResp["exist_data"] = [ + "vdr_id" => $existVdrId, + "drv_id" => $existDrvId, + "vhc_id" => $existVhcId, + ]; + + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + // multiple + /** + * DONE jangan lupa insert t_pocket, t_checkpoint + * DONE tambahan field t_vendors => is_vdr_bcng + * DONE tambahin field t_zones => boundary_diameter, boundary_area, boundary_ha + * tambahin field t_drivers => bank driver + */ + public function api_trx_spc_create_order_v1(Request $req) + { + try { + $now = time(); + + $input = [ + "uid" => $req->uid, + "points" => $req->points, + // 'pickup_at' => $req->pickup_at, + // 'pickup_zone_id' => $req->pickup_zone_id, + // 'pickup_zone_pic_name' => $req->pickup_zone_pic_name, + // 'pickup_zone_pic_phone' => $req->pickup_zone_pic_phone, + // 'drop_zone_id' => $req->drop_zone_id, + // 'drop_zone_pic_name' => $req->drop_zone_pic_name, + // 'drop_zone_pic_phone' => $req->drop_zone_pic_phone, + "truck_type_id" => $req->truck_type_id, + "truck_type_name" => $req->truck_type_name, + "is_insurance" => $req->is_insurance, + "is_client_pkp" => $req->is_client_pkp, + "amt_beneficiary" => $req->amt_beneficiary, + "vdr_id" => $req->vdr_id, + "vdr_name" => $req->vdr_name, + "vdr_phone" => $req->vdr_phone, + "vdr_email" => $req->vdr_email, + "vdr_addr" => $req->vdr_addr, + "vdr_bank_id" => $req->vdr_bank_id, + "vdr_bank_code" => $req->vdr_bank_code, + "vdr_bank_short" => $req->vdr_bank_short, + "vdr_bank_name" => $req->vdr_bank_name, + "vdr_kcp" => $req->vdr_bank_branch_name, + "vdr_bank_acc_number" => $req->vdr_bank_acc_number, + "vdr_bank_acc_name" => $req->vdr_bank_acc_name, + "is_vdr_bcng" => $req->is_vdr_bcng, + "device_id" => $req->device_id, + "vhc_id" => $req->vhc_id, + "vhc_nopol" => $req->vhc_nopol, + "vhc_stnk_taxexp" => $req->vhc_stnk_taxexp, + "vhc_kir_exp" => $req->vhc_kir_exp, + "drv_id" => $req->drv_id, + "drv_name" => $req->drv_name, + "drv_phone" => $req->drv_phone, + "drv_phone2" => $req->drv_phone2, + "drv_bank_id" => $req->drv_bank_id, + "drv_bank_code" => $req->drv_bank_code, + "drv_bank_name" => $req->drv_bank_name, + "drv_kcp" => $req->drv_bank_branch_name, + "drv_bank_acc_number" => $req->drv_bank_acc_number, + "drv_bank_acc_name" => $req->drv_bank_acc_name, + "sell_price" => $req->sell_price, + "buy_price" => $req->buy_price, + "buy_price_tax_type" => $req->buy_price_tax_type, + "buy_price_tax_ppn_percent" => $req->buy_price_tax_ppn_percent, + "buy_price_tax_ppn_flat" => $req->buy_price_tax_ppn_flat, + "buy_price_tax_pph_percent" => $req->buy_price_tax_pph_percent, + "buy_price_tax_pph_flat" => $req->buy_price_tax_pph_flat, + "buy_price_total_tax" => $req->buy_price_total_tax, + "margin_price" => $req->margin_price, + "percent_price" => $req->percent_price, + "lead_time" => $req->lead_time, + "termin1_amt_type" => $req->termin1_amt_type, + "termin1_amt" => $req->termin1_amt, + "termin1_calc_percent" => $req->termin1_calc_percent, + "termin1_date" => $req->termin1_date, + "termin1_time" => $req->termin1_time, + "termin1_at" => $req->termin1_at, + "termin2_amt_type" => $req->termin2_amt_type, + "termin2_amt" => $req->termin2_amt, + "termin2_calc_percent" => $req->termin2_calc_percent, + "sell_termin1_amt_type" => $req->sell_termin1_amt_type, + "sell_termin1_amt" => $req->sell_termin1_amt, + "sell_termin1_calc_percent" => $req->sell_termin1_calc_percent, + "sell_termin1_date" => $req->sell_termin1_date, + "sell_termin1_time" => $req->sell_termin1_time, + "sell_termin1_at" => $req->sell_termin1_at, + "sell_termin2_amt_type" => $req->sell_termin2_amt_type, + "sell_termin2_amt" => $req->sell_termin2_amt, + "sell_termin2_calc_percent" => $req->sell_termin2_calc_percent, + "pocket_id" => $req->pocket_id, + "pocket_type" => $req->pocket_type, + "pocket_checkpoints" => $req->pocket_checkpoints, + ]; + $rulesInput = [ + "uid" => "required|integer|not_in:0", + "points" => "required|array|min:1", + "points.*.pickup_at" => "required|integer", + "points.*.pickup_zone_id" => "required|integer", + "points.*.pickup_zone_pic_name" => "required|string", + "points.*.pickup_zone_pic_phone" => "required|numeric", + "points.*.drop_zone_id" => "required|integer", + "points.*.drop_zone_pic_name" => "required|string", + "points.*.drop_zone_pic_phone" => "required|numeric", + "truck_type_id" => "required|integer|not_in:0", + "truck_type_name" => "required|string", + "is_insurance" => "nullable|string", + "is_client_pkp" => "nullable|numeric", + "amt_beneficiary" => "nullable|numeric", + "vdr_id" => "required|numeric", + "vdr_name" => "required|string", + "vdr_phone" => "required|numeric", + "vdr_email" => "required|email", + "vdr_addr" => "required|string|min:35", + "vdr_bank_id" => "required|integer|not_in:0", + "vdr_bank_code" => "required|numeric", + "vdr_bank_short" => "required|string", + "vdr_bank_name" => "required|string", + "vdr_kcp" => "required|string", + "vdr_bank_acc_number" => "required|numeric", + "vdr_bank_acc_name" => "required|string|max:255", + "is_vdr_bcng" => "nullable|numeric", + "device_id" => "nullable|numeric", + "vhc_id" => "required|numeric", + "vhc_nopol" => "required|string", + "vhc_stnk_taxexp" => "required|date_format:Y-m-d", + "vhc_kir_exp" => "required|date_format:Y-m-d", + "drv_id" => "required|numeric", + "drv_name" => "required|string", + "drv_phone" => "required|numeric", + "drv_phone2" => "nullable|numeric", + "drv_bank_id" => "nullable|numeric", + "drv_bank_code" => "nullable|string", + "drv_bank_name" => "nullable|string", + "drv_kcp" => "nullable|string", + "drv_bank_short_name" => "nullable|string", + "drv_bank_acc_number" => "nullable|string", + "drv_bank_acc_name" => "nullable|string", + "sell_price" => "required|numeric", + "buy_price" => "required|numeric", + "buy_price_tax_type" => "required|numeric", + "buy_price_tax_ppn_percent" => "required|numeric", + "buy_price_tax_ppn_flat" => "required|numeric", + "buy_price_tax_pph_percent" => "required|numeric", + "buy_price_tax_pph_flat" => "required|numeric", + "buy_price_total_tax" => "required|numeric", + "margin_price" => "required|numeric", + // 'margin_price' => 'required', + // 'percent_price' => 'required|numeric', + "lead_time" => "required|integer|not_in:0", + "termin1_amt_type" => "nullable|numeric", + "termin1_amt" => "nullable|numeric", + "termin1_calc_percent" => "nullable|numeric", + "termin1_date" => "nullable|string", + "termin1_time" => "nullable|string", + "termin1_at" => "nullable|numeric", + "termin2_amt_type" => "nullable|numeric", + "termin2_amt" => "nullable|numeric", + "termin2_calc_percent" => "nullable|numeric", + "sell_termin1_amt_type" => "nullable|numeric", + "sell_termin1_amt" => "nullable|numeric", + "sell_termin1_calc_percent" => "nullable|numeric", + "sell_termin1_date" => "nullable|string", + "sell_termin1_time" => "nullable|string", + "sell_termin1_at" => "nullable|numeric", + "sell_termin2_amt_type" => "nullable|numeric", + "sell_termin2_amt" => "nullable|numeric", + "sell_termin2_calc_percent" => "nullable|numeric", + "pocket_id" => "nullable|integer", + "pocket_type" => "nullable|numeric", + "pocket_checkpoints" => "nullable|array", + ]; + // $req->margin_price = 0; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input( + $isValidInput->messages()->first() + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $clientAuth = Users::getUserById($req->uid)[0]; + $clientAuth->uid = $clientAuth->id; + + $adm_id = $req->auth->uid; + $crt_type_order = Orders::CRT_TYPE_ORDER_ADMIN_SPECIAL; + + $type_truck_name = $req->truck_type_name; + if ($req->truck_type_id && $req->truck_type_id != 0) { + $type_truck_name = $req->truck_type_name; + } else { + $type_truck_name = ""; + $req->truck_type_id = 0; + } + + $vdr_id = (int) $req->vdr_id; + $vhc_id = (int) $req->vhc_id; + $drv_id = (int) $req->drv_id; + $device_id = str_pad( + $req->device_id, + Vehicles::MAX_DEVICE_ID, + "0", + STR_PAD_LEFT + ); + $nopol = explode(" ", strtoupper($req->vhc_nopol)); + if (count($nopol) < 3) { + $apiResp = Responses::bad_input( + "Nomor polisi kendaraan tidak valid" + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $pckZids = []; + $dropZids = []; + $pickupAt = []; + foreach ($req->points as $i => $point) { + $pckZids[] = $point["pickup_zone_id"]; + $dropZids[] = $point["drop_zone_id"]; + $pickupAt[] = $point["pickup_at"]; + } + $pcks = Zone::getZoneByIds($pckZids); + if (count($pcks) < 1) { + $apiResp = Responses::not_found( + "Lokasi penjemputan tidak ditemukan" + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + if (empty($pcks[0]->boundary_points)) { + $apiResp = Responses::bad_request( + "Lokasi penjemputan tidak valid" + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + $drops = Zone::getZoneByIds($dropZids); + if (count($drops) < 1) { + $apiResp = Responses::not_found( + "Lokasi pengantaran tidak ditemukan" + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + if (empty($drops[0]->boundary_points)) { + $apiResp = Responses::bad_request( + "Lokasi pengantaran tidak valid" + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + $pckPoints = []; + $dropPoints = []; + foreach ($req->points as $iPoint => $point) { + foreach ($pcks as $iPck => $pck) { + if ($point["pickup_zone_id"] == $pck->id) { + if ( + $pck->prid == 0 || + $pck->ktid == 0 || + $pck->kcid == 0 || + $pck->klid == 0 + ) { + $apiResp = Responses::bad_request( + "Zonasi wilayah(provinsi, kecamatan, ...) lokasi penjemputan " . + $pck->name . + " belum lengkap" + ); + return new Response( + $apiResp, + $apiResp["meta"]["code"] + ); + } + $pcks[$iPck]->inpt_set_pck_at = + $req->points[$iPoint]["pickup_at"]; + $pcks[$iPck]->inpt_pic_name = + $req->points[$iPoint]["pickup_zone_pic_name"]; + $pcks[$iPck]->inpt_pic_phone_code = 62; + $pcks[$iPck]->inpt_pic_phone_val = + (int) $req->points[$iPoint][ + "pickup_zone_pic_phone" + ]; + $pcks[$iPck]->inpt_pic_mail = null; + $pckPoints[$iPoint] = clone $pcks[$iPck]; + } + } + foreach ($drops as $iDrop => $drop) { + if ($point["drop_zone_id"] == $drop->id) { + if ( + $drop->prid == 0 || + $drop->ktid == 0 || + $drop->kcid == 0 || + $drop->klid == 0 + ) { + $apiResp = Responses::bad_request( + "Zonasi wilayah(provinsi, kecamatan, ...) lokasi pengantaran " . + $drop->name . + " belum lengkap" + ); + return new Response( + $apiResp, + $apiResp["meta"]["code"] + ); + } + $drops[$iDrop]->inpt_pic_name = + $req->points[$iPoint]["drop_zone_pic_name"]; + $drops[$iDrop]->inpt_pic_phone_code = 62; + $drops[$iDrop]->inpt_pic_phone_val = + (int) $req->points[$iPoint]["drop_zone_pic_phone"]; + $drops[$iDrop]->inpt_pic_mail = null; + $dropPoints[$iPoint] = clone $drops[$iDrop]; + } + } + } + $lowestPickupAt = min($pickupAt); + $longestPickupAt = max($pickupAt); + + $nanoid = new Nanoid(); + + // $ord_code = $nanoid->formattedId('0123456789', 12); + // $doWhile = true; + // do { + // $uniqOrdCode = Orders::getOrderByCode($ord_code); + // if (count($uniqOrdCode) > 0) { + // $ord_code = $nanoid->formattedId('0123456789', 12); + // } else { + // $doWhile = false; + // } + // } while ($doWhile); + if ( + ($req->sell_termin2_amt_type == OrdersTermins::AMT_TYPE_FLAT || + $req->sell_termin2_amt_type == + OrdersTermins::AMT_TYPE_PERCENT) && + $req->sell_termin2_amt > 0 + ) { + $ord_code_type = 6; + } else { + if ($req->sell_termin1_at < $req->points[0]["pickup_at"]) { + $ord_code_type = 5; + } else { + $ord_code_type = 7; + } + } + $ord_code = Helper::gnrtOrdCode($ord_code_type); + + $rate_code = $nanoid->formattedId("123456789", 6); + $doWhile = true; + do { + $uniqRateCode = ConfRates::getRateByCode($rate_code); + if (count($uniqRateCode) > 0) { + $rate_code = $nanoid->formattedId("123456789", 6); + } else { + $doWhile = false; + } + } while ($doWhile); + + $client = Clients::getClientById($clientAuth->client_group_id); + // $rate = ConfRates::getRateById($req->lead_time_id); + // $pck_pic = Clients::getClientById($pckPoints[0]->client_group_id); + // $drop_pic = Clients::getClientById($dropPoints[0]->client_group_id); + $admins = Users::getUsersActiveByRole(Users::ROLE_ADMIN); + $device = Devices::getDeviceByDeviceId($device_id); + if (count($device) < 1 || $device === false) { + $device = []; + $device[0] = new \StdClass(); + $device[0]->id = 0; + $device[0]->name = "-"; + $device[0]->type = Devices::TYPE_BUILT_IN; + $device[0]->simcard_code = 62; + $device[0]->simcard = 0; + } + // $insurance = []; + // if ($req->is_insurance === 'true') { + // $insurance = Insurances::getInsuranceById($req->insurance_id); + // if (count($insurance) < 1) { + // $apiResp = Responses::bad_request('Insurance not found'); + // return new Response($apiResp, $apiResp['meta']['code']); + // } + // } + + $admins_data = []; + foreach ($admins as $k => $v) { + array_push($admins_data, [ + "admin_id" => $v->id, + "admin_name" => $v->first_name, + "admin_phone" => + $v->phone_code . + " " . + implode(" ", str_split($v->phone, 4)), + "admin_mail" => $v->email, + "admin_addr" => "", + ]); + } + + $rate_id = 0; + if ($req->is_vdr_bcng != Users::IS_VDR_BCNG_YES) { + $insRate = [ + "code" => $rate_code, + "origin_prov" => $pckPoints[0]->prid, + "origin_city" => $pckPoints[0]->ktid, + "origin_district" => $pckPoints[0]->kcid, + "origin_village" => $pckPoints[0]->klid, + "lane" => ConfRates::LANE_EARTH, + "dest_prov" => $dropPoints[0]->prid, + "dest_city" => $dropPoints[0]->ktid, + "dest_district" => $dropPoints[0]->kcid, + "dest_village" => $dropPoints[0]->klid, + "vdr_id" => $vdr_id, + "vhc_type" => $req->truck_type_id, + "fast_time" => $req->lead_time, + "long_time" => $req->lead_time, + "unit_time" => ConfRates::UNIT_DAY, + "sell_kg" => 0, + "buy_kg" => 0, + "margin_kg" => 0, + "percent_kg" => 0, + "sell_cbm" => 0, + "buy_cbm" => 0, + "margin_cbm" => 0, + "percent_cbm" => 0, + "sell_ftl" => $req->sell_price, + "buy_ftl" => $req->buy_price, + "margin_ftl" => $req->margin_price ?? 0, + "percent_ftl" => $req->percent_price ?? 0, + "is_active" => ConfRates::IS_ACTIVE, + "crt" => $now, + "crt_by" => $req->auth->uid, + "crt_type" => ConfRates::CRT_TYPE_SYSTEM, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]; + + $rates = ConfRates::getUniqRate([ + "origin_prov" => $insRate["origin_prov"], + "dest_city" => $insRate["dest_city"], + "dest_district" => $insRate["dest_district"], + "vhc_type" => $insRate["vhc_type"], + "sell_ftl" => $insRate["sell_ftl"], + "long_time" => $insRate["long_time"], + "origin_prov_dest_ktid_dest_kcid_vhc_type_sell_ftl_long_time" => 1, + "is_active" => $insRate["is_active"], + ]); + if (count($rates) > 0) { + $rate_id = $rates[0]->id; + } + } + + /** + * DONE status_order, + * DONE vhc_in_ord, + * DONE drv_in_ord, + * DONE insert_orders_vendors, + * DONE insert_orders_vehicles, + * DONE insert_orders_drivers + */ + DB::beginTransaction(); + + if ($vdr_id === 0) { + $data = [ + "first_name" => $req->vdr_name, + "last_name" => $req->last_name ?? null, + "email" => $req->vdr_email, + "phone" => (int) $req->vdr_phone, + "phone_code" => Users::DEFAULT_PHONE_CODE, + "fulladdress" => $req->vdr_addr, + "password" => Hash::make((int) $req->vdr_phone), + "role" => Users::ROLE_VENDOR, + "client_group_id" => Clients::DEFAULT_CID, + "status" => Users::STATUS_ACTIVE, + "is_tracking" => Users::IS_TRACK_VHC_DEFAULT, + "bank_id" => $req->vdr_bank_id, + "bank_code" => $req->vdr_bank_code, + "bank_short_name" => $req->vdr_bank_short, + "bank_name" => $req->vdr_bank_name, + "bank_branch_name" => $req->vdr_bank_branch_name, + "bank_acc_number" => $req->vdr_bank_acc_number, + "bank_acc_name" => $req->vdr_bank_acc_name, + "crt" => $now, + "crt_by" => $req->auth->uid, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]; + $vdr_id = Users::addUser($data); + } else { + Users::updateUser($vdr_id, [ + "first_name" => $req->vdr_name, + "email" => $req->vdr_email, + "phone" => (int) $req->vdr_phone, + "fulladdress" => $req->vdr_addr, + "bank_id" => $req->vdr_bank_id, + "bank_code" => $req->vdr_bank_code, + "bank_short_name" => $req->vdr_bank_short, + "bank_name" => $req->vdr_bank_name, + "bank_branch_name" => $req->vdr_bank_branch_name, + "bank_acc_number" => $req->vdr_bank_acc_number, + "bank_acc_name" => $req->vdr_bank_acc_name, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]); + } + $vendor = Users::getUserById($vdr_id); + + if ($req->is_vdr_bcng != Users::IS_VDR_BCNG_YES) { + if ($rate_id === 0) { + $rate_id = ConfRates::addRate($insRate); + } + } + + $buy_price = $req->buy_price_total_tax; + if ( + $req->buy_price_tax_type == OrdersAItems::AMT_TAX_TYPE_INCLUDE + ) { + $buy_price = $req->buy_price_base; + } elseif ( + $req->buy_price_tax_type == OrdersAItems::AMT_TAX_TYPE_EXCLUDE + ) { + $buy_price = $req->buy_price_total_tax; + } + $insOrd = [ + "code" => $ord_code, + "type" => Orders::TYPE_FCL, + "pck_total" => count($pckPoints), + "drop_total" => count($dropPoints), + "est_lead_time" => $req->lead_time, + "lead_time" => $req->lead_time, + "est_price" => $req->price, + "price" => $req->price, + "est_real_price" => $req->real_price, + "real_price" => $req->real_price, + "est_disc_price" => $req->disc_price, + "disc_price" => $req->disc_price, + "est_buy_price" => $buy_price, + "buy_price" => $buy_price, + "est_real_buy_price" => $buy_price, + "real_buy_price" => $buy_price, + "est_disc_buy_price" => $req->disc_buy_price ?? 0, + "disc_buy_price" => $req->disc_buy_price ?? 0, + "est_rate_id" => $rate_id, + "rate_id" => $rate_id, + "status" => Orders::STTS_HAVE_GET_VHC, + "crt_type_order" => $crt_type_order, + "crt" => $now, + "crt_by" => $req->auth->uid, + "crt_adm_by" => $adm_id, + "updt" => $now, + "updt_by" => $req->auth->uid, + "confirm_at" => $now, + "confirm_by" => $req->auth->id, + // 'find_vhc_at' => $now, + // 'find_vhc_by' => $req->auth->id, + ]; + $ord_id = Orders::addOrder($insOrd); + + if ($drv_id === 0) { + $insDriver = [ + "nik" => 0, + "fullname" => $req->drv_name, + "fullname2" => $req->drv_name2, + "email" => null, + "phone" => (int) $req->drv_phone, + "phone_code" => Drivers::DEFAULT_PHONE_CODE, + "phone2" => $req->drv_phone2 ?? 0, + "phone2_code" => Drivers::DEFAULT_PHONE_CODE, + "dob" => null, + "age" => 0, + "blood" => null, + "fulladdress" => null, + "client_group_id" => Clients::DEFAULT_CID ?? null, + "vendor_id" => $vdr_id, + "status" => Drivers::STTS_ACTIVE, + "is_in_ord" => Drivers::IN_ORD_YES, + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "ord_ids" => json_encode([$ord_id]), + "crt" => $now, + "crt_by" => $req->auth->uid, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]; + $drv_id = Drivers::addDriver($insDriver); + $insDetail = [ + "did" => $drv_id, + "bank_id" => $req->drv_bank_id ?? 0, + "bank_code" => $req->drv_bank_code ?? null, + "bank_name" => $req->drv_bank_name ?? null, + "bank_short_name" => $req->drv_bank_short ?? null, + "bank_branch_name" => $req->drv_bank_branch_name, + "bank_acc_number" => $req->drv_bank_acc_number ?? null, + "bank_acc_name" => $req->drv_bank_acc_name ?? null, + ]; + DriversDetail::addDetail($insDetail); + } else { + $driver = Drivers::showDriverById($drv_id); + $ord_ids = []; + if ($driver[0]->ord_ids) { + $ord_ids = json_decode($driver[0]->ord_ids); + array_push($ord_ids, $ord_id); + } else { + array_push($ord_ids, $ord_id); + } + $updtDriver = [ + "fullname" => $req->drv_name, + "fullname2" => $req->drv_name2, + "phone" => (int) $req->drv_phone, + "phone2" => $req->drv_phone2 ?? 0, + "phone2_code" => Drivers::DEFAULT_PHONE_CODE, + "status" => Drivers::STTS_ACTIVE, + "is_in_ord" => Drivers::IN_ORD_YES, + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "ord_ids" => json_encode($ord_ids), + "updt" => $now, + "updt_by" => $req->auth->uid, + ]; + Drivers::updateDriver($drv_id, $updtDriver); + $updtDetailDriver = [ + "bank_id" => $req->drv_bank_id ?? 0, + "bank_code" => $req->drv_bank_code ?? null, + "bank_name" => $req->drv_bank_name ?? null, + "bank_short_name" => $req->drv_bank_short ?? null, + "bank_branch_name" => $req->drv_bank_branch_name, + "bank_acc_number" => $req->drv_bank_acc_number ?? null, + "bank_acc_name" => $req->drv_bank_acc_name ?? null, + ]; + DriversDetail::updateDetailByDid($drv_id, $updtDetailDriver); + } + $driver = Drivers::showDriverById($drv_id); + + if ($vhc_id === 0) { + $insVhc = [ + "name" => + strtoupper($nopol[0]) . + " " . + strtoupper($nopol[1]) . + " " . + strtoupper($nopol[2]), + "dvc_id" => $device[0]->id, + "device_id" => $device_id, + "simcard" => $device[0]->simcard, + "cat_id" => Vehicles::DEFAULT_CAT_ID, + "brand_id" => 0, + "type_id" => $req->truck_type_id, + "nopol1" => strtoupper($nopol[0]), + "nopol2" => strtoupper($nopol[1]), + "nopol3" => strtoupper($nopol[2]), + "c_did" => $drv_id, + "a_did" => $drv_id, + "is_track_holiday" => Vehicles::DEFAULT_TRACK_HOLIDAY, + "track_sch_d" => Vehicles::DEFAULT_TRACK_SCH_D, + "track_sch_h" => Vehicles::DEFAULT_TRACK_SCH_H, + "client_group_id" => Clients::DEFAULT_CID, + "vendor_id" => $vdr_id, + "status" => Vehicles::STTS_ACTIVE, + "is_in_ord" => Vehicles::IN_ORD_YES, + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "ord_ids" => json_encode([$ord_id]), + "crt" => $now, + "crt_by" => $req->auth->uid, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]; + $vhc_id = Vehicles::addVehicle($insVhc); + $insVhcDetail = [ + "vid" => $vhc_id, + "tax_exp" => $req->vhc_stnk_taxexp, + "kir_exp" => $req->vhc_kir_exp, + ]; + VehiclesDetail::addDetail($insVhcDetail); + } else { + $vehicle = Vehicles::showVehicleById($vhc_id); + $ord_ids = []; + if ($vehicle[0]->ord_ids) { + $ord_ids = json_decode($vehicle[0]->ord_ids); + array_push($ord_ids, $ord_id); + } else { + array_push($ord_ids, $ord_id); + } + $updtVhc = [ + "name" => + strtoupper($nopol[0]) . + " " . + strtoupper($nopol[1]) . + " " . + strtoupper($nopol[2]), + "dvc_id" => $device[0]->id, + "device_id" => $device_id, + "simcard" => $device[0]->simcard, + "type_id" => $req->truck_type_id, + "nopol1" => strtoupper($nopol[0]), + "nopol2" => strtoupper($nopol[1]), + "nopol3" => strtoupper($nopol[2]), + "c_did" => $drv_id, + "a_did" => $drv_id, + "status" => Vehicles::STTS_ACTIVE, + "is_in_ord" => Vehicles::IN_ORD_YES, + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "ord_ids" => json_encode($ord_ids), + "updt" => $now, + "updt_by" => $req->auth->uid, + ]; + if ( + $updtVhc["dvc_id"] == 0 && + $updtVhc["device_id"] == "0000000000000000" + ) { + $updtVhc["dvc_id"] = $vehicle[0]->dvc_id; + $updtVhc["device_id"] = $vehicle[0]->device_id; + } + Vehicles::updateVehicle($vhc_id, $updtVhc); + $updtVhcDetail = [ + "tax_exp" => $req->vhc_stnk_taxexp, + "kir_exp" => $req->vhc_kir_exp, + ]; + VehiclesDetail::updateDetailByVid($vhc_id, $updtVhcDetail); + } + $vehicle = Vehicles::showVehicleById($vhc_id); + + if ($device[0]->id > 0) { + Devices::updateDevice($device[0]->id, [ + "is_assigned" => Devices::IS_ASSIGNED, + "is_available" => Devices::IS_UNAVAIL, + ]); + } + + // if ($pckPoints[0]->boundary_bounds) { + // // $pckPoints[0]->boundary_bounds = json_encode($pckPoints[0]->boundary_bounds); + // } + // if ($pckPoints[0]->boundary_latlngs) { + // // $pckPoints[0]->boundary_latlngs = json_encode($pckPoints[0]->boundary_latlngs); + // } + + $pck_ids = []; + foreach ($pckPoints as $i => $pck) { + $insPck = [ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "set_pck_at" => $pck->inpt_set_pck_at, + "stts_pck" => OrdersPickups::STTS_WAIT, + "pck_id" => $pck->id, + "pck_name" => $pck->name, + "pck_desc" => $pck->desc, + "pck_type" => $pck->type, + "pck_workflow" => $pck->workflow_type, + "pck_shiptocode" => $pck->shiptocode, + "pck_prid" => $pck->prid, + "pck_ktid" => $pck->ktid, + "pck_kcid" => $pck->kcid, + "pck_klid" => $pck->klid, + "pck_addr" => $pck->fulladdress, + "pck_cgroup_id" => $pck->client_group_id, + "pck_cdiv_id" => $pck->client_div_id, + "pck_cgp_id" => $pck->client_gp_id, + "pck_hex_color" => $pck->boundary_hex_color, + "pck_shape" => $pck->boundary_type, + "pck_radius" => $pck->boundary_radius, + "pck_diameter" => $pck->boundary_diameter, + "pck_area" => $pck->boundary_area, + "pck_ha" => $pck->boundary_ha, + "pck_bounds" => $pck->boundary_bounds, + "pck_latlngs" => $pck->boundary_latlngs, + "pck_points" => $pck->boundary_points, + "pic_name" => $pck->inpt_pic_name, + "pic_phone_code" => $pck->inpt_pic_phone_code, + "pic_phone_val" => $pck->inpt_pic_phone_val, + "pic_mail" => $pck->inpt_pic_mail, + // 'pic_name' => $clientAuth->first_name, + // 'pic_phone_code' => $clientAuth->phone_code, + // 'pic_phone_val' => $clientAuth->phone, + // 'pic_mail' => $clientAuth->email, + ]; + $pck_id = OrdersPickups::add($insPck); + $pck_ids[] = $pck_id; + } + + // if ($dropPoints[0]->boundary_bounds) { + // // $dropPoints[0]->boundary_bounds = json_encode($dropPoints[0]->boundary_bounds); + // } + // if ($dropPoints[0]->boundary_latlngs) { + // // $dropPoints[0]->boundary_latlngs = json_encode($dropPoints[0]->boundary_latlngs); + // } + + $drop_ids = []; + foreach ($dropPoints as $i => $drop) { + $insDrop = [ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "stts_drop" => OrdersDrops::STTS_WAIT, + "drop_id" => $drop->id, + "drop_name" => $drop->name, + "drop_desc" => $drop->desc, + "drop_type" => $drop->type, + "drop_workflow" => $drop->workflow_type, + "drop_shiptocode" => $drop->shiptocode, + "drop_prid" => $drop->prid, + "drop_ktid" => $drop->ktid, + "drop_kcid" => $drop->kcid, + "drop_klid" => $drop->klid, + "drop_addr" => $drop->fulladdress, + "drop_cgroup_id" => $drop->client_group_id, + "drop_cdiv_id" => $drop->client_div_id, + "drop_cgp_id" => $drop->client_gp_id, + "drop_hex_color" => $drop->boundary_hex_color, + "drop_shape" => $drop->boundary_type, + "drop_radius" => $drop->boundary_radius, + "drop_diameter" => $drop->boundary_diameter, + "drop_area" => $drop->boundary_area, + "drop_ha" => $drop->boundary_ha, + "drop_bounds" => $drop->boundary_bounds, + "drop_latlngs" => $drop->boundary_latlngs, + "drop_points" => $drop->boundary_points, + "pic_name" => $drop->inpt_pic_name, + "pic_phone_code" => $drop->inpt_pic_phone_code, + "pic_phone_val" => $drop->inpt_pic_phone_val, + "pic_mail" => $drop->inpt_pic_mail, + // 'pic_name' => $clientAuth->first_name, + // 'pic_phone_code' => $clientAuth->phone_code, + // 'pic_phone_val' => $clientAuth->phone, + // 'pic_mail' => $clientAuth->email, + ]; + $drop_id = OrdersDrops::add($insDrop); + $drop_ids[] = $drop_id; + + OrdersPckDrop::add([ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "pck_id" => $pck_ids[$i], + "drop_id" => $drop_ids[$i], + "is_active" => 1, + "stts" => OrdersPckDrop::STTS_DELIVERY_OTW_PICKUP, + "crt" => $now, + "crt_by" => 0, + "updt" => $now, + "updt_by" => 0, + ]); + } + + $insClient = [ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "c_id" => $clientAuth->uid, + "c_name" => $clientAuth->first_name, + "c_phone_code" => $clientAuth->phone_code, + "c_phone_val" => $clientAuth->phone, + "c_mail" => $clientAuth->email, + "c_addr" => $clientAuth->fulladdress, + "c_disc_type" => $client[0]->disc_type, + "c_disc_amount" => $client[0]->disc_amount, + "c_pt_id" => $client[0]->id, + "c_pt_div_id" => $clientAuth->client_div_id, + "c_pt_gp_id" => $clientAuth->client_gp_id, + "c_pt_name" => $client[0]->c_name, + "c_pt_phone_code" => $client[0]->c_phone_code, + "c_pt_phone_val" => $client[0]->c_phone, + "c_pt_mail" => $client[0]->c_mail, + "c_pt_addr" => $client[0]->c_addr_office, + "c_pt_pic_name" => $client[0]->pic_name, + "c_pt_pic_phone_code" => $client[0]->pic_phone_code, + "c_pt_pic_phone_val" => $client[0]->pic_phone, + "c_pt_pic_mail" => $client[0]->pic_mail, + "c_pt_pic_addr" => null, + "prefer_truck_type" => $req->truck_type_id, + "is_pkp" => $req->is_client_pkp, + ]; + $ord_client_id = OrdersClients::add($insClient); + + if ($req->is_vdr_bcng != Users::IS_VDR_BCNG_YES) { + $insRate = [ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "rate_id" => $rate_id, + "rate_code" => $rate_code, + "origin_prov" => $insRate["origin_prov"], + "origin_city" => $insRate["origin_city"], + "origin_district" => $insRate["origin_district"], + "origin_village" => $insRate["origin_village"], + "lane" => $insRate["lane"], + "dest_prov" => $insRate["dest_prov"], + "dest_city" => $insRate["dest_city"], + "dest_district" => $insRate["dest_district"], + "dest_village" => $insRate["dest_village"], + "fast_time" => $insRate["fast_time"], + "long_time" => $insRate["long_time"], + "unit_time" => $insRate["unit_time"], + "sell_kg" => $insRate["sell_kg"], + "buy_kg" => $insRate["buy_kg"], + "margin_kg" => $insRate["margin_kg"], + "percent_kg" => $insRate["percent_kg"], + "sell_cbm" => $insRate["sell_cbm"], + "buy_cbm" => $insRate["buy_cbm"], + "margin_cbm" => $insRate["margin_cbm"], + "percent_cbm" => $insRate["percent_cbm"], + "sell_ftl" => $insRate["sell_ftl"], + "buy_ftl" => $insRate["buy_ftl"], + "margin_ftl" => $insRate["margin_ftl"], + "percent_ftl" => $insRate["percent_ftl"], + "vdr_id" => $insRate["vdr_id"], + "vhc_type" => $insRate["vhc_type"], + "crt_type" => $insRate["crt_type"], + ]; + OrdersRates::add($insRate); + } + + if ($req->is_insurance == "true") { + // if (count($insurance) > 0) { + $insurance = StaticInsurances::listStaticInsurances([ + "is_active" => StaticInsurances::IS_ACTIVE, + ]); + $beneficiary = $req->amt_beneficiary ?? 0; // nilai pertangguhan + $calcPercent = + ($beneficiary * $insurance[0]->amt_percent) / 100; + $flatPercent = $beneficiary - $calcPercent; + $insInsurance = [ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "insurance_id" => 0, + "premi_name" => $insurance[0]->desc, + "premi_price" => $calcPercent, + "amt_beneficiary" => $beneficiary, + "amt_percent" => $insurance[0]->amt_percent, + "amt_type" => OrdersInsurances::AMT_TYPE_PERCENT, + "premi_min_price" => $beneficiary, + "premi_max_price" => $beneficiary, + "desc" => $insurance[0]->desc, + ]; + OrdersInsurances::add($insInsurance); + } + + $vdrCompany = Clients::getClientById($vendor[0]->client_group_id); + $insVendors = [ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "vdr_id" => $vendor[0]->id, + "vdr_name" => $vendor[0]->first_name, + "vdr_mail" => $vendor[0]->email, + "vdr_phone_code" => $vendor[0]->phone_code, + "vdr_phone_val" => $vendor[0]->phone, + "vdr_addr" => $vendor[0]->fulladdress, + "vdr_cgroup_id" => $vendor[0]->client_group_id, + "vdr_pt_name" => $vdrCompany[0]->c_name, + "vdr_pt_phone_code" => $vdrCompany[0]->c_phone_code, + "vdr_pt_phone_val" => $vdrCompany[0]->c_phone, + "vdr_pt_mail" => $vdrCompany[0]->c_mail, + "vdr_pt_addr" => $vdrCompany[0]->c_addr_office, + "vdr_pt_pic_name" => $vdrCompany[0]->pic_name, + "vdr_pt_pic_phone_code" => $vdrCompany[0]->pic_phone_code, + "vdr_pt_pic_phone_val" => $vdrCompany[0]->pic_phone, + "vdr_pt_pic_mail" => $vdrCompany[0]->pic_mail, + "vdr_bank_id" => $vendor[0]->bank_id, + "vdr_bank_code" => $vendor[0]->bank_code, + "vdr_bank_short_name" => $vendor[0]->bank_short_name, + "vdr_bank_name" => $vendor[0]->bank_name, + "vdr_bank_branch_name" => $vendor[0]->bank_branch_name, + "vdr_bank_acc_number" => $vendor[0]->bank_acc_number, + "vdr_bank_acc_name" => $vendor[0]->bank_acc_name, + "is_vdr_bcng" => $req->is_vdr_bcng, + "find_vhcs" => $vhc_id, + "find_radius" => 0, + "find_shape" => Zone::ZONE_BOUNDARY_CIRCLE, + "find_center_lat" => 0, + "find_center_lng" => 0, + "distance" => 0, + "is_exp" => OrdersVendors::LINK_NOT_EXP, + "exp_at" => 0, // strtotime('+10 minutes', $now), // strtotime('+1 day', $now) + "bid_token" => (new Nanoid())->generateId(36), + "is_mailing_bid" => OrdersVendors::IS_MAILING_BID_NOT, + "is_mailing_bid_at" => 0, + "is_want" => OrdersVendors::IS_WANT_YES, + "is_want_at" => $now, + "status" => OrdersVendors::STTS_ACC, + "respond_at" => $now, + "is_pkp" => $req->is_vendor_pkp, + "crt" => $now, + ]; + OrdersVendors::add($insVendors); + + OrdersDrivers::add([ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "vdr_id" => $driver[0]->vendor_id, + "drv_id" => $driver[0]->id, + "drv_name" => $driver[0]->fullname, + "drv_mail" => $driver[0]->email, + "drv_name2" => $driver[0]->fullname2, + "drv_phone_code" => $driver[0]->phone_code, + "drv_phone_val" => $driver[0]->phone, + "drv_phone2_code" => $driver[0]->phone2_code, + "drv_phone2_val" => $driver[0]->phone2, + "drv_addr" => $driver[0]->fulladdress, + "drv_cgroup_id" => $driver[0]->client_group_id, + "drv_nik" => $driver[0]->nik, + "drv_dob" => $driver[0]->dob, + "drv_age" => Helper::countAge($driver[0]->dob), + "drv_gender" => $driver[0]->gender, + "drv_blood" => $driver[0]->blood, + "em_fullname" => $driver[0]->em_fullname, + "em_phone_code" => $driver[0]->em_phone_code, + "em_phone_val" => $driver[0]->em_phone, + "em_relationship" => $driver[0]->em_relationship, + "drv_ktp_img" => $driver[0]->ktp_img, + "drv_npwp_img" => $driver[0]->npwp_img, + "drv_npwp_number" => $driver[0]->npwp_number, + "drv_npwp_string" => $driver[0]->npwp_string, + "drv_license_img" => $driver[0]->license_img, + "drv_license_number" => $driver[0]->license_number, + "drv_license_exp" => $driver[0]->license_exp, + "drv_bank_id" => $req->drv_bank_id ?? 0, + "drv_bank_code" => $req->drv_bank_code ?? null, + "drv_bank_short_name" => $req->drv_bank_short ?? null, + "drv_bank_name" => $req->drv_bank_name ?? null, + "drv_bank_branch_name" => $req->drv_bank_branch_name ?? null, + "drv_bank_acc_number" => $req->drv_bank_acc_number ?? null, + "drv_bank_acc_name" => $req->drv_bank_acc_name ?? null, + ]); + OrdersVehicles::add([ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "vhc_id" => $vehicle[0]->vid, + "vhc_name" => $vehicle[0]->name, + "vhc_dvc_id" => $device[0]->id, + "vhc_dvc_name" => $device[0]->name, + "vhc_dvc_type" => $device[0]->type, + "vhc_device_id" => $vehicle[0]->device_id, + "vhc_simcard_code" => $device[0]->simcard_code, + "vhc_simcard" => $device[0]->simcard, + "vhc_cat_id" => $vehicle[0]->cat_id, + "vhc_brand_id" => $vehicle[0]->brand_id, + "vhc_type_id" => $vehicle[0]->type_id, + "vhc_model_id" => $vehicle[0]->model_id, + "vhc_c_did" => $vehicle[0]->c_did, + "vhc_a_did" => $vehicle[0]->a_did, + "vhc_nopol1" => $vehicle[0]->nopol1, + "vhc_nopol2" => $vehicle[0]->nopol2, + "vhc_nopol3" => $vehicle[0]->nopol3, + "vhc_is_track_holiday" => $vehicle[0]->is_track_holiday, + "vhc_track_sch_d" => $vehicle[0]->track_sch_d, + "vhc_track_sch_h" => $vehicle[0]->track_sch_h, + "vhc_cgroup_id" => $vehicle[0]->client_group_id, + "vhc_vdr_id" => $vehicle[0]->vendor_id, + "vhc_speed_limit" => $vehicle[0]->speed_limit, + "vhc_fuel_capacity" => $vehicle[0]->fuel_capacity, + "vhc_fuel_drop_treshold" => $vehicle[0]->fuel_drop_treshold, + "vhc_max_pressure" => $vehicle[0]->max_pressure, + "vhc_fvhc_img" => $vehicle[0]->fvhc_img, + "vhc_stnk_img" => $vehicle[0]->stnk_img, + "vhc_stnk_exp" => $vehicle[0]->stnk_exp, + "vhc_vyear" => $vehicle[0]->vyear, + "vhc_cc" => $vehicle[0]->cc, + "vhc_vin" => $vehicle[0]->vin, + "vhc_en" => $vehicle[0]->en, + "vhc_vcolor" => $vehicle[0]->vcolor, + "vhc_fuel_type" => $vehicle[0]->fuel_type, + "vhc_tnkb_color" => $vehicle[0]->tnkb_color, + "vhc_regis_year" => $vehicle[0]->regis_year, + "vhc_tax_exp" => $vehicle[0]->tax_exp, + ]); + + if ($req->is_vdr_bcng == Users::IS_VDR_BCNG_YES) { + // $req->pocket_id + // $req->pocket_type + // $req->pocket_checkpoints + $pocket = PocketMoney::showPocketById($req->pocket_id); + if (count($pocket) < 1) { + $apiResp = Responses::not_found("uang saku belum dipilih"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + $ord_pocket_id = OrdersPockets::addPocket([ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "pocket_id" => $pocket[0]->id, + "pocket_code" => $pocket[0]->code, + "pocket_name" => $pocket[0]->name, + "pck_id" => $pocket[0]->pck_id, + "drop_id" => $pocket[0]->drop_id, + "pocket_type" => $pocket[0]->type, + "pocket_flow" => $pocket[0]->flow, + "pocket_is_active" => $pocket[0]->is_active, + "pocket_total" => $pocket[0]->total, + "crt" => $now, + "crt_by" => $req->auth->uid, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]); + // order_pocket_id + $pocket[0]->checkpoints = Checkpoints::listCheckpoints([ + "pocket_id" => $pocket[0]->id, + ]); + foreach ($pocket[0]->checkpoints as $checkpoint) { + OrdersCheckpoints::addCheckpoint([ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "ord_pocket_id" => $ord_pocket_id, + "pocket_id" => $checkpoint->pocket_id, + "pck_id" => $checkpoint->pck_id, + "drop_id" => $checkpoint->drop_id, + "pocket_sort" => $checkpoint->sort, + "pocket_fee" => $checkpoint->pocket_fee, + "pocket_tol_fee" => $checkpoint->tol_fee, + "pocket_fuel_fee" => $checkpoint->fuel_fee, + "pocket_total" => $checkpoint->total, + "crt" => $now, + "crt_by" => $req->auth->uid, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]); + } + } + + // $main_item_dec = "Pengantaran Logistik
" . ucwords(strtolower($pckPoints[0]->prid_name)) . " - " . ucwords(strtolower($dropPoints[0]->prid_name)) . "
" . date('d F Y', $insPck['set_pck_at']); + // $main_item_dec = "Pengantaran Logistik
" . ucwords(strtolower($pckPoints[0]->prid_name)) . " - " . ucwords(strtolower($dropPoints[0]->prid_name)) . "
" . strftime('%d %B %Y', $insPck['set_pck_at']); + $main_item_dec = + "Pengantaran Logistik
" . + ucwords(strtolower($pckPoints[0]->ktid_name)) . + " - " . + ucwords(strtolower($dropPoints[0]->ktid_name)) . + "
" . + ucwords(strtolower($dropPoints[0]->name)) . + ", " . + ucwords(strtolower($dropPoints[0]->prid_name)) . + " - " . + $dropPoints[0]->shiptocode . + "
" . + strftime("%d %m %Y", $insPck["set_pck_at"]) . + "
" . + $req->note_tonase; + + if ($req->is_vdr_bcng == Users::IS_VDR_BCNG_YES) { + $req->termin1_amt_type = OrdersTermins::AMT_TYPE_PERCENT; + $req->buy_price = 0; + $req->buy_price_tax_type = 0; + $req->buy_price_tax_ppn_percent = 0; + $req->buy_price_tax_ppn_flat = 0; + $req->buy_price_tax_pph_percent = 0; + $req->buy_price_tax_pph_flat = 0; + $req->buy_price_total_tax = 0; + $req->termin1_amt = 0; + $req->termin1_calc_percent = 0; + $req->termin1_at = 0; + $req->termin1_calc_percent_base = 0; + } + + $v_termin_sequence = 0; + $v_termin1_id = 0; + $v_termin2_id = 0; + if ( + $req->termin1_amt_type == OrdersTermins::AMT_TYPE_FLAT || + $req->termin1_amt_type == OrdersTermins::AMT_TYPE_PERCENT + ) { + ++$v_termin_sequence; + $insTerminsVdr1 = [ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "flow_type" => OrdersTermins::FLOW_TYPE_PAYMENT, + "cash_type" => OrdersTermins::TYPE_CASH_OUT, + "sequence" => $v_termin_sequence, + "termin_base_flat" => $req->buy_price, + "termin_tax_type" => $req->buy_price_tax_type, + "termin_tax_ppn_percent" => + $req->buy_price_tax_ppn_percent ?? 0, + "termin_tax_ppn_flat" => $req->buy_price_tax_ppn_flat ?? 0, + "termin_tax_pph_percent" => + $req->buy_price_tax_pph_percent ?? 0, + "termin_tax_pph_flat" => $req->buy_price_tax_pph_flat ?? 0, + "termin_total_tax_flat" => $req->buy_price_total_tax ?? 0, + "termin_amt_type" => $req->termin1_amt_type ?? 0, + "termin_amt" => $req->termin1_amt ?? 0, + "termin_calc_percent" => $req->termin1_calc_percent ?? 0, + "termin_result_flat" => + $req->termin1_amt_type == OrdersTermins::AMT_TYPE_FLAT + ? $req->termin1_amt + : $req->termin1_calc_percent, + "termin_ddln_at" => $req->termin1_at ?? 0, + "termin_ddln_type" => OrdersTermins::DDLN_TERMIN_TYPE_TIME, + "termin_for" => OrdersTermins::TERMIN_FOR_VENDOR, + "crt" => $now, + "crt_by" => $req->auth->uid, + "crt_type" => OrdersTermins::CRT_TYPE_ADMIN, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]; + $v_termin1_id = OrdersTermins::add($insTerminsVdr1); + $qty = 1; + $amt_base_flat = + $req->termin1_amt_type == OrdersTermins::AMT_TYPE_FLAT + ? $req->termin1_amt + : $req->termin1_calc_percent_base; + $yang_dijadiin_summary = $insTerminsVdr1["termin_result_flat"]; + if ( + $req->buy_price_tax_type == + OrdersAItems::AMT_TAX_TYPE_INCLUDE + ) { + // $yang_dijadiin_summary = $amt_base_flat; + $yang_dijadiin_summary = + $insTerminsVdr1["termin_result_flat"]; + } elseif ( + $req->buy_price_tax_type == + OrdersAItems::AMT_TAX_TYPE_EXCLUDE + ) { + $yang_dijadiin_summary = + $insTerminsVdr1["termin_result_flat"]; + } + OrdersAItems::add([ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "flow_type" => OrdersAItems::FLOW_TYPE_PAYMENT, + "cash_type" => OrdersAItems::TYPE_CASH_OUT, + "v_termin_id" => $v_termin1_id, + "a_item_type" => OrdersAItems::A_TYPE_PRIMARY, + // 'desc' => $main_item_dec . "
Pembayaran termin 1", + "desc" => $main_item_dec, + "unit_id" => 0, + "unit_type" => UnitTypes::UNIT_TYPE_PAKET, + "unit_qty" => $qty, + "amt_base_flat" => $amt_base_flat, + "amt_tax_type" => $req->buy_price_tax_type, + "amt_tax_ppn_percent" => + $req->buy_price_tax_ppn_percent ?? 0, + "amt_tax_ppn_flat" => $req->buy_price_tax_ppn_flat ?? 0, + "amt_tax_pph_percent" => + $req->buy_price_tax_pph_percent ?? 0, + "amt_tax_pph_flat" => $req->buy_price_tax_pph_flat ?? 0, + "amt_total_tax_flat" => + $insTerminsVdr1["termin_result_flat"], + "amt_result_flat" => $insTerminsVdr1["termin_result_flat"], + "amt_total_flat" => $yang_dijadiin_summary * $qty, + "ddln_pay_at" => $insTerminsVdr1["termin_ddln_at"], + "ddln_pay_type" => OrdersAItems::DDLN_PAY_TYPE_TIME, + "img_proof_submission" => null, + "img_proof_payment" => null, + "bank_id" => $insVendors["vdr_bank_id"], + "bank_code" => $insVendors["vdr_bank_code"], + "bank_name" => $insVendors["vdr_bank_name"], + "bank_short_name" => $insVendors["vdr_bank_short_name"], + "bank_acc_number" => $insVendors["vdr_bank_acc_number"], + "bank_acc_name" => $insVendors["vdr_bank_acc_name"], + "invc_to_client" => OrdersAItems::INVC_TO_CLIENT_NO, + "calc_to_vdr" => OrdersAItems::CALC_TO_VDR_YES, + "only_vdr" => OrdersAItems::ONLY_VDR_YES, + "ref_ord_id" => $ord_id, + "ref_ord_code" => $ord_code, + "ref_v_termin_id" => $v_termin1_id, + "crt" => $now, + "crt_by" => $req->auth->uid, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]); + } + if ( + ($req->termin2_amt_type == OrdersTermins::AMT_TYPE_FLAT || + $req->termin2_amt_type == + OrdersTermins::AMT_TYPE_PERCENT) && + $req->termin2_amt > 0 + ) { + ++$v_termin_sequence; + $insTerminsVdr2 = [ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "flow_type" => OrdersTermins::FLOW_TYPE_PAYMENT, + "cash_type" => OrdersTermins::TYPE_CASH_OUT, + "sequence" => $v_termin_sequence, + "termin_base_flat" => $req->buy_price, + "termin_tax_type" => $req->buy_price_tax_type, + "termin_tax_ppn_percent" => + $req->buy_price_tax_ppn_percent ?? 0, + "termin_tax_ppn_flat" => $req->buy_price_tax_ppn_flat ?? 0, + "termin_tax_pph_percent" => + $req->buy_price_tax_pph_percent ?? 0, + "termin_tax_pph_flat" => $req->buy_price_tax_pph_flat ?? 0, + "termin_total_tax_flat" => $req->buy_price_total_tax ?? 0, + "termin_amt_type" => $req->termin2_amt_type ?? 0, + "termin_amt" => $req->termin2_amt ?? 0, + "termin_calc_percent" => $req->termin2_calc_percent ?? 0, + "termin_result_flat" => + $req->termin2_amt_type == OrdersTermins::AMT_TYPE_FLAT + ? $req->termin2_amt + : $req->termin2_calc_percent, + "termin_ddln_at" => $req->termin2_at ?? 0, + "termin_ddln_type" => + OrdersTermins::DDLN_TERMIN_TYPE_ORD_FINISH, + "termin_for" => OrdersTermins::TERMIN_FOR_VENDOR, + "crt" => $now, + "crt_by" => $req->auth->uid, + "crt_type" => OrdersTermins::CRT_TYPE_ADMIN, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]; + $v_termin2_id = OrdersTermins::add($insTerminsVdr2); + $qty = 1; + $amt_base_flat = + $req->termin2_amt_type == OrdersTermins::AMT_TYPE_FLAT + ? $req->termin2_amt + : $req->termin2_calc_percent_base; + $yang_dijadiin_summary = $insTerminsVdr2["termin_result_flat"]; + if ( + $req->buy_price_tax_type == + OrdersAItems::AMT_TAX_TYPE_INCLUDE + ) { + // $yang_dijadiin_summary = $amt_base_flat; + $yang_dijadiin_summary = + $insTerminsVdr2["termin_result_flat"]; + } elseif ( + $req->buy_price_tax_type == + OrdersAItems::AMT_TAX_TYPE_EXCLUDE + ) { + $yang_dijadiin_summary = + $insTerminsVdr2["termin_result_flat"]; + } + OrdersAItems::add([ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "flow_type" => OrdersAItems::FLOW_TYPE_PAYMENT, + "cash_type" => OrdersAItems::TYPE_CASH_OUT, + "v_termin_id" => $v_termin2_id, + "a_item_type" => OrdersAItems::A_TYPE_PRIMARY, + // 'desc' => $main_item_dec . "
Pembayaran termin 2", + "desc" => $main_item_dec, + "unit_id" => 0, + "unit_type" => UnitTypes::UNIT_TYPE_PAKET, + "unit_qty" => $qty, + "amt_base_flat" => $amt_base_flat, + "amt_tax_type" => $req->buy_price_tax_type, + "amt_tax_ppn_percent" => + $req->buy_price_tax_ppn_percent ?? 0, + "amt_tax_ppn_flat" => $req->buy_price_tax_ppn_flat ?? 0, + "amt_tax_pph_percent" => + $req->buy_price_tax_pph_percent ?? 0, + "amt_tax_pph_flat" => $req->buy_price_tax_pph_flat ?? 0, + "amt_total_tax_flat" => + $insTerminsVdr2["termin_result_flat"], + "amt_result_flat" => $insTerminsVdr2["termin_result_flat"], + "amt_total_flat" => $yang_dijadiin_summary * $qty, + "ddln_pay_at" => $insTerminsVdr2["termin_ddln_at"], + "ddln_pay_type" => OrdersAItems::DDLN_PAY_TYPE_ORD_FINISH, + "img_proof_submission" => null, + "img_proof_payment" => null, + "bank_id" => $insVendors["vdr_bank_id"], + "bank_code" => $insVendors["vdr_bank_code"], + "bank_name" => $insVendors["vdr_bank_name"], + "bank_short_name" => $insVendors["vdr_bank_short_name"], + "bank_acc_number" => $insVendors["vdr_bank_acc_number"], + "bank_acc_name" => $insVendors["vdr_bank_acc_name"], + "invc_to_client" => OrdersAItems::INVC_TO_CLIENT_NO, + "calc_to_vdr" => OrdersAItems::CALC_TO_VDR_YES, + "only_vdr" => OrdersAItems::ONLY_VDR_YES, + "ref_ord_id" => $ord_id, + "ref_ord_code" => $ord_code, + "ref_v_termin_id" => $v_termin2_id, + "crt" => $now, + "crt_by" => $req->auth->uid, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]); + } + if ($v_termin_sequence === 0) { + $req->termin1_amt_type = OrdersTermins::AMT_TYPE_FLAT; + $req->termin1_amt = $req->buy_price; + $req->termin1_amt_at = strtotime("+2 days", $now); + $req->termin1_calc_percent = 0; + ++$v_termin_sequence; + $insTerminsVdr1 = [ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "flow_type" => OrdersTermins::FLOW_TYPE_PAYMENT, + "cash_type" => OrdersTermins::TYPE_CASH_OUT, + "sequence" => $v_termin_sequence, + "termin_base_flat" => $req->buy_price, + "termin_tax_type" => $req->buy_price_tax_type, + "termin_tax_ppn_percent" => + $req->buy_price_tax_ppn_percent ?? 0, + "termin_tax_ppn_flat" => $req->buy_price_tax_ppn_flat ?? 0, + "termin_tax_pph_percent" => + $req->buy_price_tax_pph_percent ?? 0, + "termin_tax_pph_flat" => $req->buy_price_tax_pph_flat ?? 0, + "termin_total_tax_flat" => $req->buy_price_total_tax ?? 0, + "termin_amt_type" => $req->termin1_amt_type ?? 0, + "termin_amt" => $req->termin1_amt ?? 0, + "termin_calc_percent" => $req->termin1_calc_percent ?? 0, + "termin_result_flat" => + $req->termin1_amt_type == OrdersTermins::AMT_TYPE_FLAT + ? $req->termin1_amt + : $req->termin1_calc_percent, + "termin_ddln_at" => $req->termin1_at ?? 0, + "termin_ddln_type" => + OrdersTermins::DDLN_TERMIN_TYPE_ORD_FINISH, + "termin_for" => OrdersTermins::TERMIN_FOR_VENDOR, + "crt" => $now, + "crt_by" => $req->auth->uid, + "crt_type" => OrdersTermins::CRT_TYPE_ADMIN, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]; + $v_termin1_id = OrdersTermins::add($insTerminsVdr1); + $qty = 1; + $amt_base_flat = + $req->termin1_amt_type == OrdersTermins::AMT_TYPE_FLAT + ? $req->termin1_amt + : $req->termin1_calc_percent_base; + $yang_dijadiin_summary = $insTerminsVdr1["termin_result_flat"]; + if ( + $req->buy_price_tax_type == + OrdersAItems::AMT_TAX_TYPE_INCLUDE + ) { + // $yang_dijadiin_summary = $amt_base_flat; + $yang_dijadiin_summary = + $insTerminsVdr1["termin_result_flat"]; + } elseif ( + $req->buy_price_tax_type == + OrdersAItems::AMT_TAX_TYPE_EXCLUDE + ) { + $yang_dijadiin_summary = + $insTerminsVdr1["termin_result_flat"]; + } + OrdersAItems::add([ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "flow_type" => OrdersAItems::FLOW_TYPE_PAYMENT, + "cash_type" => OrdersAItems::TYPE_CASH_OUT, + "v_termin_id" => $v_termin1_id, + "a_item_type" => OrdersAItems::A_TYPE_PRIMARY, + // 'desc' => $main_item_dec . "
Pembayaran termin 1", + "desc" => $main_item_dec, + "unit_id" => 0, + "unit_type" => UnitTypes::UNIT_TYPE_PAKET, + "unit_qty" => $qty, + "amt_base_flat" => $amt_base_flat, + "amt_tax_type" => $req->buy_price_tax_type, + "amt_tax_ppn_percent" => + $req->buy_price_tax_ppn_percent ?? 0, + "amt_tax_ppn_flat" => $req->buy_price_tax_ppn_flat ?? 0, + "amt_tax_pph_percent" => + $req->buy_price_tax_pph_percent ?? 0, + "amt_tax_pph_flat" => $req->buy_price_tax_pph_flat ?? 0, + "amt_total_tax_flat" => + $insTerminsVdr1["termin_result_flat"], + "amt_result_flat" => $insTerminsVdr1["termin_result_flat"], + "amt_total_flat" => $yang_dijadiin_summary * $qty, + "ddln_pay_at" => $insTerminsVdr1["termin_ddln_at"], + "ddln_pay_type" => OrdersAItems::DDLN_PAY_TYPE_ORD_FINISH, + "img_proof_submission" => null, + "img_proof_payment" => null, + "bank_id" => $insVendors["vdr_bank_id"], + "bank_code" => $insVendors["vdr_bank_code"], + "bank_name" => $insVendors["vdr_bank_name"], + "bank_short_name" => $insVendors["vdr_bank_short_name"], + "bank_acc_number" => $insVendors["vdr_bank_acc_number"], + "bank_acc_name" => $insVendors["vdr_bank_acc_name"], + "invc_to_client" => OrdersAItems::INVC_TO_CLIENT_NO, + "calc_to_vdr" => OrdersAItems::CALC_TO_VDR_YES, + "only_vdr" => OrdersAItems::ONLY_VDR_YES, + "ref_ord_id" => $ord_id, + "ref_ord_code" => $ord_code, + "ref_v_termin_id" => $v_termin1_id, + "crt" => $now, + "crt_by" => $req->auth->uid, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]); + } + + $c_termin_sequence = 0; + $c_termin1_id = 0; + $c_termin2_id = 0; + if ( + $req->sell_termin1_amt_type == OrdersTermins::AMT_TYPE_FLAT || + $req->sell_termin1_amt_type == OrdersTermins::AMT_TYPE_PERCENT + ) { + ++$c_termin_sequence; + $insTerminsC1 = [ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "flow_type" => OrdersTermins::FLOW_TYPE_BILLING, + "cash_type" => OrdersTermins::TYPE_CASH_IN, + "sequence" => $c_termin_sequence, + "termin_base_flat" => $req->sell_price, + "termin_tax_type" => OrdersAItems::AMT_TAX_TYPE_EXCLUDE, + "termin_tax_ppn_percent" => OrdersAItems::PPN_PERCENT, + "termin_tax_pph_percent" => OrdersAItems::PPH_PERCENT, + "termin_amt_type" => $req->sell_termin1_amt_type ?? 0, + "termin_amt" => $req->sell_termin1_amt ?? 0, + "termin_calc_percent" => + $req->sell_termin1_calc_percent ?? 0, + "termin_result_flat" => + $req->sell_termin1_amt_type == + OrdersTermins::AMT_TYPE_FLAT + ? $req->sell_termin1_amt + : $req->sell_termin1_calc_percent, + "termin_ddln_at" => $req->sell_termin1_at ?? 0, + "termin_ddln_type" => OrdersTermins::DDLN_TERMIN_TYPE_TIME, + "termin_for" => OrdersTermins::TERMIN_FOR_CLIENT, + "crt" => $now, + "crt_by" => $req->auth->uid, + "crt_type" => OrdersTermins::CRT_TYPE_ADMIN, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]; + $c_termin1_id = OrdersTermins::add($insTerminsC1); + $qty = 1; + OrdersAItems::add([ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "flow_type" => OrdersAItems::FLOW_TYPE_BILLING, + "cash_type" => OrdersAItems::TYPE_CASH_IN, + "c_termin_id" => $c_termin1_id, + "a_item_type" => OrdersAItems::A_TYPE_PRIMARY, + // 'desc' => $main_item_dec . "
Pembayaran termin 1", + "desc" => $main_item_dec, + "unit_id" => 0, + "unit_type" => UnitTypes::UNIT_TYPE_PAKET, + "unit_qty" => $qty, + "amt_bill_base_flat" => $insTerminsC1["termin_result_flat"], + "amt_bill_result_flat" => + $insTerminsC1["termin_result_flat"], + "amt_bill_total_flat" => + $insTerminsC1["termin_result_flat"] * $qty, + "ddln_pay_at" => $insTerminsC1["termin_ddln_at"], + "ddln_pay_type" => OrdersAItems::DDLN_PAY_TYPE_TIME, + "img_proof_submission" => null, + "img_proof_payment" => null, + "bank_id" => Banks::DFT_BANK_ID, + "bank_code" => Banks::DFT_BANK_CODE, + "bank_name" => Banks::DFT_BANK_NAME, + "bank_short_name" => Banks::DFT_BANK_SHORT_NAME, + "bank_acc_number" => Banks::DFT_BANK_ACC_NUMBER, + "bank_acc_name" => Banks::DFT_BANK_ACC_NAME, + "invc_to_client" => OrdersAItems::INVC_TO_CLIENT_YES, + "calc_to_vdr" => OrdersAItems::CALC_TO_VDR_NO, + "only_client" => OrdersAItems::ONLY_CLIENT_YES, + "ref_ord_id" => $ord_id, + "ref_ord_code" => $ord_code, + "ref_c_termin_id" => $c_termin1_id, + "crt" => $now, + "crt_by" => $req->auth->uid, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]); + } + if ( + ($req->sell_termin2_amt_type == OrdersTermins::AMT_TYPE_FLAT || + $req->sell_termin2_amt_type == + OrdersTermins::AMT_TYPE_PERCENT) && + $req->sell_termin2_amt > 0 + ) { + ++$c_termin_sequence; + $insTerminsC2 = [ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "flow_type" => OrdersTermins::FLOW_TYPE_BILLING, + "cash_type" => OrdersTermins::TYPE_CASH_IN, + "sequence" => $c_termin_sequence, + "termin_base_flat" => $req->sell_price, + "termin_tax_type" => OrdersAItems::AMT_TAX_TYPE_EXCLUDE, + "termin_tax_ppn_percent" => OrdersAItems::PPN_PERCENT, + "termin_tax_pph_percent" => OrdersAItems::PPH_PERCENT, + "termin_amt_type" => $req->sell_termin2_amt_type ?? 0, + "termin_amt" => $req->sell_termin2_amt ?? 0, + "termin_calc_percent" => + $req->sell_termin2_calc_percent ?? 0, + "termin_result_flat" => + $req->sell_termin2_amt_type == + OrdersTermins::AMT_TYPE_FLAT + ? $req->sell_termin2_amt + : $req->sell_termin2_calc_percent, + "termin_ddln_at" => $req->sell_termin2_at ?? 0, + "termin_ddln_type" => + OrdersTermins::DDLN_TERMIN_TYPE_ORD_FINISH, + "termin_for" => OrdersTermins::TERMIN_FOR_CLIENT, + "crt" => $now, + "crt_by" => $req->auth->uid, + "crt_type" => OrdersTermins::CRT_TYPE_ADMIN, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]; + $c_termin2_id = OrdersTermins::add($insTerminsC2); + $qty = 1; + OrdersAItems::add([ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "flow_type" => OrdersAItems::FLOW_TYPE_BILLING, + "cash_type" => OrdersAItems::TYPE_CASH_IN, + "c_termin_id" => $c_termin2_id, + "a_item_type" => OrdersAItems::A_TYPE_PRIMARY, + // 'desc' => $main_item_dec . "
Pembayaran termin 2", + "desc" => $main_item_dec, + "unit_id" => 0, + "unit_type" => UnitTypes::UNIT_TYPE_PAKET, + "unit_qty" => $qty, + "amt_bill_base_flat" => $insTerminsC2["termin_result_flat"], + "amt_bill_result_flat" => + $insTerminsC2["termin_result_flat"], + "amt_bill_total_flat" => + $insTerminsC2["termin_result_flat"] * $qty, + "ddln_pay_at" => $insTerminsC2["termin_ddln_at"], + "ddln_pay_type" => OrdersAItems::DDLN_PAY_TYPE_ORD_FINISH, + "img_proof_submission" => null, + "img_proof_payment" => null, + "bank_id" => Banks::DFT_BANK_ID, + "bank_code" => Banks::DFT_BANK_CODE, + "bank_name" => Banks::DFT_BANK_NAME, + "bank_short_name" => Banks::DFT_BANK_SHORT_NAME, + "bank_acc_number" => Banks::DFT_BANK_ACC_NUMBER, + "bank_acc_name" => Banks::DFT_BANK_ACC_NAME, + "invc_to_client" => OrdersAItems::INVC_TO_CLIENT_YES, + "calc_to_vdr" => OrdersAItems::CALC_TO_VDR_NO, + "only_client" => OrdersAItems::ONLY_CLIENT_YES, + "ref_ord_id" => $ord_id, + "ref_ord_code" => $ord_code, + "ref_c_termin_id" => $c_termin2_id, + "crt" => $now, + "crt_by" => $req->auth->uid, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]); + } + if ($c_termin_sequence === 0) { + $req->sell_termin1_amt_type = OrdersTermins::AMT_TYPE_FLAT; + $req->sell_termin1_amt = $req->sell_price; + $req->sell_termin1_amt_at = strtotime("+2 days", $now); + $req->sell_termin1_calc_percent = 0; + ++$c_termin_sequence; + $insTerminsC1 = [ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "flow_type" => OrdersTermins::FLOW_TYPE_BILLING, + "cash_type" => OrdersTermins::TYPE_CASH_IN, + "sequence" => $c_termin_sequence, + "termin_base_flat" => $req->sell_price, + "termin_tax_type" => OrdersAItems::AMT_TAX_TYPE_EXCLUDE, + "termin_tax_ppn_percent" => OrdersAItems::PPN_PERCENT, + "termin_tax_pph_percent" => OrdersAItems::PPH_PERCENT, + "termin_amt_type" => $req->sell_termin1_amt_type ?? 0, + "termin_amt" => $req->sell_termin1_amt ?? 0, + "termin_calc_percent" => + $req->sell_termin1_calc_percent ?? 0, + "termin_result_flat" => + $req->sell_termin1_amt_type == + OrdersTermins::AMT_TYPE_FLAT + ? $req->sell_termin1_amt + : $req->sell_termin1_calc_percent, + "termin_ddln_at" => $req->sell_termin1_at ?? 0, + "termin_ddln_type" => + OrdersTermins::DDLN_TERMIN_TYPE_ORD_FINISH, + "termin_for" => OrdersTermins::TERMIN_FOR_CLIENT, + "crt" => $now, + "crt_by" => $req->auth->uid, + "crt_type" => OrdersTermins::CRT_TYPE_ADMIN, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]; + $c_termin1_id = OrdersTermins::add($insTerminsC1); + $qty = 1; + OrdersAItems::add([ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "flow_type" => OrdersAItems::FLOW_TYPE_BILLING, + "cash_type" => OrdersAItems::TYPE_CASH_IN, + "c_termin_id" => $c_termin1_id, + "a_item_type" => OrdersAItems::A_TYPE_PRIMARY, + // 'desc' => $main_item_dec . "
Pembayaran termin 1", + "desc" => $main_item_dec, + "unit_id" => 0, + "unit_type" => UnitTypes::UNIT_TYPE_PAKET, + "unit_qty" => $qty, + "amt_bill_base_flat" => $insTerminsC1["termin_result_flat"], + "amt_bill_result_flat" => + $insTerminsC1["termin_result_flat"], + "amt_bill_total_flat" => + $insTerminsC1["termin_result_flat"] * $qty, + "ddln_pay_at" => $insTerminsC1["termin_ddln_at"], + "ddln_pay_type" => OrdersAItems::DDLN_PAY_TYPE_ORD_FINISH, + "img_proof_submission" => null, + "img_proof_payment" => null, + "bank_id" => Banks::DFT_BANK_ID, + "bank_code" => Banks::DFT_BANK_CODE, + "bank_name" => Banks::DFT_BANK_NAME, + "bank_short_name" => Banks::DFT_BANK_SHORT_NAME, + "bank_acc_number" => Banks::DFT_BANK_ACC_NUMBER, + "bank_acc_name" => Banks::DFT_BANK_ACC_NAME, + "invc_to_client" => OrdersAItems::INVC_TO_CLIENT_YES, + "calc_to_vdr" => OrdersAItems::CALC_TO_VDR_NO, + "only_client" => OrdersAItems::ONLY_CLIENT_YES, + "ref_ord_id" => $ord_id, + "ref_ord_code" => $ord_code, + "ref_c_termin_id" => $c_termin1_id, + "crt" => $now, + "crt_by" => $req->auth->uid, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]); + } + + $url = env("API_URL_NODE") . "/order/create"; + $guzReq = new GuzzleClient(); + $respNode = $guzReq->request("POST", $url, [ + "headers" => [ + "Host" => $_SERVER["SERVER_ADDR"] ?? "127.0.0.1", + "User-Agent" => "curl/7.65.3", + "Accept" => "*/*", + "Accept-Encoding" => "gzip, deflate, br", + // 'Content-Type' => 'application/x-www-form-urlencoded; charset=UTF-8', + // 'Connection' => 'keep-alive', + ], + "json" => [ + "trx_code" => $ord_code, + "trx_at" => $now, + "client_id" => $clientAuth->uid, + "client_name" => $clientAuth->first_name, + "client_phone" => + $clientAuth->phone_code . + " " . + implode(" ", str_split($clientAuth->phone, 4)), + "client_mail" => $clientAuth->email, + "client_addr" => "", + "client_prefer_type_truck" => $type_truck_name, + "pickup_zone_title" => $pckPoints[0]->name, + "pickup_zone_addr" => $pckPoints[0]->fulladdress, + "pickup_at" => $req->points[0]["pickup_at"], + "drop_zone_title" => $dropPoints[0]->name, + "drop_zone_addr" => $dropPoints[0]->fulladdress, + "admins" => $admins_data, + ], + ]); + if ($respNode->getStatusCode() != 200) { + DB::rollBack(); + $apiResp = Responses::bad_request("fail create order 0"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + $body = json_decode($respNode->getBody()->getContents()); + + $apiResp = Responses::created("success create order"); + + DB::commit(); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } +} diff --git a/app/Http/Controllers/TransactionSpcController_bak_many_to_many.php b/app/Http/Controllers/TransactionSpcController_bak_many_to_many.php new file mode 100755 index 0000000..876690a --- /dev/null +++ b/app/Http/Controllers/TransactionSpcController_bak_many_to_many.php @@ -0,0 +1,1845 @@ +where("id", Auth::user()->id) + ->get(); + + $vehicles = DB::table("t_vehicles as tv") + ->leftJoin("t_users as tu", "tu.id", "tv.vendor_id") + ->where("tu.id", Auth::user()->id) + ->where("tv.status", 1) + ->whereNull("tv.dlt") + ->select("tv.*") + ->groupBy("tv.vendor_id") + ->get(); + + $drivers = DB::table("t_drivers as td") + ->leftJoin("t_users as tu", "tu.id", "td.vendor_id") + ->where("tu.id", Auth::user()->id) + ->where("td.status", 1) + ->where("td.is_in_ord", 2) + ->whereNull("td.dlt") + ->select("td.*") + ->get(); + + // select * from t_zones tz where tz.client_group_id = 21 and tz.workflow_type = 1 and tz.status = 1 + $pickupzone = DB::table("t_zones as tz") // + ->where("tz.client_group_id", Auth::user()->client_id) + ->where("tz.workflow_type", 1) + ->where("tz.status", 1) + ->whereNull("tz.dlt") + ->get(); + + // dd($pickupzone); + $dropzone = DB::table("t_zones as tz") // + ->where("tz.client_group_id", Auth::user()->client_id) + ->where("tz.workflow_type", 2) + ->where("tz.status", 1) + ->whereNull("tz.dlt") + ->get(); + + $checklist = DB::table("t_conf_checklists") + ->where("status", 1) + ->whereNull("dlt") + ->get(); + + $data = [ + "uclients" => Users::listUsers([ + "role" => Users::ROLE_VENDOR, + "status" => Users::STATUS_ACTIVE, + "id" => Auth::user()->id, + ]), + "truck_types" => ConfTruckTypes::listTruckTypes(ConfTruckTypes::IS_ACTIVE, [ + "is_publish" => ConfTruckTypes::IS_PUBLISH, + ]), + "devices" => Devices::listDevices([ + "is_active" => Devices::IS_ACTIVE, + "type" => Devices::TYPE_PORTABLE, + "is_idle_yes" => 1, + "is_available" => Devices::IS_AVAIL, + ]), + "vendors" => $vendors, + "vehicles" => $vehicles, + "drivers" => $drivers, + "pickup_zone" => $pickupzone, + "drop_zone" => $dropzone, + "checklist" => $checklist, + "banks" => Banks::listBanks(["is_active" => Banks::IS_ACTIVE]), + ]; + // dd($data); + return view("menu_v1._addTransactionsSpcMultiple", $data); + // return view('menu_v1._addTransactionsSpcSingle', $data); + } + + /** + * CASE SEMI AUTOMATIC + * Vendor + * phone belum digunakan, email digunakan ? AMAN + * phone digunakan, email belum digunakan ? AMAN + * phone digunakan, emaill digunakan ? AMAN + * Driver + * driver lock on phone1 ? AMAN + * driver in order ? AMAN + * driver phone1 used but from current input its different name driver ? AMAN + * driver ditemukan tapi beda vendor ? + * Vehicle + * device_id used on vhc and nopol same ? + * device_id used on vhc but nopol not same ? AMAN + * device_id not used on any vhc and nopol not used ? AMAN + * device_id not used on any vhc but nopol used ? AMAN + * vehilce ditemukan tapi beda vendor ? + * Rates + * rates yang sama ? AMAN + * Other + * kir_exp / tax_exp not input on DB when new vhc AMAN + * show suggestion beluman + */ + + // multiple + public function api_trx_spc_checkout_v1(Request $req) + { + $vhs = DB::table("t_vehicles as tv") + ->leftJoin("t_vehicles_types as tvt", "tvt.id", "tv.type_id") + ->leftJoin("t_vehicles_detail as tvd", "tvd.vid", "tv.id") + ->where("tv.id", $req->id_kendaraan) + ->select( + "tv.*", + "tvt.id as truck_type_id", + "tvt.name as truck_type_name", + "tvd.tax_exp as vhc_stnk_taxexp", + "tvd.kir_exp as vhc_kir_exp" + ) + ->first(); + $drv = DB::table("t_drivers as td") + ->leftJoin("t_drivers_detail as tdd", "tdd.did", "td.id") + ->where("td.id", $req->id_pengemudi) + ->first(); + // $points = $req->add_pickup_date; + $vdr = DB::table("t_users as tu") + ->leftJoin("t_clients as tc", "tc.id", "tu.client_id") + ->where("tu.id", Auth::user()->id) + ->first(); + // dd($req->all(), $vdr, $vhs, $drv, $points); + // dd($req->all()); + try { + $now = time(); + + $input = [ + "uid" => $req->add_client, + // "points" => $req->points, + // "points" => [1], + "truck_type_id" => $vhs->truck_type_id, + "truck_type_name" => $vhs->truck_type_name, + "is_insurance" => "NO", + "is_client_pkp" => 0, + "amt_beneficiary" => 0, + "vdr_name" => $vdr->c_name, + "vdr_phone" => "+" . $vdr->c_phone_code . $vdr->c_phone, + "vdr_email" => $vdr->c_mail, + "vdr_addr" => $vdr->c_addr_office, + "vdr_bank_id" => 0, + "vdr_bank_code" => 0, + "vdr_bank_short" => "vdr_bank_short", + "vdr_bank_name" => "vdr_bank_name", + "vdr_kcp" => "vdr_kcp", + "vdr_bank_acc_number" => 0, + "vdr_bank_acc_name" => "vdr_bank_acc_name", + "is_vdr_bcng" => 0, + "device_id" => $vhs->device_id, + "vhc_nopol" => $vhs->nopol1 . " " . $vhs->nopol2 . " " . $vhs->nopol3, + "vhc_stnk_taxexp" => $vhs->vhc_stnk_taxexp, + "vhc_kir_exp" => $vhs->vhc_kir_exp, + "drv_name" => $drv->fullname, + "drv_phone" => "+" . $drv->phone_code . $drv->phone, + "drv_phone2" => "+" . $drv->phone2_code . $drv->phone2, + "drv_bank_id" => $drv->bank_id, + "drv_bank_code" => $drv->bank_code, + "drv_bank_name" => $drv->bank_name, + "drv_kcp" => $drv->bank_branch_name, + "drv_bank_acc_number" => $drv->bank_acc_number, + "drv_bank_acc_name" => $drv->bank_acc_name, + "sell_price" => 0, + "buy_price" => 0, + "buy_price_tax_type" => 0, + "buy_price_tax_ppn_percent" => 0, + "buy_price_tax_ppn_flat" => 0, + "buy_price_tax_pph_percent" => 0, + "buy_price_tax_pph_flat" => 0, + "buy_price_total_tax" => 0, + "margin_price" => 0, + "percent_price" => 0, + "lead_time" => 1, + "termin1_amt_type" => 0, + "termin1_amt" => 0, + "termin1_calc_percent" => 0, + "termin1_date" => "$now", + "termin1_time" => "$now", + "termin1_at" => $now, + "termin2_amt_type" => $now, + "termin2_amt" => $now, + "termin2_calc_percent" => $now, + "sell_termin1_amt_type" => $now, + "sell_termin1_amt" => $now, + "sell_termin1_calc_percent" => $now, + "sell_termin1_date" => "$now", + "sell_termin1_time" => "$now", + "sell_termin1_at" => $now, + "sell_termin2_amt_type" => 0, + "sell_termin2_amt" => 0, + "sell_termin2_calc_percent" => 0, + // "pocket_id" => $req->pocket_id, + // "pocket_type" => $req->pocket_type, + // "pocket_checkpoints" => $req->pocket_checkpoints, + ]; + $rulesInput = [ + "uid" => "required|integer|not_in:0", + // "points" => "required|array|min:1", + // "points.*.pickup_at" => "required|integer", + // "points.*.pickup_zone_id" => "required|integer", + // "points.*.pickup_zone_pic_name" => "required|string", + // "points.*.pickup_zone_pic_phone" => "required|numeric", + // "points.*.drop_zone_id" => "required|integer", + // "points.*.drop_zone_pic_name" => "required|string", + // "points.*.drop_zone_pic_phone" => "required|numeric", + "truck_type_id" => "required|integer|not_in:0", + "truck_type_name" => "required|string", + "is_insurance" => "nullable|string", + "is_client_pkp" => "nullable|numeric", + "amt_beneficiary" => "nullable|numeric", + "vdr_name" => "required|string", + "vdr_phone" => "required|numeric", + "vdr_email" => "required|email", + "vdr_addr" => "required|string|min:35", + "vdr_bank_id" => "required|integer", + "vdr_bank_code" => "required|numeric", + "vdr_bank_short" => "required|string", + "vdr_bank_name" => "required|string", + "vdr_kcp" => "required|string", + "vdr_bank_acc_number" => "required|numeric", + "vdr_bank_acc_name" => "required|string|max:255", + "is_vdr_bcng" => "nullable|numeric", + "device_id" => "nullable|numeric", + "vhc_nopol" => "required|string", + "vhc_stnk_taxexp" => "required|date_format:Y-m-d", + "vhc_kir_exp" => "required|date_format:Y-m-d", + "drv_name" => "required|string", + "drv_phone" => "required|numeric", + "drv_phone2" => "nullable|numeric", + "drv_bank_id" => "nullable|numeric", + "drv_bank_code" => "nullable|string", + "drv_bank_name" => "nullable|string", + "drv_kcp" => "nullable|string", + "drv_bank_short_name" => "nullable|string", + "drv_bank_acc_number" => "nullable|string", + "drv_bank_acc_name" => "nullable|string", + "sell_price" => "required|numeric", + "buy_price" => "required|numeric", + "buy_price_tax_type" => "required|numeric", + "buy_price_tax_ppn_percent" => "required|numeric", + "buy_price_tax_ppn_flat" => "required|numeric", + "buy_price_tax_pph_percent" => "required|numeric", + "buy_price_tax_pph_flat" => "required|numeric", + "buy_price_total_tax" => "required|numeric", + "margin_price" => "required|numeric", + "lead_time" => "required|integer|not_in:0", + "termin1_amt_type" => "nullable|numeric", + "termin1_amt" => "nullable|numeric", + "termin1_calc_percent" => "nullable|numeric", + "termin1_date" => "nullable|string", + "termin1_time" => "nullable|string", + "termin1_at" => "nullable|numeric", + "termin2_amt_type" => "nullable|numeric", + "termin2_amt" => "nullable|numeric", + "termin2_calc_percent" => "nullable|numeric", + "sell_termin1_amt_type" => "nullable|numeric", + "sell_termin1_amt" => "nullable|numeric", + "sell_termin1_calc_percent" => "nullable|numeric", + "sell_termin1_date" => "nullable|string", + "sell_termin1_time" => "nullable|string", + "sell_termin1_at" => "nullable|numeric", + "sell_termin2_amt_type" => "nullable|numeric", + "sell_termin2_amt" => "nullable|numeric", + "sell_termin2_calc_percent" => "nullable|numeric", + // "pocket_id" => "nullable|integer", + // "pocket_type" => "nullable|numeric", + // "pocket_checkpoints" => "nullable|array", + ]; + // $req->margin_price = 0; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $pckZids = []; + foreach ($req->add_pickup_zone as $i => $point) { + $pckZids[] = $point; + } + $dropZids = []; + foreach ($req->add_drop_zone as $i => $point) { + $dropZids[] = $point; + } + // dd($pckZids); + + $pcks = Zone::getZoneByIds($pckZids); + // dd($pcks); + if (count($pcks) < 1) { + $apiResp = Responses::bad_request("Lokasi penjemputan tidak ditemukan"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + foreach ($pcks as $i => $pck) { + if ($pck->prid == 0 || $pck->ktid == 0 || $pck->kcid == 0 || $pck->klid == 0) { + $apiResp = Responses::bad_request( + "Zonasi wilayah(provinsi, kecamatan, ...) lokasi penjemputan " . + $pck->name . + " belum lengkap" + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + $drops = Zone::getZoneByIds($dropZids); + if (count($drops) < 1) { + $apiResp = Responses::bad_request("Lokasi pengantaran"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + foreach ($drops as $i => $drop) { + if ($drop->prid == 0 || $drop->ktid == 0 || $drop->kcid == 0 || $drop->klid == 0) { + $apiResp = Responses::bad_request( + "Zonasi wilayah(provinsi, kecamatan, ...) lokasi pengantaran " . + $drop->name . + " belum lengkap" + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + $client = Clients::getClientById($req->auth->client_group_id); + $insurance = StaticInsurances::listStaticInsurances([ + "is_active" => StaticInsurances::IS_ACTIVE, + ]); + + $opts = []; + $opt = [ + "is_best" => 1, + ]; + $opt["lead_time_id"] = 0; + // $center_time = $v->long_time - $v->fast_time; + $opt["lead_time"] = $req->lead_time; // long_time + $price = $req->sell_price ?? 0; + $opt["price"] = $price; + $opt["real_price"] = $price; + $opt["disc_price"] = 0; + $opt["disc_type"] = $client[0]->disc_type; + $opt["disc_percent"] = 0; + if ($client[0]->disc_type === Clients::DISC_TYPE_FIX) { + $opt["disc_price"] = $client[0]->disc_amount; + $opt["price"] = $opt["price"] - $opt["disc_price"]; + } elseif ($client[0]->disc_type === Clients::DISC_TYPE_PERCENT) { + $opt["disc_percent"] = $client[0]->disc_amount; + $opt["disc_price"] = ($opt["price"] * $client[0]->disc_amount) / 100; + $opt["price"] = $opt["price"] - $opt["disc_price"]; + } + array_push($opts, $opt); + + $apiResp = Responses::success("checkout success"); + $apiResp["data"] = $opts; + + if ($req->is_insurance === "true") { + // $insurances = Insurances::getInsurancesByRangeBeneficiaryAndActive($req->amt_beneficiary); + // if (count($insurances) < 1) { + // $apiResp = Responses::bad_request('Total pertangguhan tidak tersedia'); + // return new Response($apiResp, $apiResp['meta']['code']); + // } + // $apiResp['insurance'] = $insurances[0]; + $beneficiary = $req->amt_beneficiary ?? 0; // nilai pertangguhan + $calcPercent = ($beneficiary * $insurance[0]->amt_percent) / 100; + $flatPercent = $beneficiary - $calcPercent; + $apiResp["insurance"] = [ + "premi_price" => $calcPercent, + ]; + } + + // $apiResp["exist_data"] = [ + // "vdr_id" => $existVdrId, + // "drv_id" => $existDrvId, + // "vhc_id" => $existVhcId, + // ]; + // dd($apiResp); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + // multiple + /** + * DONE jangan lupa insert t_pocket, t_checkpoint + * DONE tambahan field t_vendors => is_vdr_bcng + * DONE tambahin field t_zones => boundary_diameter, boundary_area, boundary_ha + * tambahin field t_drivers => bank driver + */ + public function api_trx_spc_create_order_v1(Request $req) + { + // dd($req->all()); + $vhs = DB::table("t_vehicles as tv") + ->leftJoin("t_vehicles_types as tvt", "tvt.id", "tv.type_id") + ->leftJoin("t_vehicles_detail as tvd", "tvd.vid", "tv.id") + ->where("tv.id", $req->id_kendaraan) + ->select( + "tv.*", + "tvt.id as truck_type_id", + "tvt.name as truck_type_name", + "tvd.tax_exp as vhc_stnk_taxexp", + "tvd.kir_exp as vhc_kir_exp" + ) + ->first(); + $drv = DB::table("t_drivers as td") + ->leftJoin("t_drivers_detail as tdd", "tdd.did", "td.id") + ->where("td.id", $req->id_pengemudi) + ->select("td.*", "tdd.*", "td.id as id") + ->first(); + + $vdr = DB::table("t_clients as tc") + ->leftJoin("t_users as tu", "tc.id", "tu.client_id") + ->where("tu.id", Auth::user()->id) + ->first(); + try { + $now = time(); + + $input = [ + "uid" => $req->add_client, + // "points" => $req->points, + // "points" => [1], + "truck_type_id" => $vhs->truck_type_id, + "truck_type_name" => $vhs->truck_type_name, + "is_insurance" => "NO", + "is_client_pkp" => 0, + "amt_beneficiary" => 0, + "vdr_id" => $vdr->id, + "vdr_name" => $vdr->c_name, + "vdr_phone" => "+" . $vdr->c_phone_code . $vdr->c_phone, + "vdr_email" => $vdr->c_mail, + "vdr_addr" => $vdr->c_addr_office, + "vdr_bank_id" => 0, + "vdr_bank_code" => 0, + "vdr_bank_short" => "vdr_bank_short", + "vdr_bank_name" => "vdr_bank_name", + "vdr_kcp" => "vdr_kcp", + "vdr_bank_acc_number" => 0, + "vdr_bank_acc_name" => "vdr_bank_acc_name", + "is_vdr_bcng" => 0, + "device_id" => $vhs->device_id, + "vhc_id" => $vhs->id, + "vhc_nopol" => $vhs->nopol1 . " " . $vhs->nopol2 . " " . $vhs->nopol3, + "vhc_stnk_taxexp" => $vhs->vhc_stnk_taxexp, + "vhc_kir_exp" => $vhs->vhc_kir_exp, + "drv_id" => $drv->id, + "drv_name" => $drv->fullname, + "drv_phone" => "+" . $drv->phone_code . $drv->phone, + "drv_phone2" => "+" . $drv->phone2_code . $drv->phone2, + "drv_bank_id" => $drv->bank_id, + "drv_bank_code" => $drv->bank_code, + "drv_bank_name" => $drv->bank_name, + "drv_kcp" => $drv->bank_branch_name, + "drv_bank_acc_number" => $drv->bank_acc_number, + "drv_bank_acc_name" => $drv->bank_acc_name, + "sell_price" => 0, + "buy_price" => 0, + "buy_price_tax_type" => 0, + "buy_price_tax_ppn_percent" => 0, + "buy_price_tax_ppn_flat" => 0, + "buy_price_tax_pph_percent" => 0, + "buy_price_tax_pph_flat" => 0, + "buy_price_total_tax" => 0, + "margin_price" => 0, + "percent_price" => 0, + "lead_time" => 1, + "termin1_amt_type" => 0, + "termin1_amt" => 0, + "termin1_calc_percent" => 0, + "termin1_date" => "$now", + "termin1_time" => "$now", + "termin1_at" => $now, + "termin2_amt_type" => $now, + "termin2_amt" => $now, + "termin2_calc_percent" => $now, + "sell_termin1_amt_type" => $now, + "sell_termin1_amt" => $now, + "sell_termin1_calc_percent" => $now, + "sell_termin1_date" => "$now", + "sell_termin1_time" => "$now", + "sell_termin1_at" => $now, + "sell_termin2_amt_type" => 0, + "sell_termin2_amt" => 0, + "sell_termin2_calc_percent" => 0, + // "pocket_id" => $req->pocket_id, + // "pocket_type" => $req->pocket_type, + // "pocket_checkpoints" => $req->pocket_checkpoints, + ]; + $rulesInput = [ + "uid" => "required|integer|not_in:0", + // "points" => "required|array|min:1", + // "points.*.pickup_at" => "required|integer", + // "points.*.pickup_zone_id" => "required|integer", + // "points.*.pickup_zone_pic_name" => "required|string", + // "points.*.pickup_zone_pic_phone" => "required|numeric", + // "points.*.drop_zone_id" => "required|integer", + // "points.*.drop_zone_pic_name" => "required|string", + // "points.*.drop_zone_pic_phone" => "required|numeric", + "truck_type_id" => "required|integer|not_in:0", + "truck_type_name" => "required|string", + "is_insurance" => "nullable|string", + "is_client_pkp" => "nullable|numeric", + "amt_beneficiary" => "nullable|numeric", + "vdr_id" => "required|numeric", + "vdr_name" => "required|string", + "vdr_phone" => "required|numeric", + "vdr_email" => "required|email", + "vdr_addr" => "required|string|min:35", + // "vdr_bank_id" => "required|integer|not_in:0", + // "vdr_bank_code" => "required|numeric", + // "vdr_bank_short" => "required|string", + // "vdr_bank_name" => "required|string", + // "vdr_kcp" => "required|string", + // "vdr_bank_acc_number" => "required|numeric", + // "vdr_bank_acc_name" => "required|string|max:255", + "is_vdr_bcng" => "nullable|numeric", + "device_id" => "nullable|numeric", + "vhc_id" => "required|numeric", + "vhc_nopol" => "required|string", + "vhc_stnk_taxexp" => "required|date_format:Y-m-d", + "vhc_kir_exp" => "required|date_format:Y-m-d", + "drv_id" => "required|numeric", + "drv_name" => "required|string", + "drv_phone" => "required|numeric", + "drv_phone2" => "nullable|numeric", + "drv_bank_id" => "nullable|numeric", + "drv_bank_code" => "nullable|string", + "drv_bank_name" => "nullable|string", + "drv_kcp" => "nullable|string", + "drv_bank_short_name" => "nullable|string", + "drv_bank_acc_number" => "nullable|string", + "drv_bank_acc_name" => "nullable|string", + "sell_price" => "required|numeric", + "buy_price" => "required|numeric", + "buy_price_tax_type" => "required|numeric", + "buy_price_tax_ppn_percent" => "required|numeric", + "buy_price_tax_ppn_flat" => "required|numeric", + "buy_price_tax_pph_percent" => "required|numeric", + "buy_price_tax_pph_flat" => "required|numeric", + "buy_price_total_tax" => "required|numeric", + "margin_price" => "required|numeric", + // 'margin_price' => 'required', + // 'percent_price' => 'required|numeric', + "lead_time" => "required|integer|not_in:0", + "termin1_amt_type" => "nullable|numeric", + "termin1_amt" => "nullable|numeric", + "termin1_calc_percent" => "nullable|numeric", + "termin1_date" => "nullable|string", + "termin1_time" => "nullable|string", + "termin1_at" => "nullable|numeric", + "termin2_amt_type" => "nullable|numeric", + "termin2_amt" => "nullable|numeric", + "termin2_calc_percent" => "nullable|numeric", + "sell_termin1_amt_type" => "nullable|numeric", + "sell_termin1_amt" => "nullable|numeric", + "sell_termin1_calc_percent" => "nullable|numeric", + "sell_termin1_date" => "nullable|string", + "sell_termin1_time" => "nullable|string", + "sell_termin1_at" => "nullable|numeric", + "sell_termin2_amt_type" => "nullable|numeric", + "sell_termin2_amt" => "nullable|numeric", + "sell_termin2_calc_percent" => "nullable|numeric", + // "pocket_id" => "nullable|integer", + // "pocket_type" => "nullable|numeric", + // "pocket_checkpoints" => "nullable|array", + ]; + // $req->margin_price = 0; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + // dd($isValidInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $clientAuth = Users::getUserById($req->add_client)[0]; + $clientAuth->uid = $clientAuth->id; + // dd($clientAuth); + + $adm_id = $req->auth->uid; + $crt_type_order = Orders::CRT_TYPE_ORDER_ADMIN_SPECIAL; + + $type_truck_name = $req->truck_type_name; + if ($req->truck_type_id && $req->truck_type_id != 0) { + $type_truck_name = $req->truck_type_name; + } else { + $type_truck_name = ""; + $req->truck_type_id = 0; + } + + $vdr_id = (int) $vdr->id; + $vhc_id = (int) $vhs->id; + $drv_id = (int) $drv->id; + $device_id = str_pad($vhs->device_id, Vehicles::MAX_DEVICE_ID, "0", STR_PAD_LEFT); + $req->vhc_nopol = $vhs->nopol1 . " " . $vhs->nopol2 . " " . $vhs->nopol3; + $nopol = explode(" ", strtoupper($req->vhc_nopol)); + // dd($nopol); + if (count($nopol) < 3) { + $apiResp = Responses::bad_input("Nomor polisi kendaraan tidak valid"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $pckZids = []; + $dropZids = []; + $pickupAt = []; + // foreach ($req->points as $i => $point) { + // $pckZids[] = $point["pickup_zone_id"]; + // $dropZids[] = $point["drop_zone_id"]; + // $pickupAt[] = $point["pickup_at"]; + // } + foreach ($req->add_pickup_zone as $i => $point) { + $pckZids[] = $point; + } + foreach ($req->add_pickup_zone as $i => $point) { + // $pickupAt[] = $point; + // dd($i); + + $time = + $req->add_pickup_date[$i] . + " " . + $req->add_pickup_time_hour[$i] . + ":" . + $req->add_pickup_time_minute[$i] . + ":00"; + $pickupAt[] = strtotime($time); + } + foreach ($req->add_drop_zone as $i => $point) { + $dropZids[] = $point; + } + $pcks = Zone::getZoneByIds($pckZids); + // dd($pcks); + if (count($pcks) < 1) { + $apiResp = Responses::not_found("Lokasi penjemputan tidak ditemukan"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + if (empty($pcks[0]->boundary_points)) { + $apiResp = Responses::bad_request("Lokasi penjemputan tidak valid"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + $drops = Zone::getZoneByIds($dropZids); + if (count($drops) < 1) { + $apiResp = Responses::not_found("Lokasi pengantaran tidak ditemukan"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + if (empty($drops[0]->boundary_points)) { + $apiResp = Responses::bad_request("Lokasi pengantaran tidak valid"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + $req->points = []; + foreach ($req->add_pickup_zone as $i => $point) { + $pointData = []; + $pointData["pickup_at"] = $pickupAt[$i]; + $pointData["pickup_zone_id"] = $pckZids[$i]; + $pointData["pickup_zone_pic_name"] = $req->add_pickup_pic_name[$i]; + $pointData["pickup_zone_pic_phone"] = $req->add_pickup_pic_phone[$i]; + $pointData["drop_zone_id"] = $dropZids[$i]; + $pointData["drop_zone_pic_name"] = $req->add_drop_pic_name[$i]; + $pointData["drop_zone_pic_phone"] = $req->add_drop_pic_phone[$i]; + $req->points[] = $pointData; + } + $pckPoints = []; + $dropPoints = []; + $checklist = []; + foreach ($req->points as $iPoint => $point) { + foreach ($pcks as $iPck => $pck) { + if ($point["pickup_zone_id"] == $pck->id) { + if ($pck->prid == 0 || $pck->ktid == 0 || $pck->kcid == 0 || $pck->klid == 0) { + $apiResp = Responses::bad_request( + "Zonasi wilayah(provinsi, kecamatan, ...) lokasi penjemputan " . + $pck->name . + " belum lengkap" + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + $pcks[$iPck]->inpt_set_pck_at = $req->points[$iPoint]["pickup_at"]; + $pcks[$iPck]->inpt_pic_name = $req->points[$iPoint]["pickup_zone_pic_name"]; + $pcks[$iPck]->inpt_pic_phone_code = 62; + $pcks[$iPck]->inpt_pic_phone_val = + (int) $req->points[$iPoint]["pickup_zone_pic_phone"]; + $pcks[$iPck]->inpt_pic_mail = null; + $pckPoints[$iPoint] = clone $pcks[$iPck]; + } + } + foreach ($drops as $iDrop => $drop) { + if ($point["drop_zone_id"] == $drop->id) { + if ($drop->prid == 0 || $drop->ktid == 0 || $drop->kcid == 0 || $drop->klid == 0) { + $apiResp = Responses::bad_request( + "Zonasi wilayah(provinsi, kecamatan, ...) lokasi pengantaran " . + $drop->name . + " belum lengkap" + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + $drops[$iDrop]->inpt_pic_name = $req->points[$iPoint]["drop_zone_pic_name"]; + $drops[$iDrop]->inpt_pic_phone_code = 62; + $drops[$iDrop]->inpt_pic_phone_val = + (int) $req->points[$iPoint]["drop_zone_pic_phone"]; + $drops[$iDrop]->inpt_pic_mail = null; + $dropPoints[$iPoint] = clone $drops[$iDrop]; + } + } + } + // dd($req->checklist, $pckPoints, $dropPoints); + $lowestPickupAt = min($pickupAt); + $longestPickupAt = max($pickupAt); + + $nanoid = new Nanoid(); + + // $ord_code = $nanoid->formattedId('0123456789', 12); + // $doWhile = true; + // do { + // $uniqOrdCode = Orders::getOrderByCode($ord_code); + // if (count($uniqOrdCode) > 0) { + // $ord_code = $nanoid->formattedId('0123456789', 12); + // } else { + // $doWhile = false; + // } + // } while ($doWhile); + if ( + ($req->sell_termin2_amt_type == OrdersTermins::AMT_TYPE_FLAT || + $req->sell_termin2_amt_type == OrdersTermins::AMT_TYPE_PERCENT) && + $req->sell_termin2_amt > 0 + ) { + $ord_code_type = 6; + } else { + if ($req->sell_termin1_at < $req->points[0]["pickup_at"]) { + $ord_code_type = 5; + } else { + $ord_code_type = 7; + } + } + $ord_code = Helper::gnrtOrdCode($ord_code_type); + + $rate_code = $nanoid->formattedId("123456789", 6); + $doWhile = true; + do { + $uniqRateCode = ConfRates::getRateByCode($rate_code); + if (count($uniqRateCode) > 0) { + $rate_code = $nanoid->formattedId("123456789", 6); + } else { + $doWhile = false; + } + } while ($doWhile); + + $client = Clients::getClientById($clientAuth->client_group_id); + + // $rate = ConfRates::getRateById($req->lead_time_id); + // $pck_pic = Clients::getClientById($pckPoints[0]->client_group_id); + // $drop_pic = Clients::getClientById($dropPoints[0]->client_group_id); + $admins = Users::getUsersActiveByRole(Users::ROLE_ADMIN); + $device = Devices::getDeviceByDeviceId($device_id); + if (count($device) < 1 || $device === false) { + $device = []; + $device[0] = new \StdClass(); + $device[0]->id = 0; + $device[0]->name = "-"; + $device[0]->type = Devices::TYPE_BUILT_IN; + $device[0]->simcard_code = 62; + $device[0]->simcard = 0; + } + + $admins_data = []; + foreach ($admins as $k => $v) { + array_push($admins_data, [ + "admin_id" => $v->id, + "admin_name" => $v->first_name, + "admin_phone" => $v->phone_code . " " . implode(" ", str_split($v->phone, 4)), + "admin_mail" => $v->email, + "admin_addr" => "", + ]); + } + + $rate_id = 0; + DB::beginTransaction(); + $vendor = Users::getUserById($vdr->id); + + $buy_price = $req->buy_price_total_tax; + if ($req->buy_price_tax_type == OrdersAItems::AMT_TAX_TYPE_INCLUDE) { + $buy_price = $req->buy_price_base; + } elseif ($req->buy_price_tax_type == OrdersAItems::AMT_TAX_TYPE_EXCLUDE) { + $buy_price = $req->buy_price_total_tax; + } + $insOrd = [ + "code" => $ord_code, + "type" => Orders::TYPE_FCL, + "pck_total" => count($pckPoints), + "drop_total" => count($dropPoints), + "est_lead_time" => 0, + "lead_time" => 0, + "est_price" => 0, + "price" => 0, + "est_real_price" => 0, + "real_price" => 0, + "est_disc_price" => 0, + "disc_price" => 0, + "est_buy_price" => 0, + "buy_price" => 0, + "est_real_buy_price" => 0, + "real_buy_price" => 0, + "est_disc_buy_price" => $req->disc_buy_price ?? 0, + "disc_buy_price" => $req->disc_buy_price ?? 0, + "est_rate_id" => $rate_id, + "rate_id" => $rate_id, + "status" => Orders::STTS_HAVE_GET_VHC, + "crt_type_order" => $crt_type_order, + "crt" => $now, + "crt_by" => Auth::user()->id, + "crt_adm_by" => Auth::user()->id, + "updt" => $now, + "updt_by" => Auth::user()->id, + "confirm_at" => $now, + "confirm_by" => Auth::user()->id, + // 'find_vhc_at' => $now, + // 'find_vhc_by' => $req->auth->id, + ]; + $ord_id = Orders::addOrder($insOrd); + $driver = Drivers::showDriverById($drv_id); + $vehicle = Vehicles::showVehicleById($vhc_id); + if ($device[0]->id > 0) { + Devices::updateDevice($device[0]->id, [ + "is_assigned" => Devices::IS_ASSIGNED, + "is_available" => Devices::IS_UNAVAIL, + ]); + } + $pck_ids = []; + foreach ($pckPoints as $i => $pck) { + $insPck = [ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "set_pck_at" => $pck->inpt_set_pck_at, + "stts_pck" => OrdersPickups::STTS_WAIT, + "pck_id" => $pck->id, + "pck_name" => $pck->name, + "pck_desc" => $pck->desc, + "pck_type" => $pck->type, + "pck_workflow" => $pck->workflow_type, + "pck_shiptocode" => $pck->shiptocode, + "pck_prid" => $pck->prid, + "pck_ktid" => $pck->ktid, + "pck_kcid" => $pck->kcid, + "pck_klid" => $pck->klid, + "pck_addr" => $pck->fulladdress, + "pck_cgroup_id" => $pck->client_group_id, + "pck_cdiv_id" => $pck->client_div_id, + "pck_cgp_id" => $pck->client_gp_id, + "pck_hex_color" => $pck->boundary_hex_color, + "pck_shape" => $pck->boundary_type, + "pck_radius" => $pck->boundary_radius, + "pck_diameter" => $pck->boundary_diameter, + "pck_area" => $pck->boundary_area, + "pck_ha" => $pck->boundary_ha, + "pck_bounds" => $pck->boundary_bounds, + "pck_latlngs" => $pck->boundary_latlngs, + "pck_points" => $pck->boundary_points, + "pic_name" => $pck->inpt_pic_name, + "pic_phone_code" => $pck->inpt_pic_phone_code, + "pic_phone_val" => $pck->inpt_pic_phone_val, + "pic_mail" => $pck->inpt_pic_mail, + // 'pic_name' => $clientAuth->first_name, + // 'pic_phone_code' => $clientAuth->phone_code, + // 'pic_phone_val' => $clientAuth->phone, + // 'pic_mail' => $clientAuth->email, + ]; + $pck_id = OrdersPickups::add($insPck); + $pck_ids[] = $pck_id; + } + + $drop_ids = []; + $pck_drop_ids = []; + foreach ($dropPoints as $i => $drop) { + $insDrop = [ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "stts_drop" => OrdersDrops::STTS_WAIT, + "drop_id" => $drop->id, + "drop_name" => $drop->name, + "drop_desc" => $drop->desc, + "drop_type" => $drop->type, + "drop_workflow" => $drop->workflow_type, + "drop_shiptocode" => $drop->shiptocode, + "drop_prid" => $drop->prid, + "drop_ktid" => $drop->ktid, + "drop_kcid" => $drop->kcid, + "drop_klid" => $drop->klid, + "drop_addr" => $drop->fulladdress, + "drop_cgroup_id" => $drop->client_group_id, + "drop_cdiv_id" => $drop->client_div_id, + "drop_cgp_id" => $drop->client_gp_id, + "drop_hex_color" => $drop->boundary_hex_color, + "drop_shape" => $drop->boundary_type, + "drop_radius" => $drop->boundary_radius, + "drop_diameter" => $drop->boundary_diameter, + "drop_area" => $drop->boundary_area, + "drop_ha" => $drop->boundary_ha, + "drop_bounds" => $drop->boundary_bounds, + "drop_latlngs" => $drop->boundary_latlngs, + "drop_points" => $drop->boundary_points, + "pic_name" => $drop->inpt_pic_name, + "pic_phone_code" => $drop->inpt_pic_phone_code, + "pic_phone_val" => $drop->inpt_pic_phone_val, + "pic_mail" => $drop->inpt_pic_mail, + // 'pic_name' => $clientAuth->first_name, + // 'pic_phone_code' => $clientAuth->phone_code, + // 'pic_phone_val' => $clientAuth->phone, + // 'pic_mail' => $clientAuth->email, + ]; + $drop_id = OrdersDrops::add($insDrop); + $drop_ids[] = $drop_id; + + $pck_drop_id = OrdersPckDrop::add([ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "pck_id" => $pck_ids[$i], + "drop_id" => $drop_ids[$i], + "is_active" => 1, + "stts" => OrdersPckDrop::STTS_DELIVERY_OTW_PICKUP, + "crt" => $now, + "crt_by" => Auth::user()->id, + "updt" => $now, + "updt_by" => Auth::user()->id, + ]); + + foreach ($req->checklist[$i] as $_checklist) { + $checklist = DB::table("t_conf_checklists") + ->where("id", $_checklist) + ->first(); + $dt_insert = [ + "did" => $drv_id, + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "pck_id" => $pck_ids[$i], + "drop_id" => $drop_ids[$i], + "ord_pck_drop_id" => $pck_drop_id, + "checklist_id" => $checklist->id, + "checklist_name" => $checklist->name, + "checklist_desc" => $checklist->desc, + "crt" => $now, + "crt_by" => Auth::user()->id, + "updt" => $now, + "updt_by" => Auth::user()->id, + ]; + $insertChecklist = DB::table("t_orders_drivers_uploads")->insert($dt_insert); + } + } + + $insClient = [ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "c_id" => $clientAuth->uid, + "c_name" => $clientAuth->first_name, + "c_phone_code" => $clientAuth->phone_code, + "c_phone_val" => $clientAuth->phone, + "c_mail" => $clientAuth->email, + "c_addr" => $clientAuth->fulladdress, + "c_disc_type" => $client[0]->disc_type, + "c_disc_amount" => $client[0]->disc_amount, + "c_pt_id" => $client[0]->id, + "c_pt_div_id" => $clientAuth->client_div_id, + "c_pt_gp_id" => $clientAuth->client_gp_id, + "c_pt_name" => $client[0]->c_name, + "c_pt_phone_code" => $client[0]->c_phone_code, + "c_pt_phone_val" => $client[0]->c_phone, + "c_pt_mail" => $client[0]->c_mail, + "c_pt_addr" => $client[0]->c_addr_office, + "c_pt_pic_name" => $client[0]->pic_name, + "c_pt_pic_phone_code" => $client[0]->pic_phone_code, + "c_pt_pic_phone_val" => $client[0]->pic_phone, + "c_pt_pic_mail" => $client[0]->pic_mail, + "c_pt_pic_addr" => null, + "prefer_truck_type" => $req->truck_type_id, + "is_pkp" => 0, + ]; + $ord_client_id = OrdersClients::add($insClient); + + // if ($req->is_vdr_bcng != Users::IS_VDR_BCNG_YES) { + // $insRate = [ + // "ord_id" => $ord_id, + // "ord_code" => $ord_code, + // "rate_id" => $rate_id, + // "rate_code" => $rate_code, + // "origin_prov" => $insRate["origin_prov"], + // "origin_city" => $insRate["origin_city"], + // "origin_district" => $insRate["origin_district"], + // "origin_village" => $insRate["origin_village"], + // "lane" => $insRate["lane"], + // "dest_prov" => $insRate["dest_prov"], + // "dest_city" => $insRate["dest_city"], + // "dest_district" => $insRate["dest_district"], + // "dest_village" => $insRate["dest_village"], + // "fast_time" => $insRate["fast_time"], + // "long_time" => $insRate["long_time"], + // "unit_time" => $insRate["unit_time"], + // "sell_kg" => $insRate["sell_kg"], + // "buy_kg" => $insRate["buy_kg"], + // "margin_kg" => $insRate["margin_kg"], + // "percent_kg" => $insRate["percent_kg"], + // "sell_cbm" => $insRate["sell_cbm"], + // "buy_cbm" => $insRate["buy_cbm"], + // "margin_cbm" => $insRate["margin_cbm"], + // "percent_cbm" => $insRate["percent_cbm"], + // "sell_ftl" => $insRate["sell_ftl"], + // "buy_ftl" => $insRate["buy_ftl"], + // "margin_ftl" => $insRate["margin_ftl"], + // "percent_ftl" => $insRate["percent_ftl"], + // "vdr_id" => $insRate["vdr_id"], + // "vhc_type" => $insRate["vhc_type"], + // "crt_type" => $insRate["crt_type"], + // ]; + // OrdersRates::add($insRate); + // } + + if ($req->is_insurance == "true") { + // if (count($insurance) > 0) { + $insurance = StaticInsurances::listStaticInsurances([ + "is_active" => StaticInsurances::IS_ACTIVE, + ]); + $beneficiary = $req->amt_beneficiary ?? 0; // nilai pertangguhan + $calcPercent = ($beneficiary * $insurance[0]->amt_percent) / 100; + $flatPercent = $beneficiary - $calcPercent; + $insInsurance = [ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "insurance_id" => 0, + "premi_name" => $insurance[0]->desc, + "premi_price" => $calcPercent, + "amt_beneficiary" => $beneficiary, + "amt_percent" => $insurance[0]->amt_percent, + "amt_type" => OrdersInsurances::AMT_TYPE_PERCENT, + "premi_min_price" => $beneficiary, + "premi_max_price" => $beneficiary, + "desc" => $insurance[0]->desc, + ]; + OrdersInsurances::add($insInsurance); + } + + $vdrCompany = Clients::getClientById($vendor[0]->client_group_id); + $insVendors = [ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "vdr_id" => $vendor[0]->id, + "vdr_name" => $vendor[0]->first_name, + "vdr_mail" => $vendor[0]->email, + "vdr_phone_code" => $vendor[0]->phone_code, + "vdr_phone_val" => $vendor[0]->phone, + "vdr_addr" => $vendor[0]->fulladdress, + "vdr_cgroup_id" => $vendor[0]->client_group_id, + "vdr_pt_name" => $vdrCompany[0]->c_name, + "vdr_pt_phone_code" => $vdrCompany[0]->c_phone_code, + "vdr_pt_phone_val" => $vdrCompany[0]->c_phone, + "vdr_pt_mail" => $vdrCompany[0]->c_mail, + "vdr_pt_addr" => $vdrCompany[0]->c_addr_office, + "vdr_pt_pic_name" => $vdrCompany[0]->pic_name, + "vdr_pt_pic_phone_code" => $vdrCompany[0]->pic_phone_code, + "vdr_pt_pic_phone_val" => $vdrCompany[0]->pic_phone, + "vdr_pt_pic_mail" => $vdrCompany[0]->pic_mail, + "vdr_bank_id" => $vendor[0]->bank_id, + "vdr_bank_code" => $vendor[0]->bank_code, + "vdr_bank_short_name" => $vendor[0]->bank_short_name, + "vdr_bank_name" => $vendor[0]->bank_name, + "vdr_bank_branch_name" => $vendor[0]->bank_branch_name, + "vdr_bank_acc_number" => $vendor[0]->bank_acc_number, + "vdr_bank_acc_name" => $vendor[0]->bank_acc_name, + "is_vdr_bcng" => 0, + "find_vhcs" => $vhc_id, + "find_radius" => 0, + "find_shape" => Zone::ZONE_BOUNDARY_CIRCLE, + "find_center_lat" => 0, + "find_center_lng" => 0, + "distance" => 0, + "is_exp" => OrdersVendors::LINK_NOT_EXP, + "exp_at" => 0, // strtotime('+10 minutes', $now), // strtotime('+1 day', $now) + "bid_token" => (new Nanoid())->generateId(36), + "is_mailing_bid" => OrdersVendors::IS_MAILING_BID_NOT, + "is_mailing_bid_at" => 0, + "is_want" => OrdersVendors::IS_WANT_YES, + "is_want_at" => $now, + "status" => OrdersVendors::STTS_ACC, + "respond_at" => $now, + "is_pkp" => 0, + "crt" => $now, + ]; + OrdersVendors::add($insVendors); + + OrdersDrivers::add([ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "vdr_id" => $driver[0]->vendor_id, + "drv_id" => $driver[0]->id, + "drv_name" => $driver[0]->fullname, + "drv_mail" => $driver[0]->email, + "drv_name2" => $driver[0]->fullname2, + "drv_phone_code" => $driver[0]->phone_code, + "drv_phone_val" => $driver[0]->phone, + "drv_phone2_code" => $driver[0]->phone2_code, + "drv_phone2_val" => $driver[0]->phone2, + "drv_addr" => $driver[0]->fulladdress, + "drv_cgroup_id" => $driver[0]->client_group_id, + "drv_nik" => $driver[0]->nik, + "drv_dob" => $driver[0]->dob, + "drv_age" => Helper::countAge($driver[0]->dob), + "drv_gender" => $driver[0]->gender, + "drv_blood" => $driver[0]->blood, + "em_fullname" => $driver[0]->em_fullname, + "em_phone_code" => $driver[0]->em_phone_code, + "em_phone_val" => $driver[0]->em_phone, + "em_relationship" => $driver[0]->em_relationship, + "drv_ktp_img" => $driver[0]->ktp_img, + "drv_npwp_img" => $driver[0]->npwp_img, + "drv_npwp_number" => $driver[0]->npwp_number, + "drv_npwp_string" => $driver[0]->npwp_string, + "drv_license_img" => $driver[0]->license_img, + "drv_license_number" => $driver[0]->license_number, + "drv_license_exp" => $driver[0]->license_exp, + "drv_bank_id" => $req->drv_bank_id ?? 0, + "drv_bank_code" => $req->drv_bank_code ?? null, + "drv_bank_short_name" => $req->drv_bank_short ?? null, + "drv_bank_name" => $req->drv_bank_name ?? null, + "drv_bank_branch_name" => $req->drv_bank_branch_name ?? null, + "drv_bank_acc_number" => $req->drv_bank_acc_number ?? null, + "drv_bank_acc_name" => $req->drv_bank_acc_name ?? null, + ]); + OrdersVehicles::add([ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "vhc_id" => $vehicle[0]->vid, + "vhc_name" => $vehicle[0]->name, + "vhc_dvc_id" => $device[0]->id, + "vhc_dvc_name" => $device[0]->name, + "vhc_dvc_type" => $device[0]->type, + "vhc_device_id" => $vehicle[0]->device_id, + "vhc_simcard_code" => $device[0]->simcard_code, + "vhc_simcard" => $device[0]->simcard, + "vhc_cat_id" => $vehicle[0]->cat_id, + "vhc_brand_id" => $vehicle[0]->brand_id, + "vhc_type_id" => $vehicle[0]->type_id, + "vhc_model_id" => $vehicle[0]->model_id, + "vhc_c_did" => $vehicle[0]->c_did, + "vhc_a_did" => $vehicle[0]->a_did, + "vhc_nopol1" => $vehicle[0]->nopol1, + "vhc_nopol2" => $vehicle[0]->nopol2, + "vhc_nopol3" => $vehicle[0]->nopol3, + "vhc_is_track_holiday" => $vehicle[0]->is_track_holiday, + "vhc_track_sch_d" => $vehicle[0]->track_sch_d, + "vhc_track_sch_h" => $vehicle[0]->track_sch_h, + "vhc_cgroup_id" => $vehicle[0]->client_group_id, + "vhc_vdr_id" => $vehicle[0]->vendor_id, + "vhc_speed_limit" => $vehicle[0]->speed_limit, + "vhc_fuel_capacity" => $vehicle[0]->fuel_capacity, + "vhc_fuel_drop_treshold" => $vehicle[0]->fuel_drop_treshold, + "vhc_max_pressure" => $vehicle[0]->max_pressure, + "vhc_fvhc_img" => $vehicle[0]->fvhc_img, + "vhc_stnk_img" => $vehicle[0]->stnk_img, + "vhc_stnk_exp" => $vehicle[0]->stnk_exp, + "vhc_vyear" => $vehicle[0]->vyear, + "vhc_cc" => $vehicle[0]->cc, + "vhc_vin" => $vehicle[0]->vin, + "vhc_en" => $vehicle[0]->en, + "vhc_vcolor" => $vehicle[0]->vcolor, + "vhc_fuel_type" => $vehicle[0]->fuel_type, + "vhc_tnkb_color" => $vehicle[0]->tnkb_color, + "vhc_regis_year" => $vehicle[0]->regis_year, + "vhc_tax_exp" => $vehicle[0]->tax_exp, + ]); + + if ($req->is_vdr_bcng == Users::IS_VDR_BCNG_YES) { + // $req->pocket_id + // $req->pocket_type + // $req->pocket_checkpoints + $pocket = PocketMoney::showPocketById($req->pocket_id); + if (count($pocket) < 1) { + $apiResp = Responses::not_found("uang saku belum dipilih"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + $ord_pocket_id = OrdersPockets::addPocket([ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "pocket_id" => $pocket[0]->id, + "pocket_code" => $pocket[0]->code, + "pocket_name" => $pocket[0]->name, + "pck_id" => $pocket[0]->pck_id, + "drop_id" => $pocket[0]->drop_id, + "pocket_type" => $pocket[0]->type, + "pocket_flow" => $pocket[0]->flow, + "pocket_is_active" => $pocket[0]->is_active, + "pocket_total" => $pocket[0]->total, + "crt" => $now, + "crt_by" => $req->auth->uid, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]); + // order_pocket_id + $pocket[0]->checkpoints = Checkpoints::listCheckpoints([ + "pocket_id" => $pocket[0]->id, + ]); + foreach ($pocket[0]->checkpoints as $checkpoint) { + OrdersCheckpoints::addCheckpoint([ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "ord_pocket_id" => $ord_pocket_id, + "pocket_id" => $checkpoint->pocket_id, + "pck_id" => $checkpoint->pck_id, + "drop_id" => $checkpoint->drop_id, + "pocket_sort" => $checkpoint->sort, + "pocket_fee" => $checkpoint->pocket_fee, + "pocket_tol_fee" => $checkpoint->tol_fee, + "pocket_fuel_fee" => $checkpoint->fuel_fee, + "pocket_total" => $checkpoint->total, + "crt" => $now, + "crt_by" => $req->auth->uid, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]); + } + } + + $main_item_dec = + "Pengantaran Logistik
" . + ucwords(strtolower($pckPoints[0]->prid_name)) . + " - " . + ucwords(strtolower($dropPoints[0]->prid_name)) . + "
" . + date("d F Y", $insPck["set_pck_at"]); + $main_item_dec = + "Pengantaran Logistik
" . + ucwords(strtolower($pckPoints[0]->prid_name)) . + " - " . + ucwords(strtolower($dropPoints[0]->prid_name)) . + "
" . + strftime("%d %B %Y", $insPck["set_pck_at"]); + $main_item_dec = + "Pengantaran Logistik
" . + ucwords(strtolower($pckPoints[0]->ktid_name)) . + " - " . + ucwords(strtolower($dropPoints[0]->ktid_name)) . + "
" . + ucwords(strtolower($dropPoints[0]->name)) . + ", " . + ucwords(strtolower($dropPoints[0]->prid_name)) . + " - " . + $dropPoints[0]->shiptocode . + "
" . + strftime("%d %m %Y", $insPck["set_pck_at"]) . + "
" . + $req->note_tonase; + + if ($req->is_vdr_bcng == Users::IS_VDR_BCNG_YES) { + $req->termin1_amt_type = OrdersTermins::AMT_TYPE_PERCENT; + $req->buy_price = 0; + $req->buy_price_tax_type = 0; + $req->buy_price_tax_ppn_percent = 0; + $req->buy_price_tax_ppn_flat = 0; + $req->buy_price_tax_pph_percent = 0; + $req->buy_price_tax_pph_flat = 0; + $req->buy_price_total_tax = 0; + $req->termin1_amt = 0; + $req->termin1_calc_percent = 0; + $req->termin1_at = 0; + $req->termin1_calc_percent_base = 0; + } + + $v_termin_sequence = 0; + $v_termin1_id = 0; + $v_termin2_id = 0; + + if ( + $req->termin1_amt_type == OrdersTermins::AMT_TYPE_FLAT || + $req->termin1_amt_type == OrdersTermins::AMT_TYPE_PERCENT + ) { + ++$v_termin_sequence; + $insTerminsVdr1 = [ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "flow_type" => OrdersTermins::FLOW_TYPE_PAYMENT, + "cash_type" => OrdersTermins::TYPE_CASH_OUT, + "sequence" => $v_termin_sequence, + "termin_base_flat" => $req->buy_price, + "termin_tax_type" => $req->buy_price_tax_type, + "termin_tax_ppn_percent" => $req->buy_price_tax_ppn_percent ?? 0, + "termin_tax_ppn_flat" => $req->buy_price_tax_ppn_flat ?? 0, + "termin_tax_pph_percent" => $req->buy_price_tax_pph_percent ?? 0, + "termin_tax_pph_flat" => $req->buy_price_tax_pph_flat ?? 0, + "termin_total_tax_flat" => $req->buy_price_total_tax ?? 0, + "termin_amt_type" => $req->termin1_amt_type ?? 0, + "termin_amt" => $req->termin1_amt ?? 0, + "termin_calc_percent" => $req->termin1_calc_percent ?? 0, + "termin_result_flat" => + $req->termin1_amt_type == OrdersTermins::AMT_TYPE_FLAT + ? $req->termin1_amt + : $req->termin1_calc_percent, + "termin_ddln_at" => $req->termin1_at ?? 0, + "termin_ddln_type" => OrdersTermins::DDLN_TERMIN_TYPE_TIME, + "termin_for" => OrdersTermins::TERMIN_FOR_VENDOR, + "crt" => $now, + "crt_by" => $req->auth->uid, + "crt_type" => OrdersTermins::CRT_TYPE_ADMIN, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]; + // dd($insTerminsVdr1); + $v_termin1_id = OrdersTermins::add($insTerminsVdr1); + $qty = 1; + $amt_base_flat = + $req->termin1_amt_type == OrdersTermins::AMT_TYPE_FLAT + ? $req->termin1_amt + : $req->termin1_calc_percent_base; + $yang_dijadiin_summary = $insTerminsVdr1["termin_result_flat"]; + if ($req->buy_price_tax_type == OrdersAItems::AMT_TAX_TYPE_INCLUDE) { + // $yang_dijadiin_summary = $amt_base_flat; + $yang_dijadiin_summary = $insTerminsVdr1["termin_result_flat"]; + } elseif ($req->buy_price_tax_type == OrdersAItems::AMT_TAX_TYPE_EXCLUDE) { + $yang_dijadiin_summary = $insTerminsVdr1["termin_result_flat"]; + } + OrdersAItems::add([ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "flow_type" => OrdersAItems::FLOW_TYPE_PAYMENT, + "cash_type" => OrdersAItems::TYPE_CASH_OUT, + "v_termin_id" => $v_termin1_id, + "a_item_type" => OrdersAItems::A_TYPE_PRIMARY, + // 'desc' => $main_item_dec . "
Pembayaran termin 1", + "desc" => $main_item_dec, + "unit_id" => 0, + "unit_type" => UnitTypes::UNIT_TYPE_PAKET, + "unit_qty" => $qty, + "amt_base_flat" => $amt_base_flat, + "amt_tax_type" => $req->buy_price_tax_type, + "amt_tax_ppn_percent" => $req->buy_price_tax_ppn_percent ?? 0, + "amt_tax_ppn_flat" => $req->buy_price_tax_ppn_flat ?? 0, + "amt_tax_pph_percent" => $req->buy_price_tax_pph_percent ?? 0, + "amt_tax_pph_flat" => $req->buy_price_tax_pph_flat ?? 0, + "amt_total_tax_flat" => $insTerminsVdr1["termin_result_flat"], + "amt_result_flat" => $insTerminsVdr1["termin_result_flat"], + "amt_total_flat" => $yang_dijadiin_summary * $qty, + "ddln_pay_at" => $insTerminsVdr1["termin_ddln_at"], + "ddln_pay_type" => OrdersAItems::DDLN_PAY_TYPE_TIME, + "img_proof_submission" => null, + "img_proof_payment" => null, + "bank_id" => $insVendors["vdr_bank_id"], + "bank_code" => $insVendors["vdr_bank_code"], + "bank_name" => $insVendors["vdr_bank_name"], + "bank_short_name" => $insVendors["vdr_bank_short_name"], + "bank_acc_number" => $insVendors["vdr_bank_acc_number"], + "bank_acc_name" => $insVendors["vdr_bank_acc_name"], + "invc_to_client" => OrdersAItems::INVC_TO_CLIENT_NO, + "calc_to_vdr" => OrdersAItems::CALC_TO_VDR_YES, + "only_vdr" => OrdersAItems::ONLY_VDR_YES, + "ref_ord_id" => $ord_id, + "ref_ord_code" => $ord_code, + "ref_v_termin_id" => $v_termin1_id, + "crt" => $now, + "crt_by" => $req->auth->uid, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]); + } + if ( + ($req->termin2_amt_type == OrdersTermins::AMT_TYPE_FLAT || + $req->termin2_amt_type == OrdersTermins::AMT_TYPE_PERCENT) && + $req->termin2_amt > 0 + ) { + ++$v_termin_sequence; + $insTerminsVdr2 = [ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "flow_type" => OrdersTermins::FLOW_TYPE_PAYMENT, + "cash_type" => OrdersTermins::TYPE_CASH_OUT, + "sequence" => $v_termin_sequence, + "termin_base_flat" => $req->buy_price, + "termin_tax_type" => $req->buy_price_tax_type, + "termin_tax_ppn_percent" => $req->buy_price_tax_ppn_percent ?? 0, + "termin_tax_ppn_flat" => $req->buy_price_tax_ppn_flat ?? 0, + "termin_tax_pph_percent" => $req->buy_price_tax_pph_percent ?? 0, + "termin_tax_pph_flat" => $req->buy_price_tax_pph_flat ?? 0, + "termin_total_tax_flat" => $req->buy_price_total_tax ?? 0, + "termin_amt_type" => $req->termin2_amt_type ?? 0, + "termin_amt" => $req->termin2_amt ?? 0, + "termin_calc_percent" => $req->termin2_calc_percent ?? 0, + "termin_result_flat" => + $req->termin2_amt_type == OrdersTermins::AMT_TYPE_FLAT + ? $req->termin2_amt + : $req->termin2_calc_percent, + "termin_ddln_at" => $req->termin2_at ?? 0, + "termin_ddln_type" => OrdersTermins::DDLN_TERMIN_TYPE_ORD_FINISH, + "termin_for" => OrdersTermins::TERMIN_FOR_VENDOR, + "crt" => $now, + "crt_by" => $req->auth->uid, + "crt_type" => OrdersTermins::CRT_TYPE_ADMIN, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]; + $v_termin2_id = OrdersTermins::add($insTerminsVdr2); + $qty = 1; + $amt_base_flat = + $req->termin2_amt_type == OrdersTermins::AMT_TYPE_FLAT + ? $req->termin2_amt + : $req->termin2_calc_percent_base; + $yang_dijadiin_summary = $insTerminsVdr2["termin_result_flat"]; + if ($req->buy_price_tax_type == OrdersAItems::AMT_TAX_TYPE_INCLUDE) { + // $yang_dijadiin_summary = $amt_base_flat; + $yang_dijadiin_summary = $insTerminsVdr2["termin_result_flat"]; + } elseif ($req->buy_price_tax_type == OrdersAItems::AMT_TAX_TYPE_EXCLUDE) { + $yang_dijadiin_summary = $insTerminsVdr2["termin_result_flat"]; + } + OrdersAItems::add([ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "flow_type" => OrdersAItems::FLOW_TYPE_PAYMENT, + "cash_type" => OrdersAItems::TYPE_CASH_OUT, + "v_termin_id" => $v_termin2_id, + "a_item_type" => OrdersAItems::A_TYPE_PRIMARY, + // 'desc' => $main_item_dec . "
Pembayaran termin 2", + "desc" => $main_item_dec, + "unit_id" => 0, + "unit_type" => UnitTypes::UNIT_TYPE_PAKET, + "unit_qty" => $qty, + "amt_base_flat" => $amt_base_flat, + "amt_tax_type" => $req->buy_price_tax_type, + "amt_tax_ppn_percent" => $req->buy_price_tax_ppn_percent ?? 0, + "amt_tax_ppn_flat" => $req->buy_price_tax_ppn_flat ?? 0, + "amt_tax_pph_percent" => $req->buy_price_tax_pph_percent ?? 0, + "amt_tax_pph_flat" => $req->buy_price_tax_pph_flat ?? 0, + "amt_total_tax_flat" => $insTerminsVdr2["termin_result_flat"], + "amt_result_flat" => $insTerminsVdr2["termin_result_flat"], + "amt_total_flat" => $yang_dijadiin_summary * $qty, + "ddln_pay_at" => $insTerminsVdr2["termin_ddln_at"], + "ddln_pay_type" => OrdersAItems::DDLN_PAY_TYPE_ORD_FINISH, + "img_proof_submission" => null, + "img_proof_payment" => null, + "bank_id" => $insVendors["vdr_bank_id"], + "bank_code" => $insVendors["vdr_bank_code"], + "bank_name" => $insVendors["vdr_bank_name"], + "bank_short_name" => $insVendors["vdr_bank_short_name"], + "bank_acc_number" => $insVendors["vdr_bank_acc_number"], + "bank_acc_name" => $insVendors["vdr_bank_acc_name"], + "invc_to_client" => OrdersAItems::INVC_TO_CLIENT_NO, + "calc_to_vdr" => OrdersAItems::CALC_TO_VDR_YES, + "only_vdr" => OrdersAItems::ONLY_VDR_YES, + "ref_ord_id" => $ord_id, + "ref_ord_code" => $ord_code, + "ref_v_termin_id" => $v_termin2_id, + "crt" => $now, + "crt_by" => $req->auth->uid, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]); + } + if ($v_termin_sequence === 0) { + $req->termin1_amt_type = OrdersTermins::AMT_TYPE_FLAT; + $req->termin1_amt = $req->buy_price; + $req->termin1_amt_at = strtotime("+2 days", $now); + $req->termin1_calc_percent = 0; + ++$v_termin_sequence; + $insTerminsVdr1 = [ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "flow_type" => OrdersTermins::FLOW_TYPE_PAYMENT, + "cash_type" => OrdersTermins::TYPE_CASH_OUT, + "sequence" => $v_termin_sequence, + "termin_base_flat" => $req->buy_price, + "termin_tax_type" => $req->buy_price_tax_type, + "termin_tax_ppn_percent" => $req->buy_price_tax_ppn_percent ?? 0, + "termin_tax_ppn_flat" => $req->buy_price_tax_ppn_flat ?? 0, + "termin_tax_pph_percent" => $req->buy_price_tax_pph_percent ?? 0, + "termin_tax_pph_flat" => $req->buy_price_tax_pph_flat ?? 0, + "termin_total_tax_flat" => $req->buy_price_total_tax ?? 0, + "termin_amt_type" => $req->termin1_amt_type ?? 0, + "termin_amt" => $req->termin1_amt ?? 0, + "termin_calc_percent" => $req->termin1_calc_percent ?? 0, + "termin_result_flat" => + $req->termin1_amt_type == OrdersTermins::AMT_TYPE_FLAT + ? $req->termin1_amt + : $req->termin1_calc_percent, + "termin_ddln_at" => $req->termin1_at ?? 0, + "termin_ddln_type" => OrdersTermins::DDLN_TERMIN_TYPE_ORD_FINISH, + "termin_for" => OrdersTermins::TERMIN_FOR_VENDOR, + "crt" => $now, + "crt_by" => $req->auth->uid, + "crt_type" => OrdersTermins::CRT_TYPE_ADMIN, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]; + $v_termin1_id = OrdersTermins::add($insTerminsVdr1); + $qty = 1; + $amt_base_flat = + $req->termin1_amt_type == OrdersTermins::AMT_TYPE_FLAT + ? $req->termin1_amt + : $req->termin1_calc_percent_base; + $yang_dijadiin_summary = $insTerminsVdr1["termin_result_flat"]; + if ($req->buy_price_tax_type == OrdersAItems::AMT_TAX_TYPE_INCLUDE) { + // $yang_dijadiin_summary = $amt_base_flat; + $yang_dijadiin_summary = $insTerminsVdr1["termin_result_flat"]; + } elseif ($req->buy_price_tax_type == OrdersAItems::AMT_TAX_TYPE_EXCLUDE) { + $yang_dijadiin_summary = $insTerminsVdr1["termin_result_flat"]; + } + OrdersAItems::add([ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "flow_type" => OrdersAItems::FLOW_TYPE_PAYMENT, + "cash_type" => OrdersAItems::TYPE_CASH_OUT, + "v_termin_id" => $v_termin1_id, + "a_item_type" => OrdersAItems::A_TYPE_PRIMARY, + // 'desc' => $main_item_dec . "
Pembayaran termin 1", + "desc" => $main_item_dec, + "unit_id" => 0, + "unit_type" => UnitTypes::UNIT_TYPE_PAKET, + "unit_qty" => $qty, + "amt_base_flat" => $amt_base_flat, + "amt_tax_type" => $req->buy_price_tax_type, + "amt_tax_ppn_percent" => $req->buy_price_tax_ppn_percent ?? 0, + "amt_tax_ppn_flat" => $req->buy_price_tax_ppn_flat ?? 0, + "amt_tax_pph_percent" => $req->buy_price_tax_pph_percent ?? 0, + "amt_tax_pph_flat" => $req->buy_price_tax_pph_flat ?? 0, + "amt_total_tax_flat" => $insTerminsVdr1["termin_result_flat"], + "amt_result_flat" => $insTerminsVdr1["termin_result_flat"], + "amt_total_flat" => $yang_dijadiin_summary * $qty, + "ddln_pay_at" => $insTerminsVdr1["termin_ddln_at"], + "ddln_pay_type" => OrdersAItems::DDLN_PAY_TYPE_ORD_FINISH, + "img_proof_submission" => null, + "img_proof_payment" => null, + "bank_id" => $insVendors["vdr_bank_id"], + "bank_code" => $insVendors["vdr_bank_code"], + "bank_name" => $insVendors["vdr_bank_name"], + "bank_short_name" => $insVendors["vdr_bank_short_name"], + "bank_acc_number" => $insVendors["vdr_bank_acc_number"], + "bank_acc_name" => $insVendors["vdr_bank_acc_name"], + "invc_to_client" => OrdersAItems::INVC_TO_CLIENT_NO, + "calc_to_vdr" => OrdersAItems::CALC_TO_VDR_YES, + "only_vdr" => OrdersAItems::ONLY_VDR_YES, + "ref_ord_id" => $ord_id, + "ref_ord_code" => $ord_code, + "ref_v_termin_id" => $v_termin1_id, + "crt" => $now, + "crt_by" => $req->auth->uid, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]); + } + + $c_termin_sequence = 0; + $c_termin1_id = 0; + $c_termin2_id = 0; + if ( + $req->sell_termin1_amt_type == OrdersTermins::AMT_TYPE_FLAT || + $req->sell_termin1_amt_type == OrdersTermins::AMT_TYPE_PERCENT + ) { + ++$c_termin_sequence; + $insTerminsC1 = [ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "flow_type" => OrdersTermins::FLOW_TYPE_BILLING, + "cash_type" => OrdersTermins::TYPE_CASH_IN, + "sequence" => $c_termin_sequence, + "termin_base_flat" => $req->sell_price, + "termin_tax_type" => OrdersAItems::AMT_TAX_TYPE_EXCLUDE, + "termin_tax_ppn_percent" => OrdersAItems::PPN_PERCENT, + "termin_tax_pph_percent" => OrdersAItems::PPH_PERCENT, + "termin_amt_type" => $req->sell_termin1_amt_type ?? 0, + "termin_amt" => $req->sell_termin1_amt ?? 0, + "termin_calc_percent" => $req->sell_termin1_calc_percent ?? 0, + "termin_result_flat" => + $req->sell_termin1_amt_type == OrdersTermins::AMT_TYPE_FLAT + ? $req->sell_termin1_amt + : $req->sell_termin1_calc_percent, + "termin_ddln_at" => $req->sell_termin1_at ?? 0, + "termin_ddln_type" => OrdersTermins::DDLN_TERMIN_TYPE_TIME, + "termin_for" => OrdersTermins::TERMIN_FOR_CLIENT, + "crt" => $now, + "crt_by" => $req->auth->uid, + "crt_type" => OrdersTermins::CRT_TYPE_ADMIN, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]; + $c_termin1_id = OrdersTermins::add($insTerminsC1); + $qty = 1; + OrdersAItems::add([ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "flow_type" => OrdersAItems::FLOW_TYPE_BILLING, + "cash_type" => OrdersAItems::TYPE_CASH_IN, + "c_termin_id" => $c_termin1_id, + "a_item_type" => OrdersAItems::A_TYPE_PRIMARY, + // 'desc' => $main_item_dec . "
Pembayaran termin 1", + "desc" => $main_item_dec, + "unit_id" => 0, + "unit_type" => UnitTypes::UNIT_TYPE_PAKET, + "unit_qty" => $qty, + "amt_bill_base_flat" => $insTerminsC1["termin_result_flat"], + "amt_bill_result_flat" => $insTerminsC1["termin_result_flat"], + "amt_bill_total_flat" => $insTerminsC1["termin_result_flat"] * $qty, + "ddln_pay_at" => $insTerminsC1["termin_ddln_at"], + "ddln_pay_type" => OrdersAItems::DDLN_PAY_TYPE_TIME, + "img_proof_submission" => null, + "img_proof_payment" => null, + "bank_id" => Banks::DFT_BANK_ID, + "bank_code" => Banks::DFT_BANK_CODE, + "bank_name" => Banks::DFT_BANK_NAME, + "bank_short_name" => Banks::DFT_BANK_SHORT_NAME, + "bank_acc_number" => Banks::DFT_BANK_ACC_NUMBER, + "bank_acc_name" => Banks::DFT_BANK_ACC_NAME, + "invc_to_client" => OrdersAItems::INVC_TO_CLIENT_YES, + "calc_to_vdr" => OrdersAItems::CALC_TO_VDR_NO, + "only_client" => OrdersAItems::ONLY_CLIENT_YES, + "ref_ord_id" => $ord_id, + "ref_ord_code" => $ord_code, + "ref_c_termin_id" => $c_termin1_id, + "crt" => $now, + "crt_by" => $req->auth->uid, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]); + } + if ( + ($req->sell_termin2_amt_type == OrdersTermins::AMT_TYPE_FLAT || + $req->sell_termin2_amt_type == OrdersTermins::AMT_TYPE_PERCENT) && + $req->sell_termin2_amt > 0 + ) { + ++$c_termin_sequence; + $insTerminsC2 = [ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "flow_type" => OrdersTermins::FLOW_TYPE_BILLING, + "cash_type" => OrdersTermins::TYPE_CASH_IN, + "sequence" => $c_termin_sequence, + "termin_base_flat" => $req->sell_price, + "termin_tax_type" => OrdersAItems::AMT_TAX_TYPE_EXCLUDE, + "termin_tax_ppn_percent" => OrdersAItems::PPN_PERCENT, + "termin_tax_pph_percent" => OrdersAItems::PPH_PERCENT, + "termin_amt_type" => $req->sell_termin2_amt_type ?? 0, + "termin_amt" => $req->sell_termin2_amt ?? 0, + "termin_calc_percent" => $req->sell_termin2_calc_percent ?? 0, + "termin_result_flat" => + $req->sell_termin2_amt_type == OrdersTermins::AMT_TYPE_FLAT + ? $req->sell_termin2_amt + : $req->sell_termin2_calc_percent, + "termin_ddln_at" => $req->sell_termin2_at ?? 0, + "termin_ddln_type" => OrdersTermins::DDLN_TERMIN_TYPE_ORD_FINISH, + "termin_for" => OrdersTermins::TERMIN_FOR_CLIENT, + "crt" => $now, + "crt_by" => $req->auth->uid, + "crt_type" => OrdersTermins::CRT_TYPE_ADMIN, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]; + $c_termin2_id = OrdersTermins::add($insTerminsC2); + $qty = 1; + OrdersAItems::add([ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "flow_type" => OrdersAItems::FLOW_TYPE_BILLING, + "cash_type" => OrdersAItems::TYPE_CASH_IN, + "c_termin_id" => $c_termin2_id, + "a_item_type" => OrdersAItems::A_TYPE_PRIMARY, + // 'desc' => $main_item_dec . "
Pembayaran termin 2", + "desc" => $main_item_dec, + "unit_id" => 0, + "unit_type" => UnitTypes::UNIT_TYPE_PAKET, + "unit_qty" => $qty, + "amt_bill_base_flat" => $insTerminsC2["termin_result_flat"], + "amt_bill_result_flat" => $insTerminsC2["termin_result_flat"], + "amt_bill_total_flat" => $insTerminsC2["termin_result_flat"] * $qty, + "ddln_pay_at" => $insTerminsC2["termin_ddln_at"], + "ddln_pay_type" => OrdersAItems::DDLN_PAY_TYPE_ORD_FINISH, + "img_proof_submission" => null, + "img_proof_payment" => null, + "bank_id" => Banks::DFT_BANK_ID, + "bank_code" => Banks::DFT_BANK_CODE, + "bank_name" => Banks::DFT_BANK_NAME, + "bank_short_name" => Banks::DFT_BANK_SHORT_NAME, + "bank_acc_number" => Banks::DFT_BANK_ACC_NUMBER, + "bank_acc_name" => Banks::DFT_BANK_ACC_NAME, + "invc_to_client" => OrdersAItems::INVC_TO_CLIENT_YES, + "calc_to_vdr" => OrdersAItems::CALC_TO_VDR_NO, + "only_client" => OrdersAItems::ONLY_CLIENT_YES, + "ref_ord_id" => $ord_id, + "ref_ord_code" => $ord_code, + "ref_c_termin_id" => $c_termin2_id, + "crt" => $now, + "crt_by" => $req->auth->uid, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]); + } + if ($c_termin_sequence === 0) { + $req->sell_termin1_amt_type = OrdersTermins::AMT_TYPE_FLAT; + $req->sell_termin1_amt = $req->sell_price; + $req->sell_termin1_amt_at = strtotime("+2 days", $now); + $req->sell_termin1_calc_percent = 0; + ++$c_termin_sequence; + $insTerminsC1 = [ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "flow_type" => OrdersTermins::FLOW_TYPE_BILLING, + "cash_type" => OrdersTermins::TYPE_CASH_IN, + "sequence" => $c_termin_sequence, + "termin_base_flat" => $req->sell_price, + "termin_tax_type" => OrdersAItems::AMT_TAX_TYPE_EXCLUDE, + "termin_tax_ppn_percent" => OrdersAItems::PPN_PERCENT, + "termin_tax_pph_percent" => OrdersAItems::PPH_PERCENT, + "termin_amt_type" => $req->sell_termin1_amt_type ?? 0, + "termin_amt" => $req->sell_termin1_amt ?? 0, + "termin_calc_percent" => $req->sell_termin1_calc_percent ?? 0, + "termin_result_flat" => + $req->sell_termin1_amt_type == OrdersTermins::AMT_TYPE_FLAT + ? $req->sell_termin1_amt + : $req->sell_termin1_calc_percent, + "termin_ddln_at" => $req->sell_termin1_at ?? 0, + "termin_ddln_type" => OrdersTermins::DDLN_TERMIN_TYPE_ORD_FINISH, + "termin_for" => OrdersTermins::TERMIN_FOR_CLIENT, + "crt" => $now, + "crt_by" => $req->auth->uid, + "crt_type" => OrdersTermins::CRT_TYPE_ADMIN, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]; + $c_termin1_id = OrdersTermins::add($insTerminsC1); + $qty = 1; + OrdersAItems::add([ + "ord_id" => $ord_id, + "ord_code" => $ord_code, + "flow_type" => OrdersAItems::FLOW_TYPE_BILLING, + "cash_type" => OrdersAItems::TYPE_CASH_IN, + "c_termin_id" => $c_termin1_id, + "a_item_type" => OrdersAItems::A_TYPE_PRIMARY, + // 'desc' => $main_item_dec . "
Pembayaran termin 1", + "desc" => $main_item_dec, + "unit_id" => 0, + "unit_type" => UnitTypes::UNIT_TYPE_PAKET, + "unit_qty" => $qty, + "amt_bill_base_flat" => $insTerminsC1["termin_result_flat"], + "amt_bill_result_flat" => $insTerminsC1["termin_result_flat"], + "amt_bill_total_flat" => $insTerminsC1["termin_result_flat"] * $qty, + "ddln_pay_at" => $insTerminsC1["termin_ddln_at"], + "ddln_pay_type" => OrdersAItems::DDLN_PAY_TYPE_ORD_FINISH, + "img_proof_submission" => null, + "img_proof_payment" => null, + "bank_id" => Banks::DFT_BANK_ID, + "bank_code" => Banks::DFT_BANK_CODE, + "bank_name" => Banks::DFT_BANK_NAME, + "bank_short_name" => Banks::DFT_BANK_SHORT_NAME, + "bank_acc_number" => Banks::DFT_BANK_ACC_NUMBER, + "bank_acc_name" => Banks::DFT_BANK_ACC_NAME, + "invc_to_client" => OrdersAItems::INVC_TO_CLIENT_YES, + "calc_to_vdr" => OrdersAItems::CALC_TO_VDR_NO, + "only_client" => OrdersAItems::ONLY_CLIENT_YES, + "ref_ord_id" => $ord_id, + "ref_ord_code" => $ord_code, + "ref_c_termin_id" => $c_termin1_id, + "crt" => $now, + "crt_by" => $req->auth->uid, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]); + } + + // $url = env("API_URL_NODE") . "/order/create"; + // $guzReq = new GuzzleClient(); + // $respNode = $guzReq->request("POST", $url, [ + // "headers" => [ + // "Host" => $_SERVER["SERVER_ADDR"] ?? "127.0.0.1", + // "User-Agent" => "curl/7.65.3", + // "Accept" => "*/*", + // "Accept-Encoding" => "gzip, deflate, br", + // // 'Content-Type' => 'application/x-www-form-urlencoded; charset=UTF-8', + // // 'Connection' => 'keep-alive', + // ], + // "json" => [ + // "trx_code" => $ord_code, + // "trx_at" => $now, + // "client_id" => $clientAuth->uid, + // "client_name" => $clientAuth->first_name, + // "client_phone" => + // $clientAuth->phone_code . " " . implode(" ", str_split($clientAuth->phone, 4)), + // "client_mail" => $clientAuth->email, + // "client_addr" => "", + // "client_prefer_type_truck" => $type_truck_name, + // "pickup_zone_title" => $pckPoints[0]->name, + // "pickup_zone_addr" => $pckPoints[0]->fulladdress, + // "pickup_at" => $req->points[0]["pickup_at"], + // "drop_zone_title" => $dropPoints[0]->name, + // "drop_zone_addr" => $dropPoints[0]->fulladdress, + // "admins" => $admins_data, + // ], + // ]); + // if ($respNode->getStatusCode() != 200) { + // DB::rollBack(); + // $apiResp = Responses::bad_request("fail create order 0"); + // return new Response($apiResp, $apiResp["meta"]["code"]); + // } + // $body = json_decode($respNode->getBody()->getContents()); + + $apiResp = Responses::created("success create order"); + + DB::commit(); + // return new Response($apiResp, $apiResp["meta"]["code"]); + return redirect("user/vendor/transactions"); + } catch (\Exception $e) { + DB::rollBack(); + // dd($e); + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } +} diff --git a/app/Http/Controllers/UsersController.php b/app/Http/Controllers/UsersController.php new file mode 100755 index 0000000..560f8b8 --- /dev/null +++ b/app/Http/Controllers/UsersController.php @@ -0,0 +1,651 @@ + Users::listRoles($req->auth->role), + "pernus" => UsersMenuPermissions::listPermissionsMenus([ + "is_active" => UsersMenuPermissions::IS_ACTIVE, + ]), + "vehicles" => Vehicles::getVehicles(), + "banks" => Banks::listBanks(["is_active" => Banks::IS_ACTIVE]), + ]; + + if ($req->auth->role == Users::ROLE_SUPERADMIN) { + $data["clients"] = Clients::select2Client(); + } elseif ($req->auth->role == Users::ROLE_ADMIN) { + $data["clients"] = Clients::select2Client(); + } else { + $data["clients"] = Clients::select2Client($req->auth->client_group_id); + } + + return view("menu_v1.users", $data); + } + + public function view_profile(Request $req) + { + $data = [ + "roles" => Users::listRoles($req->auth->role), + "pernus" => UsersMenuPermissions::listPermissionsMenus([ + "is_active" => UsersMenuPermissions::IS_ACTIVE, + ]), + "vehicles" => Vehicles::getVehicles(), + "banks" => Banks::listBanks(["is_active" => Banks::IS_ACTIVE]), + ]; + + if ($req->auth->role == Users::ROLE_SUPERADMIN) { + $data["clients"] = Clients::select2Client(); + } elseif ($req->auth->role == Users::ROLE_ADMIN) { + $data["clients"] = Clients::select2Client(); + } else { + $data["clients"] = Clients::select2Client($req->auth->client_group_id); + } + + return view("menu_v1._profile", $data); + } + + /** + * API + */ + + public function api_list_users(Request $req) + { + try { + $now = time(); + $input = []; + $rulesInput = []; + + // validasi input + // $isValidInput = Validator::make($input, $rulesInput); + // if (!$isValidInput->passes()) { + // $apiResp = Responses::bad_input($isValidInput->messages()->first()); + // return new Response($apiResp, $apiResp['meta']['code']); + // } + + $filter = []; + if ($req->cptid) { + $filter["company"] = $req->cptid; + } + $list = Users::listUsers($filter); + foreach ($list as $key => $row) { + $list[$key]->DT_RowIndex = $key + 1; + $list[$key]->count_trx = 0; + $list[$key]->action = "-"; + } + + $apiResp = Responses::success("success list users"); + $apiResp["data"] = $list; + $apiResp["count"] = count($list); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_show_user(Request $req, $uid) + { + try { + $now = time(); + + $input = [ + "uid" => $uid, + ]; + $rulesInput = [ + "uid" => "required|integer|not_in:0", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $user = Users::showUserById($uid); + if (count($user) < 1) { + $apiResp = Responses::not_found("user not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $apiResp = Responses::success("success get detail user"); + $apiResp["data"] = $user[0]; + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_add_user(Request $req) + { + try { + $now = time(); + $roles = Users::arrRoles(); + $statuses = Users::arrStatus(); + + $input = [ + "first_name" => $req->first_name, + "last_name" => $req->last_name, + "phone" => $req->phone, + "email" => $req->email, + "fulladdress" => $req->fulladdress, + "password" => $req->password, + "clients_id" => $req->clients, + "roles" => $req->roles, + "chk_type" => $req->chk_type, + "bank_id" => $req->bank_id, + "bank_code" => $req->bank_code, + "bank_short" => $req->bank_short, + "bank_name" => $req->bank_name, + "bank_kcp" => $req->bank_branch_name, + "bank_acc_number" => $req->bank_acc_number, + "bank_acc_name" => $req->bank_acc_name, + "status" => $req->status, + "is_tracking" => $req->is_tracking, + "vehicles" => $req->vehicles, + "is_vdr_bcng" => $req->is_vdr_bcng, + ]; + $rulesInput = [ + "first_name" => "required|string|max:125", + "last_name" => "nullable|max:125", + "phone" => "required|numeric", + "email" => "required|email", + "fulladdress" => "required|string|min:45", + "password" => "required|string|max:25", + "clients_id" => "required|integer|not_in:0", + "roles" => "required|integer|not_in:0", + "chk_type" => "nullable|integer|not_in:0", + "bank_id" => "nullable|integer|not_in:0", + "bank_code" => "nullable|numeric", + "bank_short" => "nullable|string", + "bank_name" => "nullable|string", + "bank_kcp" => "nullable|string", + "bank_acc_number" => "nullable|numeric", + "bank_acc_name" => "nullable|string|max:255", + "status" => "required|integer|not_in:0", + "is_tracking" => "nullable|numeric", + "vehicles" => "nullable|array", + "is_vdr_bcng" => "nullable|numeric", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + if (in_array($req->roles, $roles)) { + } else { + $apiResp = Responses::bad_request("role not valid"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + if (in_array($req->status, $statuses)) { + } else { + $apiResp = Responses::bad_request("status not valid"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + if ($req->roles == Users::ROLE_VENDOR) { + if (!$req->bank_id) { + $apiResp = Responses::bad_request("bank wajib diisi"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + if (!$req->bank_acc_number) { + $apiResp = Responses::bad_request("nomor rekening wajib diisi"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + if (!$req->bank_acc_name) { + $apiResp = Responses::bad_request("nama pemilik rekening wajib diisi"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + if ($req->clients) { + $clients = Clients::getClientById($req->clients); + if (count($clients) < 1) { + $apiResp = Responses::not_found("clients not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + $uniqEmail = Users::getUserByEmail($req->email); + if (count($uniqEmail) > 0) { + $apiResp = Responses::bad_request("email has been used"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $uniqPhone = Users::getUserByPhone((int) $req->phone); + if (count($uniqPhone) > 0) { + $apiResp = Responses::bad_request("phone has been used"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $uniqCPhone = Clients::getClientByPhone((int) $req->phone); + if (count($uniqCPhone) > 0) { + $apiResp = Responses::bad_request("phone has been used"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $vhcs = null; + if ($req->is_tracking == Users::IS_TRACK_VHC_YES) { + if (!$req->vehicles) { + $apiResp = Responses::bad_request("vehicles must be filled"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + foreach ($req->vehicles as $k => $v) { + $vhcs .= $v . ","; + } + if ($vhcs) { + if (substr($vhcs, -1) === ",") { + $vhcs = substr($vhcs, 0, -1); + } + } + } + + $data = [ + "first_name" => $req->first_name, + "last_name" => $req->last_name ?? null, + "email" => $req->email, + "phone" => (int) $req->phone, + "phone_code" => Users::DEFAULT_PHONE_CODE, + "fulladdress" => $req->fulladdress, + "password" => Hash::make($req->password), + "role" => $req->roles, + "client_id" => $req->clients, + "client_group_id" => $req->clients, + "status" => $req->status, + "is_tracking" => $req->is_tracking, + "vhcs" => $vhcs, + "crt" => $now, + "crt_by" => $req->auth->uid, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]; + if ($req->roles == Users::ROLE_CHECKER) { + // $data['chk_type'] = $req->chk_type; + $data["chk_type"] = Users::CHK_TYPE_ALL; + } + if ($req->roles == Users::ROLE_VENDOR) { + $data["bank_id"] = $req->bank_id; + $data["bank_code"] = $req->bank_code; + $data["bank_name"] = $req->bank_name; + $data["bank_short_name"] = $req->bank_short; + $data["bank_branch_name"] = $req->bank_branch_name; + $data["bank_acc_number"] = $req->bank_acc_number; + $data["bank_acc_name"] = $req->bank_acc_name; + $data["is_vdr_bcng"] = $req->is_vdr_bcng; + } + + DB::beginTransaction(); + + Users::addUser($data); + + $apiResp = Responses::created("success add new user"); + + DB::commit(); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_edit_user(Request $req) + { + try { + $now = time(); + $roles = Users::arrRoles(); + $statuses = Users::arrStatus(); + + $input = [ + "uid" => $req->uid, + "is_tracking" => $req->is_tracking, + "vehicles" => $req->vehicles, + "bank_id" => $req->bank_id, + "bank_code" => $req->bank_code, + "bank_short" => $req->bank_short, + "bank_name" => $req->bank_name, + "bank_kcp" => $req->bank_branch_name, + "bank_acc_number" => $req->bank_acc_number, + "bank_acc_name" => $req->bank_acc_name, + "is_vdr_bcng" => $req->is_vdr_bcng, + ]; + $rulesInput = [ + "uid" => "required|integer|not_in:0", + "is_tracking" => "nullable|numeric", + "vehicles" => "nullable|array", + "bank_id" => "nullable|integer|not_in:0", + "bank_code" => "nullable|numeric", + "bank_short" => "nullable|string", + "bank_name" => "nullable|string", + "bank_kcp" => "nullable|string", + "bank_acc_number" => "nullable|numeric", + "bank_acc_name" => "nullable|string|max:255", + "is_vdr_bcng" => "nullable|numeric", + ]; + $data = [ + "id" => $req->uid, + ]; + + if ($req->first_name) { + $input["first_name"] = $req->first_name; + $rulesInput["first_name"] = "required|string|max:125"; + $data["first_name"] = $req->first_name; + } + if ($req->last_name) { + $input["last_name"] = $req->last_name; + $rulesInput["last_name"] = "required|string|max:125"; + $data["last_name"] = $req->last_name ?? null; + } + if ($req->email) { + $input["email"] = $req->email; + $rulesInput["email"] = "required|email"; + $data["email"] = $req->email; + } + if ($req->phone) { + $input["phone"] = $req->phone; + $rulesInput["phone"] = "required|integer|not_in:0"; + $data["phone"] = $req->phone; + $data["phone_code"] = Users::DEFAULT_PHONE_CODE; + } + if ($req->fulladdress) { + $input["fulladdress"] = $req->fulladdress; + $rulesInput["fulladdress"] = "required|string|min:45"; + $data["fulladdress"] = $req->fulladdress; + } + if ($req->password) { + $input["password"] = $req->password; + $rulesInput["password"] = "required|string"; + $data["password"] = Hash::make($req->password); + } + if ($req->clients) { + $input["clients"] = $req->clients; + $rulesInput["clients"] = "required|integer|not_in:0"; + $data["client_group_id"] = $req->clients; + + $clients = Clients::getClientById($req->clients); + if (count($clients) < 1) { + $apiResp = Responses::not_found("clients not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + if ($req->roles) { + $input["roles"] = $req->roles; + $rulesInput["roles"] = "required|integer|not_in:0"; + $data["role"] = $req->roles; + + if (in_array($req->roles, $roles)) { + } else { + $apiResp = Responses::bad_request("role not valid"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + if ($req->roles) { + if ($req->roles == Users::ROLE_CHECKER) { + // $data['chk_type'] = $req->chk_type; + $data["chk_type"] = Users::CHK_TYPE_ALL; + } + } + if ($req->status) { + $input["status"] = $req->status; + $rulesInput["status"] = "required|integer|not_in:0"; + $data["status"] = $req->status; + + if (in_array($req->status, $statuses)) { + } else { + $apiResp = Responses::bad_request("status not valid"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $getUser = Users::getUserById($req->uid); + if (count($getUser) < 1) { + $apiResp = Responses::not_found("user not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + if ($req->roles == Users::ROLE_VENDOR) { + if (!$req->bank_id) { + $apiResp = Responses::bad_request("bank wajib diisi"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + if (!$req->bank_branch_name) { + $apiResp = Responses::bad_request("bank kcp wajib diisi"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + if (!$req->bank_acc_number) { + $apiResp = Responses::bad_request("nomor rekening wajib diisi"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + if (!$req->bank_acc_name) { + $apiResp = Responses::bad_request("nama pemilik rekening wajib diisi"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + $uniqEmail = Users::getUserByEmail($req->email); + if (count($uniqEmail) > 0) { + $notSameUser = 1; + foreach ($uniqEmail as $key => $row) { + if ($row->id == $req->uid) { + $notSameUser = 0; + } + } + if ($notSameUser) { + $apiResp = Responses::bad_request("email has been used"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + $uniqPhone = Users::getUserByPhone($req->phone); + if (count($uniqPhone) > 0) { + $notSameUser = 1; + foreach ($uniqPhone as $key => $row) { + if ($row->id == $req->uid) { + $notSameUser = 0; + } + } + if ($notSameUser) { + $apiResp = Responses::bad_request("phone has been used"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + // $uniqCPhone = Clients::getClientByPhone($req->phone); + // if (count($uniqCPhone) > 0) { + // $notSameUser = 1; + // foreach ($uniqCPhone as $key => $row) { + // if ($row->id == $getUser[0]->client_id) { + // $notSameUser = 0; + // } + // } + // if ($notSameUser) { + // $apiResp = Responses::bad_request('phone has been used'); + // return (new Response($apiResp, $apiResp['meta']['code'])); + // } + // } + + $vhcs = null; + if ($req->is_tracking == Users::IS_TRACK_VHC_YES) { + if (!$req->vehicles) { + $apiResp = Responses::bad_request("vehicles must be filled"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + foreach ($req->vehicles as $k => $v) { + $vhcs .= $v . ","; + } + if ($vhcs) { + if (substr($vhcs, -1) === ",") { + $vhcs = substr($vhcs, 0, -1); + } + } + } + $data["is_tracking"] = $req->is_tracking; + $data["vhcs"] = $vhcs; + + if ($req->roles == Users::ROLE_VENDOR) { + $data["bank_id"] = $req->bank_id; + $data["bank_code"] = $req->bank_code; + $data["bank_name"] = $req->bank_name; + $data["bank_short_name"] = $req->bank_short; + $data["bank_branch_name"] = $req->bank_branch_name; + $data["bank_acc_number"] = $req->bank_acc_number; + $data["bank_acc_name"] = $req->bank_acc_name; + $data["is_vdr_bcng"] = $req->is_vdr_bcng; + } + + $data["updt"] = $now; + $data["updt_by"] = $req->auth->uid; + + DB::beginTransaction(); + + Users::updateUser($req->uid, $data); + + $apiResp = Responses::created("success update user"); + + DB::commit(); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_del_user(Request $req) + { + try { + $now = time(); + + $input = [ + "uid" => $req->uid, + ]; + $rulesInput = [ + "uid" => "required|integer|not_in:0", + ]; + $data = [ + "id" => $req->uid, + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $getUser = Users::getUserById($req->uid); + if (count($getUser) < 1) { + $apiResp = Responses::not_found("user not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $data["dlt"] = $now; + $data["dlt_by"] = $req->auth->uid; + + DB::beginTransaction(); + + Users::updateUser($req->uid, $data); + + $apiResp = Responses::created("success delete user"); + + DB::commit(); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_search_user_name(Request $req) + { + try { + $now = time(); + $roles = Users::arrRoles(); + $statuses = Users::arrStatus(); + + $input = [ + "name" => $req->name, + "roles" => $req->roles, + ]; + $rulesInput = [ + "name" => "required|string|max:125", + "roles" => "nullable|integer|not_in:0", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + if ($req->roles) { + if (in_array($req->roles, $roles)) { + } else { + $apiResp = Responses::bad_request("role not valid"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + $users = Users::likeName($req->name, $req->roles); + } else { + $users = Users::likeName($req->name); + } + + if (count($users) < 1) { + $apiResp = Responses::not_found("user not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + foreach ($users as $k => $v) { + // remove from array but no reindex array + // unset($users[$k]); + // remove from array and reindex array + // array_splice($users, $k, 1); + unset($users[$k]->password); + } + + $apiResp = Responses::success("success search user by name"); + $apiResp["data"] = $users; + + DB::commit(); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } +} diff --git a/app/Http/Controllers/UsersMenuPermissionsController.php b/app/Http/Controllers/UsersMenuPermissionsController.php new file mode 100755 index 0000000..e153ff5 --- /dev/null +++ b/app/Http/Controllers/UsersMenuPermissionsController.php @@ -0,0 +1,358 @@ + $req->auth, + ]; + return view('menu_v1.configs.usersMenuPermissions', $data); + } + + /** + * API + */ + + public function api_list_menu_permissions(Request $req) + { + try { + $now = time(); + $input = []; + $rulesInput = []; + + // validasi input + // $isValidInput = Validator::make($input, $rulesInput); + // if (!$isValidInput->passes()) { + // $apiResp = Responses::bad_input($isValidInput->messages()->first()); + // return new Response($apiResp, $apiResp['meta']['code']); + // } + $filter = []; + + $list = UsersMenuPermissions::listPermissionsMenus($filter); + foreach ($list as $key => $row) { + $list[$key]->DT_RowIndex = $key + 1; + $list[$key]->action = '-'; + } + + $apiResp = Responses::success('success list menu permissions'); + $apiResp['count'] = count($list); + $apiResp['data'] = $list; + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_show_menu_permissions(Request $req, $id) + { + try { + $now = time(); + + $input = [ + 'id' => $id, + ]; + $rulesInput = [ + 'id' => 'required|integer|not_in:0', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $permis = UsersMenuPermissions::showPermissionsMenusById($id); + if (count($permis) < 1) { + $apiResp = Responses::not_found('permissions not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + $apiResp = Responses::success('success get detail permissions'); + $apiResp['data'] = $permis[0]; + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_add_menu_permissions(Request $req) + { + try { + $now = time(); + + $input = [ + 'name' => $req->name, + // menu admin + 'menu_trx' => $req->menu_trx, + 'menu_company' => $req->menu_company, + 'menu_zone' => $req->menu_zone, + 'menu_users' => $req->menu_users, + 'menu_conf_rates' => $req->menu_conf_rates, + 'menu_conf_insurance' => $req->menu_conf_insurance, + 'menu_conf_truck_type' => $req->menu_conf_truck_type, + 'menu_devices' => $req->menu_devices, + 'menu_logs_devices' => $req->menu_logs_devices, + 'menu_conf_adt_items' => $req->menu_conf_adt_items, + 'menu_drivers' => $req->menu_drivers, + 'menu_vehicles' => $req->menu_vehicles, + 'menu_menu_permission' => $req->menu_menu_permission, + // menu finance + 'menu_fnc_ledger_balance' => $req->menu_fnc_ledger_balance, + 'menu_fnc_payment' => $req->menu_fnc_payment, + 'menu_fnc_billing' => $req->menu_fnc_billing, + 'menu_fnc_conf_adt_items' => $req->menu_fnc_conf_adt_items, + 'status' => $req->status, + ]; + $rulesInput = [ + 'name' => 'required|string', + // menu admin + 'menu_trx' => 'required|numeric|max:2', + 'menu_company' => 'required|numeric|max:2', + 'menu_zone' => 'required|numeric|max:2', + 'menu_users' => 'required|numeric|max:2', + 'menu_conf_rates' => 'required|numeric|max:2', + 'menu_conf_insurance' => 'required|numeric|max:2', + 'menu_conf_truck_type' => 'required|numeric|max:2', + 'menu_devices' => 'required|numeric|max:2', + 'menu_logs_devices' => 'required|numeric|max:2', + 'menu_conf_adt_items' => 'required|numeric|max:2', + 'menu_drivers' => 'required|numeric|max:2', + 'menu_vehicles' => 'required|numeric|max:2', + 'menu_menu_permission' => 'required|numeric|max:2', + // menu finance + 'menu_fnc_ledger_balance' => 'required|numeric|max:2', + 'menu_fnc_payment' => 'required|numeric|max:2', + 'menu_fnc_billing' => 'required|numeric|max:2', + 'menu_fnc_conf_adt_items' => 'required|numeric|max:2', + 'status' => 'required|integer|min:0|max:2', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $isAdmin = 0; + $isFinance = 0; + if ($req->menu_trx || $req->menu_company || $req->menu_zone || $req->menu_users || $req->menu_conf_rates || $req->menu_conf_insurance || $req->menu_conf_truck_type || $req->menu_devices || $req->menu_logs_devices || $req->menu_conf_adt_items || $req->menu_drivers || $req->menu_vehicles) { + $isAdmin = 1; + } + if ($req->menu_fnc_ledger_balance || $req->menu_fnc_payment || $req->menu_fnc_billing || $req->menu_fnc_conf_adt_items) { + $isFinance = 1; + } + + if ($isAdmin && $isFinance) { + $apiResp = Responses::bad_request('Jika salah satu menu admin diizinkan, maka tidak bisa mengizinkan menu finance'); + return new Response($apiResp, $apiResp['meta']['code']); + } + + DB::beginTransaction(); + + $insPer = [ + 'name' => $req->name, + // menu admin + 'is_trx' => $req->menu_trx, + 'is_company' => $req->menu_company, + 'is_zone' => $req->menu_zone, + 'is_users' => $req->menu_users, + 'is_conf_rates' => $req->menu_conf_rates, + 'is_conf_insurance' => $req->menu_conf_insurance, + 'is_conf_truck_type' => $req->menu_conf_truck_type, + 'is_devices' => $req->menu_devices, + 'is_logs_devices' => $req->menu_logs_devices, + 'is_conf_adt_items' => $req->menu_conf_adt_items, + 'is_drivers' => $req->menu_drivers, + 'is_vehicles' => $req->menu_vehicles, + 'is_menu_permission' => $req->menu_menu_permission, + // menu finance + 'is_fnc_ledger_balance' => $req->menu_fnc_ledger_balance, + 'is_fnc_payment' => $req->menu_fnc_payment, + 'is_fnc_billing' => $req->menu_fnc_billing, + 'is_fnc_conf_adt_items' => $req->menu_fnc_conf_adt_items, + 'is_active' => $req->status, + ]; + $id = UsersMenuPermissions::add($insPer); + + $apiResp = Responses::created('success add new permission'); + + DB::commit(); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_updt_menu_permissions(Request $req, $id) + { + try { + $now = time(); + + $input = [ + 'name' => $req->name, + // menu admin + 'menu_trx' => $req->menu_trx, + 'menu_company' => $req->menu_company, + 'menu_zone' => $req->menu_zone, + 'menu_users' => $req->menu_users, + 'menu_conf_rates' => $req->menu_conf_rates, + 'menu_conf_insurance' => $req->menu_conf_insurance, + 'menu_conf_truck_type' => $req->menu_conf_truck_type, + 'menu_devices' => $req->menu_devices, + 'menu_logs_devices' => $req->menu_logs_devices, + 'menu_conf_adt_items' => $req->menu_conf_adt_items, + 'menu_drivers' => $req->menu_drivers, + 'menu_vehicles' => $req->menu_vehicles, + 'menu_menu_permission' => $req->menu_menu_permission, + // menu finance + 'menu_fnc_ledger_balance' => $req->menu_fnc_ledger_balance, + 'menu_fnc_payment' => $req->menu_fnc_payment, + 'menu_fnc_billing' => $req->menu_fnc_billing, + 'menu_fnc_conf_adt_items' => $req->menu_fnc_conf_adt_items, + 'status' => $req->status, + ]; + $rulesInput = [ + 'name' => 'required|string', + // menu admin + 'menu_trx' => 'required|numeric|max:2', + 'menu_company' => 'required|numeric|max:2', + 'menu_zone' => 'required|numeric|max:2', + 'menu_users' => 'required|numeric|max:2', + 'menu_conf_rates' => 'required|numeric|max:2', + 'menu_conf_insurance' => 'required|numeric|max:2', + 'menu_conf_truck_type' => 'required|numeric|max:2', + 'menu_devices' => 'required|numeric|max:2', + 'menu_logs_devices' => 'required|numeric|max:2', + 'menu_conf_adt_items' => 'required|numeric|max:2', + 'menu_drivers' => 'required|numeric|max:2', + 'menu_vehicles' => 'required|numeric|max:2', + 'menu_menu_permission' => 'required|numeric|max:2', + // menu finance + 'menu_fnc_ledger_balance' => 'required|numeric|max:2', + 'menu_fnc_payment' => 'required|numeric|max:2', + 'menu_fnc_billing' => 'required|numeric|max:2', + 'menu_fnc_conf_adt_items' => 'required|numeric|max:2', + 'status' => 'required|integer|min:0|max:2', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $isAdmin = 0; + $isFinance = 0; + if ($req->menu_trx || $req->menu_company || $req->menu_zone || $req->menu_users || $req->menu_conf_rates || $req->menu_conf_insurance || $req->menu_conf_truck_type || $req->menu_devices || $req->menu_logs_devices || $req->menu_conf_adt_items || $req->menu_drivers || $req->menu_vehicles) { + $isAdmin = 1; + } + if ($req->menu_fnc_ledger_balance || $req->menu_fnc_payment || $req->menu_fnc_billing || $req->menu_fnc_conf_adt_items) { + $isFinance = 1; + } + + if ($isAdmin && $isFinance) { + $apiResp = Responses::bad_request('Jika salah satu menu admin diizinkan, maka tidak bisa mengizinkan menu finance'); + return new Response($apiResp, $apiResp['meta']['code']); + } + + DB::beginTransaction(); + + $updtPer = [ + 'name' => $req->name, + // menu admin + 'is_trx' => $req->menu_trx, + 'is_company' => $req->menu_company, + 'is_zone' => $req->menu_zone, + 'is_users' => $req->menu_users, + 'is_conf_rates' => $req->menu_conf_rates, + 'is_conf_insurance' => $req->menu_conf_insurance, + 'is_conf_truck_type' => $req->menu_conf_truck_type, + 'is_devices' => $req->menu_devices, + 'is_logs_devices' => $req->menu_logs_devices, + 'is_conf_adt_items' => $req->menu_conf_adt_items, + 'is_drivers' => $req->menu_drivers, + 'is_vehicles' => $req->menu_vehicles, + 'is_menu_permission' => $req->menu_menu_permission, + // menu finance + 'is_fnc_ledger_balance' => $req->menu_fnc_ledger_balance, + 'is_fnc_payment' => $req->menu_fnc_payment, + 'is_fnc_billing' => $req->menu_fnc_billing, + 'is_fnc_conf_adt_items' => $req->menu_fnc_conf_adt_items, + 'is_active' => $req->status, + ]; + UsersMenuPermissions::updt($id, $updtPer); + + $apiResp = Responses::created('success update permissions'); + + DB::commit(); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } + + public function api_del_menu_permissions(Request $req, $id) + { + try { + $now = time(); + + $input = [ + 'id' => $id, + ]; + $rulesInput = [ + 'id' => 'required|integer|not_in:0', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp['meta']['code']); + } + + $a_item = UsersMenuPermissions::showPermissionsMenusById($id); + if (count($a_item) < 1) { + $apiResp = Responses::not_found('permissions not found'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + + DB::beginTransaction(); + + UsersMenuPermissions::updt($id, [ + 'dlt' => $now, + 'dlt_by' => $req->auth->uid, + ]); + + DB::commit(); + + $apiResp = Responses::success('success delete permissions'); + return (new Response($apiResp, $apiResp['meta']['code'])); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return (new Response($apiResp, $apiResp['meta']['code'])); + } + } +} diff --git a/app/Http/Controllers/VehiclesController.php b/app/Http/Controllers/VehiclesController.php new file mode 100755 index 0000000..d4090ee --- /dev/null +++ b/app/Http/Controllers/VehiclesController.php @@ -0,0 +1,706 @@ +passes()) { + // $apiResp = Responses::bad_input($isValidInput->messages()->first()); + // return new Response($apiResp, $apiResp['meta']['code']); + // } + + $filter = []; + if ($req->cptid) { + $filter["company"] = $req->cptid; + } + $list = Vehicles::listVehicles($req->auth, $filter); + foreach ($list as $key => $row) { + $list[$key]->DT_RowIndex = $key + 1; + // $list[$key]->mileage_km = '-'; + // $list[$key]->div_name = 'All Division'; + // $list[$key]->group_name = 'All Group'; + // $list[$key]->track_schedule = $row->track_sch_h.'/'.$row->track_sch_d; // combine track_sch_h + track_sch_d + // $list[$key]->is_track_holiday_text = ($list[$key]->is_track_holiday == Vehicles::ENABLED_TRACK_HOLIDAY) ? 'Enabled' : 'Disabled'; + // $list[$key]->alert_zones = '-'; + // $list[$key]->cameras = '-'; + $list[$key]->action = "-"; + } + + $apiResp = Responses::success("success list vehicles"); + $apiResp["data"] = $list; + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_show_vehicle(Request $req, $vid) + { + try { + $now = time(); + + $input = [ + "vid" => $vid, + ]; + $rulesInput = [ + "vid" => "required|integer|not_in:0", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $vehicle = Vehicles::showVehicleById($vid); + if (count($vehicle) < 1) { + $apiResp = Responses::not_found("vehicle not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $apiResp = Responses::success("success get detail vehicle"); + $apiResp["data"] = $vehicle[0]; + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_add_vehicle(Request $req) + { + $url_fvhc = ""; + $url_stnk = ""; + try { + $now = time(); + + $device_id = str_pad($req->device_id, Vehicles::MAX_DEVICE_ID, "0", STR_PAD_LEFT); + + $input = [ + "front_vehicle_photo" => $req->fvhc_base64, + "dvc_id" => $req->dvc_id, + "simcard" => $req->simcard, + "device_id" => $req->device_id, + "vehicle_name" => $req->vhc_name, + "brand_id" => $req->brand_id, + "type_id" => $req->type_id, + "model_id" => $req->model_id, + "speed_limit" => $req->speed_limit, + "fuel_capacity" => $req->fuel_capacity, + "fuel_drop_treshold" => $req->fuel_drop_treshold, + "max_pressure" => $req->max_pressure, + "current_driver" => $req->d_current, + "assign_driver" => $req->d_assign, + "stnk_photo" => $req->stnk_base64, + "stnk_exp" => $req->stnk_exp, + "nopol1" => $req->nopol1, + "nopol2" => $req->nopol2, + "nopol3" => $req->nopol3, + "manufacture_year" => $req->stnk_vyear, + "cylinder_capacity" => $req->cc, + "vehicle_identity_number" => $req->vin, + "engine_number" => $req->en, + "vehicle_color" => $req->color, + "fuel_type" => $req->fuel_type, + "license_plat_color" => $req->tnkb_color, + "regis_year" => $req->regis_year, + "tax_exp" => $req->tax_exp, + "kir_exp" => $req->kir_exp, + "vendor_id" => $req->vendor_id, + ]; + $rulesInput = [ + "front_vehicle_photo" => "required|string", + "dvc_id" => "nullable|integer", + "simcard" => "nullable|numeric", + "device_id" => "nullable|numeric", + "vehicle_name" => "required|string", + "brand_id" => "required|integer", + "type_id" => "required|integer", + "model_id" => "nullable|integer", + "speed_limit" => "required|numeric", + // "fuel_capacity" => "required|numeric", + // "fuel_drop_treshold" => "required|numeric", + // "max_pressure" => "required|numeric", + "current_driver" => "nullable|integer", + "assign_driver" => "nullable|integer", + "stnk_photo" => "required|string", + "stnk_exp" => "required|date_format:Y-m-d", + "nopol1" => "required|string|max:2", + "nopol2" => "required|string|max:4", + "nopol3" => "required|string|max:3", + "manufacture_year" => "required|digits:4", + "cylinder_capacity" => "required|integer", + "vehicle_identity_number" => "required|string|min:17|max:45", + "engine_number" => "required|string|min:9|max:45", + "vehicle_color" => "required|string|min:3|max:25", + "fuel_type" => "required|string|min:3|max:25", + "license_plat_color" => "required|string|min:3|max:25", + "regis_year" => "required|digits:4", + "tax_exp" => "required|date_format:Y-m-d", + "kir_exp" => "required|date_format:Y-m-d", + "vendor_id" => "nullable|integer|not_in:0", + ]; + + if ($req->auth->role == Users::ROLE_VENDOR) { + $rulesInput["simcard"] = "nullable"; + } + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + if (strlen($req->device_id) > Vehicles::MAX_DEVICE_ID) { + $apiResp = Responses::bad_input("device_id max length is " . Vehicles::MAX_DEVICE_ID); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + if ($device_id !== str_pad(0, Vehicles::MAX_DEVICE_ID, "0", STR_PAD_LEFT)) { + $uniqDeviceId = Vehicles::getVehicleByDeviceId($device_id); + if (count($uniqDeviceId) > 0) { + $apiResp = Responses::bad_request("device id has been used"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + $uniqSimcard = Vehicles::getVehicleBySimcard($req->simcard); + if (count($uniqSimcard) > 0) { + $apiResp = Responses::bad_request("simcard has been used"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $uniqPlatNo = Vehicles::getVehicleByPlatNo($req->nopol1, $req->nopol2, $req->nopol3); + if (count($uniqPlatNo) > 0) { + $apiResp = Responses::bad_request("plat number has been used"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + DB::beginTransaction(); + + $insVhc = [ + "name" => $req->vhc_name, + "dvc_id" => $req->dvc_id ?? 0, + "device_id" => $device_id, + "simcard" => $req->simcard ?? 0, + "cat_id" => Vehicles::DEFAULT_CAT_ID, + "brand_id" => $req->brand_id, + "type_id" => $req->type_id, + "nopol1" => strtoupper($req->nopol1), + "nopol2" => strtoupper($req->nopol2), + "nopol3" => strtoupper($req->nopol3), + "c_did" => $req->d_current ?? 0, + "a_did" => $req->d_assign ?? 0, + "is_track_holiday" => Vehicles::DEFAULT_TRACK_HOLIDAY, + "track_sch_d" => Vehicles::DEFAULT_TRACK_SCH_D, + "track_sch_h" => Vehicles::DEFAULT_TRACK_SCH_H, + "client_group_id" => $req->auth->client_group_id ?? null, + "crt" => $now, + "crt_by" => $req->auth->uid, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]; + if ($req->model_id) { + $insVhc["model_id"] = $req->model_id; + } + if ($req->auth->role == Users::ROLE_VENDOR) { + $insVhc["vendor_id"] = $req->auth->uid; + $insVhc["simcard"] = 0; + } else { + $insVhc["vendor_id"] = $req->vendor_id ?? 0; + } + $vid = Vehicles::addVehicle($insVhc); + + if ($req->auth->role == Users::ROLE_VENDOR) { + $getUsrId = DB::table("t_users") + ->where("id", Auth::user()->id) + ->first(); + $vhclid = DB::table("t_vehicles")->insertGetId($insVhc); + $new = $getUsrId->vhcs . "," . $vhclid; + $dtupdate = [ + "vhcs" => $new, + ]; + DB::table("t_users") + ->where("id", Auth::user()->id) + ->update($dtupdate); + $dtUpdataIsTracking = [ + "is_tracking" => 1, + ]; + DB::table("t_users") + ->where("id", Auth::user()->id) + ->update($dtUpdataIsTracking); + } + $url_fvhc = "vehicles/$vid/front_$now.jpeg"; + if (!Storage::disk("public")->put($url_fvhc, base64_decode($req->fvhc_base64))) { + DB::rollBack(); + $apiResp = Responses::bad_request("fail upload front photo"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + $url_stnk = "vehicles/$vid/stnk_$now.jpeg"; + if (!Storage::disk("public")->put($url_stnk, base64_decode($req->stnk_base64))) { + Storage::disk("public")->delete($url_fvhc); + DB::rollBack(); + $apiResp = Responses::bad_request("fail upload front photo"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $insDetail = [ + "vid" => $vid, + "speed_limit" => $req->speed_limit, + "fuel_capacity" => $req->fuel_capacity, + "fuel_drop_treshold" => $req->fuel_drop_treshold, + "max_pressure" => $req->max_pressure, + "fvhc_img" => $url_fvhc, + "stnk_img" => $url_stnk, + "stnk_exp" => $req->stnk_exp, + "vyear" => $req->stnk_vyear, // manufacture_year + "cc" => $req->cc, // cylinder_capacity + "vin" => strtoupper($req->vin), // vehicle_identity_number + "en" => strtoupper($req->en), // engine_number + "vcolor" => strtoupper($req->color), + "fuel_type" => strtoupper($req->fuel_type), + "tnkb_color" => strtoupper($req->tnkb_color), // license_plat_color + "regis_year" => $req->regis_year, + "tax_exp" => $req->tax_exp, + "kir_exp" => $req->kir_exp, + ]; + VehiclesDetail::addDetail($insDetail); + + $apiResp = Responses::created("success add new vehicle"); + + DB::commit(); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + Storage::disk("public")->delete($url_fvhc); + Storage::disk("public")->delete($url_stnk); + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_edit_vehicle(Request $req, $vid) + { + $url_fvhc = ""; + $url_stnk = ""; + + try { + $now = time(); + + $device_id = str_pad($req->device_id, Vehicles::MAX_DEVICE_ID, "0", STR_PAD_LEFT); + + $input = [ + "vid" => $vid, + "front_vehicle_photo" => $req->fvhc_base64, + "dvc_id" => $req->dvc_id ?? 0, + "simcard" => $req->simcard, + "device_id" => $req->device_id, + "vehicle_name" => $req->vhc_name, + "brand_id" => $req->brand_id, + "type_id" => $req->type_id, + "model_id" => $req->model_id, + "speed_limit" => $req->speed_limit, + "fuel_capacity" => $req->fuel_capacity, + "fuel_drop_treshold" => $req->fuel_drop_treshold, + "max_pressure" => $req->max_pressure, + "current_driver" => $req->d_current, + "assign_driver" => $req->d_assign, + "stnk_photo" => $req->stnk_base64, + "stnk_exp" => $req->stnk_exp, + "nopol1" => $req->nopol1, + "nopol2" => $req->nopol2, + "nopol3" => $req->nopol3, + "manufacture_year" => $req->stnk_vyear, + "cylinder_capacity" => $req->cc, + "vehicle_identity_number" => $req->vin, + "engine_number" => $req->en, + "vehicle_color" => $req->color, + "fuel_type" => $req->fuel_type, + "license_plat_color" => $req->tnkb_color, + "regis_year" => $req->regis_year, + "tax_exp" => $req->tax_exp, + "kir_exp" => $req->kir_exp, + "vendor_id" => $req->vendor_id, + ]; + $rulesInput = [ + "vid" => "required|integer|not_in:0", + "front_vehicle_photo" => "nullable|string", + // "dvc_id" => "nullable|integer", + "simcard" => "nullable|numeric", + "device_id" => "nullable|numeric", + "vehicle_name" => "required|string", + "brand_id" => "required|integer", + "type_id" => "required|integer", + "model_id" => "nullable|integer", + "speed_limit" => "required|numeric", + // "fuel_capacity" => "required|numeric", + // "fuel_drop_treshold" => "required|numeric", + // "max_pressure" => "required|numeric", + "current_driver" => "nullable|integer", + "assign_driver" => "nullable|integer", + "stnk_photo" => "nullable|string", + "stnk_exp" => "required|date_format:Y-m-d", + "nopol1" => "required|string|max:2", + "nopol2" => "required|string|max:4", + "nopol3" => "required|string|max:3", + "manufacture_year" => "required|digits:4", + "cylinder_capacity" => "required|integer", + "vehicle_identity_number" => "required|string|min:17|max:45", + "engine_number" => "required|string|min:9|max:45", + "vehicle_color" => "required|string|min:3|max:25", + "fuel_type" => "required|string|min:3|max:25", + "license_plat_color" => "required|string|min:3|max:25", + "regis_year" => "required|digits:4", + "tax_exp" => "required|date_format:Y-m-d", + "kir_exp" => "required|date_format:Y-m-d", + "vendor_id" => "nullable|integer|not_in:0", + ]; + + if ($req->auth->role == Users::ROLE_VENDOR) { + $rulesInput["simcard"] = "nullable"; + } + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + if (strlen($req->device_id) > Vehicles::MAX_DEVICE_ID) { + $apiResp = Responses::bad_input("device id max length is " . Vehicles::MAX_DEVICE_ID); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $vhc = Vehicles::getVehicleById($vid); + if (count($vhc) < 1) { + $apiResp = Responses::bad_request("vehicle not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + $vd = VehiclesDetail::getDetailByVid($vid); + if (count($vd) < 1) { + $apiResp = Responses::bad_request("vehicle not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + // if ($req->dvc_id) { + // $uniqDeviceId = Vehicles::getVehicleByDeviceId($device_id); + // if (count($uniqDeviceId) > 0) { + // $notSameUser = 1; + // foreach ($uniqDeviceId as $key => $row) { + // if ($row->id == $vid) { + // $notSameUser = 0; + // } + // } + // if ($notSameUser) { + // $apiResp = Responses::bad_request("device id has been used"); + // return new Response($apiResp, $apiResp["meta"]["code"]); + // } + // } + // } + + $uniqSimcard = Vehicles::getVehicleBySimcard($req->simcard); + if (count($uniqSimcard) > 0) { + $notSameUser = 1; + foreach ($uniqSimcard as $key => $row) { + if ($row->id == $vid) { + $notSameUser = 0; + } + } + if ($notSameUser) { + $apiResp = Responses::bad_request("simcard has been used"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + $uniqPlatNo = Vehicles::getVehicleByPlatNo($req->nopol1, $req->nopol2, $req->nopol3); + if (count($uniqPlatNo) > 0) { + $notSameUser = 1; + foreach ($uniqPlatNo as $key => $row) { + if ($row->id == $vid) { + $notSameUser = 0; + } + } + if ($notSameUser) { + $apiResp = Responses::bad_request("plat number has been used"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + DB::beginTransaction(); + + $updtVhc = [ + "name" => $req->vhc_name, + "dvc_id" => $req->dvc_id, + "device_id" => $device_id, + "simcard" => (int) $req->simcard, + "cat_id" => Vehicles::DEFAULT_CAT_ID, + "brand_id" => $req->brand_id, + "type_id" => $req->type_id, + "nopol1" => strtoupper($req->nopol1), + "nopol2" => strtoupper($req->nopol2), + "nopol3" => strtoupper($req->nopol3), + "c_did" => $req->d_current ?? 0, + "a_did" => $req->d_assign ?? 0, + "is_track_holiday" => Vehicles::DEFAULT_TRACK_HOLIDAY, + "track_sch_d" => Vehicles::DEFAULT_TRACK_SCH_D, + "track_sch_h" => Vehicles::DEFAULT_TRACK_SCH_H, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]; + if ($req->model_id) { + $updtVhc["model_id"] = $req->model_id; + } + if ($req->auth->role == Users::ROLE_VENDOR) { + $updtVhc["vendor_id"] = $req->auth->uid; + // $updtVhc["simcard"] = (int) $uniqDeviceId[0]->simcard; + } else { + $updtVhc["vendor_id"] = $req->vendor_id ?? 0; + } + Vehicles::updateVehicle($vid, $updtVhc); + + if ($req->dvc_id) { + Devices::updateDevice($req->dvc_id, [ + "is_assigned" => Devices::IS_ASSIGNED, + ]); + } else { + Devices::updateDevice($vhc[0]->dvc_id, [ + "is_assigned" => Devices::IS_UNASSIGNED, + ]); + } + + if ($req->fvhc_base64) { + $url_fvhc = "vehicles/$vid/front_$now.jpeg"; + if (!Storage::disk("public")->put($url_fvhc, base64_decode($req->fvhc_base64))) { + DB::rollBack(); + $apiResp = Responses::bad_request("fail upload front photo"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + Storage::disk("public")->delete($vd[0]->fvhc_img); + } + if ($req->stnk_base64) { + $url_stnk = "vehicles/$vid/stnk_$now.jpeg"; + if (!Storage::disk("public")->put($url_stnk, base64_decode($req->stnk_base64))) { + Storage::disk("public")->delete($url_fvhc); + DB::rollBack(); + $apiResp = Responses::bad_request("fail upload front photo"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + Storage::disk("public")->delete($vd[0]->stnk_img); + } + + $updtDetail = [ + "vid" => $vid, + "speed_limit" => $req->speed_limit, + "fuel_capacity" => $req->fuel_capacity, + "fuel_drop_treshold" => $req->fuel_drop_treshold, + "max_pressure" => $req->max_pressure, + "stnk_exp" => $req->stnk_exp, + "vyear" => $req->stnk_vyear, // manufacture_year + "cc" => $req->cc, // cylinder_capacity + "vin" => strtoupper($req->vin), // vehicle_identity_number + "en" => strtoupper($req->en), // engine_number + "vcolor" => strtoupper($req->color), + "fuel_type" => strtoupper($req->fuel_type), + "tnkb_color" => strtoupper($req->tnkb_color), // license_plat_color + "regis_year" => $req->regis_year, + "tax_exp" => $req->tax_exp, + "kir_exp" => $req->kir_exp, + ]; + if ($req->fvhc_base64) { + $updtDetail["fvhc_img"] = $url_fvhc; + } + if ($req->stnk_base64) { + $updtDetail["stnk_img"] = $url_stnk; + } + VehiclesDetail::updateDetailByVid($vid, $updtDetail); + + DB::commit(); + + $apiResp = Responses::success("success update vehicle"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + Storage::disk("public")->delete($url_fvhc); + Storage::disk("public")->delete($url_stnk); + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_del_vehicle(Request $req, $vid) + { + try { + $now = time(); + + $input = [ + "vid" => $vid, + ]; + $rulesInput = [ + "vid" => "required|integer|not_in:0", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $vehicle = Vehicles::showVehicleById($vid); + if (count($vehicle) < 1) { + $apiResp = Responses::not_found("vehicle not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + DB::beginTransaction(); + + $device_id = str_pad(0, Devices::MAX_DEVICE_ID, "0", STR_PAD_LEFT); + Vehicles::updateVehicle($vid, [ + "dvc_id" => 0, + "device_id" => $device_id, + "simcard" => 0, + "dlt" => $now, + "dlt_by" => $req->auth->uid, + ]); + if ($vehicle[0]->dvc_id != 0) { + Devices::updateDevice($vehicle[0]->dvc_id, [ + "is_assigned" => Devices::IS_UNASSIGNED, + ]); + } + + // Storage::disk('public')->delete($vehicle[0]->fvhc_img); + // Storage::disk('public')->delete($vehicle[0]->stnk_img); + + DB::commit(); + + $apiResp = Responses::success("success delete vehicle"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_search_device_id(Request $req) + { + try { + $now = time(); + + $input = [ + "device_id" => $req->device_id, + ]; + $rulesInput = [ + "device_id" => "required|numeric", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + if (strlen($req->device_id) > Vehicles::MAX_DEVICE_ID) { + $apiResp = Responses::bad_input("device id max length is " . Vehicles::MAX_DEVICE_ID); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $device_id = str_pad($req->device_id, Vehicles::MAX_DEVICE_ID, "0", STR_PAD_LEFT); + $devices = Vehicles::getVehicleByDeviceId($device_id); + + if (count($devices) < 1) { + $apiResp = Responses::not_found("device id not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $apiResp = Responses::success("success search device id"); + $apiResp["data"] = $devices; + + DB::commit(); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_search_nopol(Request $req) + { + try { + $now = time(); + + $input = [ + "nopol" => $req->nopol, + ]; + $rulesInput = [ + "nopol" => "required|string", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $nopol = explode(" ", strtoupper($req->nopol)); + $cNopol = count($nopol); + if ($cNopol === 3) { + } elseif ($cNopol === 2) { + $nopol[2] = ""; + } elseif ($cNopol === 1) { + $nopol[1] = ""; + $nopol[2] = ""; + } else { + $apiResp = Responses::bad_input("Nomor polisi kendaraan tidak valid"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $vehicles = Vehicles::searchVehicleByPlatNo($nopol[0], $nopol[1], $nopol[2]); + + if (count($vehicles) < 1) { + $apiResp = Responses::not_found("vehicles not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $apiResp = Responses::success("success search vehicles"); + $apiResp["data"] = $vehicles; + + DB::commit(); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } +} diff --git a/app/Http/Controllers/ZoneController.php b/app/Http/Controllers/ZoneController.php new file mode 100755 index 0000000..613afd7 --- /dev/null +++ b/app/Http/Controllers/ZoneController.php @@ -0,0 +1,1183 @@ + Zone::listTypes(), + "workflows" => Zone::listWorkflows(), + "boundarys" => Zone::listBoundarys(), + "provs" => Region::listProv(), + ]; + + if ($req->auth->role == Users::ROLE_SUPERADMIN) { + $data["is_su"] = 1; + $data["clients"] = Clients::select2Client(); + } elseif ($req->auth->role == Users::ROLE_ADMIN) { + $data["is_su"] = 1; + $data["clients"] = Clients::select2Client(); + } else { + $data["clients"] = []; + $data["is_su"] = 0; + } + + return view("menu_v1._addZone", $data); + } + + public function view_zone_edit(Request $req, $zid) + { + $input = [ + "zid" => $zid, + ]; + $rulesInput = [ + "zid" => "required|integer|not_in:0", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $zone = Zone::showZoneById($zid); + if (count($zone) < 1) { + $apiResp = Responses::not_found("zone not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + if ($zone[0]->boundary_bounds) { + $zone[0]->boundary_bounds = json_decode($zone[0]->boundary_bounds); + } + if ($zone[0]->boundary_latlngs) { + $zone[0]->boundary_latlngs = json_decode( + $zone[0]->boundary_latlngs + ); + } + unset($zone[0]->boundary_points); + + $data = [ + "zone" => $zone[0], + "types" => Zone::listTypes(), + "workflows" => Zone::listWorkflows(), + "boundarys" => Zone::listBoundarys(), + "provs" => Region::listProv(), + ]; + + if ($req->auth->role == Users::ROLE_SUPERADMIN) { + $data["is_su"] = 1; + $data["clients"] = Clients::select2Client(); + } elseif ($req->auth->role == Users::ROLE_ADMIN) { + $data["is_su"] = 1; + $data["clients"] = Clients::select2Client(); + } else { + $data["clients"] = []; + $data["is_su"] = 0; + } + + $arr_zone = (array) $data["zone"]; + $data["arr_zone"] = json_encode($arr_zone); + + return view("menu_v1._edtZone", $data); + } + + public function view_user_checker_zone_edit(Request $req) + { + $input = [ + "zid" => $req->zid, + "ord_code" => $req->ord_code, + ]; + $rulesInput = [ + "zid" => "required|integer|not_in:0", + "ord_code" => "required|string|max:12", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input($isValidInput->messages()->first()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $zone = Zone::showZoneById($req->zid); + if (count($zone) < 1) { + $apiResp = Responses::not_found("zone not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + if ($zone[0]->boundary_bounds) { + $zone[0]->boundary_bounds = json_decode($zone[0]->boundary_bounds); + } + if ($zone[0]->boundary_latlngs) { + $zone[0]->boundary_latlngs = json_decode( + $zone[0]->boundary_latlngs + ); + } + unset($zone[0]->boundary_points); + + $orders = Orders::showOrder([ + "code" => $req->ord_code, + // 'get_stts_checker' => 1, + // 'get_prefer_type_truck' => 1, + // 'get_checker_data' => 1, + // 'get_client_pt' => 1, + // 'get_accidents' => 1, + "couple_pck_drop" => 1, + // 'get_user_aprv_pck' => 1, + // 'get_user_aprv_pck' => 1, + "group_by" => "ord.id", + ]); + if (count($orders) < 1) { + return redirect(url()->previous()); + } + + $data = [ + "zone" => $zone[0], + "order" => $orders[0], + "types" => Zone::listTypes(), + "workflows" => Zone::listWorkflows(), + "boundarys" => Zone::listBoundarys(), + "provs" => Region::listProv(), + ]; + + $data["clients"] = Clients::select2Client(); + + $arr_zone = (array) $data["zone"]; + $data["arr_zone"] = json_encode($arr_zone); + + return view("menu_v2.Checker._edtZone", $data); + } + + /** + * API + */ + + public function api_list_zones(Request $req) + { + try { + $now = time(); + $input = []; + $rulesInput = []; + + // validasi input + // $isValidInput = Validator::make($input, $rulesInput); + // if (!$isValidInput->passes()) { + // $apiResp = Responses::bad_input($isValidInput->messages()->first()); + // return new Response($apiResp, $apiResp['meta']['code']); + // } + + $filter = []; + if ($req->cptid) { + $filter["company"] = $req->cptid; + } + if ($req->status) { + $filter["is_active"] = $req->status; + } + $list = Zone::listZones($req->auth, $filter); + + foreach ($list as $key => $row) { + $list[$key]->DT_RowIndex = $key + 1; + $list[$key]->action = "-"; + unset($list[$key]->boundary_points); + } + + $apiResp = Responses::success("success list zones"); + $apiResp["data"] = $list; + $apiResp["count"] = count($list); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_show_zone(Request $req, $zid) + { + try { + $now = time(); + + $input = [ + "zid" => $zid, + ]; + $rulesInput = [ + "zid" => "required|integer|not_in:0", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input( + $isValidInput->messages()->first() + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $zone = Zone::showZoneById($zid); + if (count($zone) < 1) { + $apiResp = Responses::not_found("zone not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $apiResp = Responses::success("success get detail zone"); + $apiResp["data"] = $zone[0]; + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_add_zone(Request $req) + { + try { + $now = time(); + + $input = [ + "zone_name" => $req->zone_name, + "zone_client" => $req->zone_client, + "zone_type" => $req->zone_type, + "workflow_zone_type" => $req->workflow_zone_type, + "shiptocode" => $req->shiptocode, + "prid" => $req->prid, + "ktid" => $req->ktid, + "kcid" => $req->kcid, + "klid" => $req->klid, + "fulladdress" => $req->fulladdress, + "status" => $req->status, + "boundary_hex_color" => $req->boundary_hex_color, + "boundary_type" => $req->boundary_type, + "boundary_latlngs" => $req->boundary_latlngs, + "boundary_bounds" => $req->boundary_bounds, + "boundary_radius" => $req->boundary_radius, + "boundary_diameter" => $req->boundary_diameter, + "boundary_area" => $req->boundary_area, // square meter + "boundary_ha" => $req->boundary_ha, // hectare + ]; + $rulesInput = [ + "zone_name" => "required|string|max:255", + "zone_client" => "nullable|integer|not_in:0", + "zone_type" => "required|integer|not_in:0", + "workflow_zone_type" => "required|integer|not_in:0", + "shiptocode" => "required|string|min:5|max:6", + "prid" => "required|numeric", + "ktid" => "required|numeric", + "kcid" => "required|numeric", + "klid" => "required|numeric", + "fulladdress" => "required|string|min:55", + "status" => "required|integer|not_in:0", + "boundary_hex_color" => "required|string|min:7|max:7", + "boundary_type" => "required|string|max:25", + "boundary_latlngs" => "required|array", + "boundary_latlngs.*.lat" => "required", + "boundary_latlngs.*.lng" => "required", + "boundary_bounds" => "nullable|array", + "boundary_radius" => "nullable|numeric", + "boundary_diameter" => "nullable|numeric", + "boundary_area" => "nullable|numeric", + "boundary_ha" => "nullable|numeric", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input( + $isValidInput->messages()->first() + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $uniqName = Zone::getZoneByName($req->zone_name); + if (count($uniqName) > 0) { + $apiResp = Responses::bad_request("zone name has been used"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $user = Users::getUserById($req->auth->uid); + + DB::beginTransaction(); + + $insZone = [ + "name" => $req->zone_name, + "type" => $req->zone_type, + "workflow_type" => $req->workflow_zone_type, + "shiptocode" => $req->shiptocode, + "prid" => $req->prid, + "ktid" => $req->ktid, + "kcid" => $req->kcid, + "klid" => $req->klid, + "fulladdress" => $req->fulladdress, + "boundary_type" => $req->boundary_type, + "boundary_hex_color" => strtoupper($req->boundary_hex_color), + "boundary_latlngs" => json_encode($req->boundary_latlngs), + "boundary_bounds" => $req->boundary_bounds + ? json_encode($req->boundary_bounds) + : null, // $req->boundary_bounds ?? null, + "boundary_radius" => $req->boundary_radius ?? 0, + "boundary_diameter" => $req->boundary_diameter ?? 0, + "boundary_area" => $req->boundary_area ?? 0, + "boundary_ha" => $req->boundary_ha ?? 0, + "status" => $req->status, + "client_group_id" => + $req->zone_client ?? ($user[0]->client_group_id ?? null), + "crt" => $now, + "crt_by" => $req->auth->uid, + "updt" => $now, + "updt_by" => $req->auth->uid, + ]; + + // $insZone['boundary_points'] = DB::raw("ST_GeomFromText('POINT($req->lng $req->lat)')"); + $insZone["boundary_points"] = "ST_GeomFromText('MULTIPOINT("; + + foreach ($req->boundary_latlngs as $key => $val) { + $insZone["boundary_points"] .= + $val["lng"] . " " . $val["lat"] . ", "; + } + $insZone["boundary_points"] = substr( + $insZone["boundary_points"], + 0, + -2 + ); // remove 2 last character + $insZone["boundary_points"] .= ")')"; + $insZone["boundary_points"] = DB::raw($insZone["boundary_points"]); + + $zoneId = Zone::addZone($insZone); + + $apiResp = Responses::created("success add new zone"); + + DB::commit(); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_edit_zone(Request $req, $zid) + { + try { + $now = time(); + + $input = [ + "zone_name" => $req->zone_name, + "zone_client" => $req->zone_client, + "zone_type" => $req->zone_type, + "workflow_zone_type" => $req->workflow_zone_type, + "shiptocode" => $req->shiptocode, + "prid" => $req->prid, + "ktid" => $req->ktid, + "kcid" => $req->kcid, + "klid" => $req->klid, + "fulladdress" => $req->fulladdress, + "status" => $req->status, + "boundary_hex_color" => $req->boundary_hex_color, + "boundary_type" => $req->boundary_type, + "boundary_latlngs" => $req->boundary_latlngs, + "boundary_bounds" => $req->boundary_bounds, + "boundary_radius" => $req->boundary_radius, + "boundary_diameter" => $req->boundary_diameter, + "boundary_area" => $req->boundary_area, // square meter + "boundary_ha" => $req->boundary_ha, // hectare + ]; + $rulesInput = [ + "zone_name" => "required|string|max:255", + "zone_client" => "nullable|integer|not_in:0", + "zone_type" => "required|integer|not_in:0", + "workflow_zone_type" => "required|integer|not_in:0", + "shiptocode" => "required|string|min:5|max:6", + "prid" => "required|numeric", + "ktid" => "required|numeric", + "kcid" => "required|numeric", + "klid" => "required|numeric", + "fulladdress" => "required|string|min:55", + "status" => "required|integer|not_in:0", + "boundary_hex_color" => "required|string|min:7|max:7", + "boundary_type" => "required|string|max:25", + "boundary_latlngs" => "required|array", + "boundary_latlngs.*.lat" => "required", + "boundary_latlngs.*.lng" => "required", + "boundary_bounds" => "nullable|array", + "boundary_radius" => "nullable|numeric", + "boundary_diameter" => "nullable|numeric", + "boundary_area" => "nullable|numeric", + "boundary_ha" => "nullable|numeric", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input( + $isValidInput->messages()->first() + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $zone = Zone::showZoneById($zid); + if (count($zone) < 1) { + $apiResp = Responses::not_found("zone not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $uniqName = Zone::getZoneByName($req->zone_name); + if (count($uniqName) > 0) { + $notSameUser = 1; + foreach ($uniqName as $key => $row) { + if ($row->id == $zid) { + $notSameUser = 0; + } + } + if ($notSameUser) { + $apiResp = Responses::bad_request( + "zone name has been used" + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + $user = Users::getUserById($req->auth->uid); + + DB::beginTransaction(); + + $updtZone = [ + "name" => $req->zone_name, + "type" => $req->zone_type, + "workflow_type" => $req->workflow_zone_type, + "shiptocode" => $req->shiptocode, + "prid" => $req->prid, + "ktid" => $req->ktid, + "kcid" => $req->kcid, + "klid" => $req->klid, + "fulladdress" => $req->fulladdress, + "boundary_type" => $req->boundary_type, + "boundary_hex_color" => strtoupper($req->boundary_hex_color), + "boundary_latlngs" => json_encode($req->boundary_latlngs), + "boundary_bounds" => $req->boundary_bounds + ? json_encode($req->boundary_bounds) + : null, // $req->boundary_bounds ?? null, + "boundary_radius" => $req->boundary_radius ?? 0, + "boundary_diameter" => $req->boundary_diameter ?? 0, + "boundary_area" => $req->boundary_area ?? 0, + "boundary_ha" => $req->boundary_ha ?? 0, + "status" => $req->status, + "client_group_id" => + $req->zone_client ?? ($user[0]->client_group_id ?? null), + "updt" => $now, + "updt_by" => $req->auth->uid, + ]; + + // $updtZone['boundary_points'] = DB::raw("ST_GeomFromText('POINT($req->lng $req->lat)')"); + $updtZone["boundary_points"] = "ST_GeomFromText('MULTIPOINT("; + + foreach ($req->boundary_latlngs as $key => $val) { + $updtZone["boundary_points"] .= + $val["lng"] . " " . $val["lat"] . ", "; + } + $updtZone["boundary_points"] = substr( + $updtZone["boundary_points"], + 0, + -2 + ); // remove 2 last character + $updtZone["boundary_points"] .= ")')"; + $updtZone["boundary_points"] = DB::raw( + $updtZone["boundary_points"] + ); + + Zone::updateZone($zid, $updtZone); + + DB::commit(); + + $apiResp = Responses::success("success update zone"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_del_zone(Request $req, $zid) + { + try { + $now = time(); + + $input = [ + "zid" => $zid, + ]; + $rulesInput = [ + "zid" => "required|integer|not_in:0", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input( + $isValidInput->messages()->first() + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $zone = Zone::showZoneById($zid); + if (count($zone) < 1) { + $apiResp = Responses::not_found("zone not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + DB::beginTransaction(); + + Zone::updateZone($zid, [ + "dlt" => $now, + "dlt_by" => $req->auth->uid, + ]); + + DB::commit(); + + $apiResp = Responses::success("success delete zone"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_list_client_zones(Request $req) + { + try { + // cptid (client_group_id / client_pt_id / company_id) + $now = time(); + + $input = [ + "cptid" => $req->cptid, + "workflow_type" => $req->workflow_type, + ]; + $rulesInput = [ + "cptid" => "nullable|integer|not_in:0", + "workflow_type" => "required|integer|not_in:0", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input( + $isValidInput->messages()->first() + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + if ($req->cptid) { + $client = Clients::getClientById($req->cptid); + if (count($client) < 1) { + $apiResp = Responses::not_found("client not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + $zones = Zone::getActiveZones( + $req->cptid, + Zone::ZONE_TYPE_WAREHOUSE, + $req->workflow_type + ); + if (count($zones) < 1) { + $apiResp = Responses::not_found( + "no available zones for client " . $client[0]->c_name + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + foreach ($zones as $key => $val) { + unset($zones[$key]->boundary_points); + } + + $apiResp = Responses::success("success list client zone"); + $apiResp["data"] = $zones; + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_list_checkpoints(Request $req) + { + try { + $now = time(); + + $input = [ + "cptid" => $req->cptid, + // 'type' => $req->type, + // 'workflow_type' => $req->workflow_type, + ]; + $rulesInput = [ + "cptid" => "nullable|integer|not_in:0", + // 'type' => 'required|integer|not_in:0', + // 'workflow_type' => 'required|integer|not_in:0', + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input( + $isValidInput->messages()->first() + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $zones = Zone::listZones($req->auth, [ + "is_active" => Zone::STATUS_ACTIVE, + ]); + if (count($zones) < 1) { + $apiResp = Responses::not_found("no available checkpoints"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + foreach ($zones as $key => $val) { + unset($zones[$key]->boundary_points); + } + + $apiResp = Responses::success("success list checkpoints"); + $apiResp["data"] = $zones; + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_user_checker_change_zone(Request $req) + { + try { + $now = time(); + + $input = [ + "ord_code" => $req->ord_code, + "zid" => $req->zid, + "zone_name" => $req->zone_name, + "zone_client" => $req->zone_client, + "zone_type" => $req->zone_type, + "workflow_zone_type" => $req->workflow_zone_type, + "shiptocode" => $req->shiptocode, + "prid" => $req->prid, + "ktid" => $req->ktid, + "kcid" => $req->kcid, + "klid" => $req->klid, + "fulladdress" => $req->fulladdress, + "status" => $req->status, + "boundary_hex_color" => $req->boundary_hex_color, + "boundary_type" => $req->boundary_type, + "boundary_latlngs" => $req->boundary_latlngs, + "boundary_bounds" => $req->boundary_bounds, + "boundary_radius" => $req->boundary_radius, + "boundary_diameter" => $req->boundary_diameter, + "boundary_area" => $req->boundary_area, // square meter + "boundary_ha" => $req->boundary_ha, // hectare + ]; + $rulesInput = [ + "ord_code" => "required|string|max:12", + "zid" => "required|integer|not_in:0", + "zone_name" => "required|string|max:255", + "zone_client" => "nullable|integer|not_in:0", + "zone_type" => "required|integer|not_in:0", + "workflow_zone_type" => "required|integer|not_in:0", + "shiptocode" => "required|string|min:5|max:6", + "prid" => "required|numeric", + "ktid" => "required|numeric", + "kcid" => "required|numeric", + "klid" => "required|numeric", + "fulladdress" => "required|string|min:55", + "status" => "required|integer|not_in:0", + "boundary_hex_color" => "required|string|min:7|max:7", + "boundary_type" => "required|string|max:25", + "boundary_latlngs" => "required|array", + "boundary_latlngs.*.lat" => "required", + "boundary_latlngs.*.lng" => "required", + "boundary_bounds" => "nullable|array", + "boundary_radius" => "nullable|numeric", + "boundary_diameter" => "nullable|numeric", + "boundary_area" => "nullable|numeric", + "boundary_ha" => "nullable|numeric", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input( + $isValidInput->messages()->first() + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $zone = Zone::showZoneById($req->zid); + if (count($zone) < 1) { + $apiResp = Responses::not_found("zone not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $uniqName = Zone::getZoneByName($req->zone_name); + if (count($uniqName) > 0) { + $notSameUser = 1; + foreach ($uniqName as $key => $row) { + if ($row->id == $req->zid) { + $notSameUser = 0; + } + } + if ($notSameUser) { + $apiResp = Responses::bad_request( + "zone name has been used" + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + $orders = Orders::showOrder([ + "code" => $req->ord_code, + // 'get_stts_checker' => 1, + // 'get_prefer_type_truck' => 1, + // 'get_checker_data' => 1, + // 'get_client_pt' => 1, + // 'get_accidents' => 1, + "couple_pck_drop" => 1, + "get_pic_zone" => 1, + // 'get_user_aprv_pck' => 1, + // 'get_user_aprv_pck' => 1, + "group_by" => "ord.id", + ]); + if (count($orders) < 1) { + $apiResp = Responses::not_found("order not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + $order = $orders[0]; + + $user = Users::getUserById($req->auth->uid); + + DB::beginTransaction(); + + $updtZone = [ + "name" => $req->zone_name, + "type" => $req->zone_type, + "workflow_type" => $req->workflow_zone_type, + "shiptocode" => $req->shiptocode, + "prid" => $req->prid, + "ktid" => $req->ktid, + "kcid" => $req->kcid, + "klid" => $req->klid, + "fulladdress" => $req->fulladdress, + "boundary_type" => $req->boundary_type, + "boundary_hex_color" => strtoupper($req->boundary_hex_color), + "boundary_latlngs" => json_encode($req->boundary_latlngs), + "boundary_bounds" => $req->boundary_bounds + ? json_encode($req->boundary_bounds) + : null, // $req->boundary_bounds ?? null, + "boundary_radius" => $req->boundary_radius ?? 0, + "boundary_diameter" => $req->boundary_diameter ?? 0, + "boundary_area" => $req->boundary_area ?? 0, + "boundary_ha" => $req->boundary_ha ?? 0, + "status" => $req->status, + "client_group_id" => + $req->zone_client ?? ($user[0]->client_group_id ?? null), + "updt" => $now, + "updt_by" => $req->auth->uid, + ]; + + // $updtZone['boundary_points'] = DB::raw("ST_GeomFromText('POINT($req->lng $req->lat)')"); + $updtZone["boundary_points"] = "ST_GeomFromText('MULTIPOINT("; + + foreach ($req->boundary_latlngs as $key => $val) { + $updtZone["boundary_points"] .= + $val["lng"] . " " . $val["lat"] . ", "; + } + $updtZone["boundary_points"] = substr( + $updtZone["boundary_points"], + 0, + -2 + ); // remove 2 last character + $updtZone["boundary_points"] .= ")')"; + $updtZone["boundary_points"] = DB::raw( + $updtZone["boundary_points"] + ); + + Zone::updateZone($req->zid, $updtZone); + + /** + * UPDATE ABOUT ZONE DROP N TRANSACTIONS + */ + + $drops = Zone::getZoneById($req->zid, ["region_name" => 1]); + if (count($drops) < 1) { + $apiResp = Responses::not_found( + "Lokasi pengantaran tidak ditemukan" + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + if (empty($drops[0]->boundary_points)) { + $apiResp = Responses::bad_request( + "Lokasi pengantaran tidak valid" + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + foreach ($drops as $iDrop => $drop) { + if ( + $drop->prid == 0 || + $drop->ktid == 0 || + $drop->kcid == 0 || + $drop->klid == 0 + ) { + $apiResp = Responses::bad_request( + "Zonasi wilayah(provinsi, kecamatan, ...) lokasi pengantaran " . + $drop->name . + " belum lengkap" + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + $drops[$iDrop]->inpt_pic_name = $order->drop_pic_name; + $drops[$iDrop]->inpt_pic_phone_code = 62; + $drops[$iDrop]->inpt_pic_phone_val = + (int) $order->drop_pic_phone_val; + $drops[$iDrop]->inpt_pic_mail = null; + + $updtDrop = [ + "ord_id" => $order->ord_id, + "ord_code" => $order->ord_code, + // 'stts_drop' => OrdersDrops::STTS_WAIT, + "drop_id" => $drop->id, + "drop_name" => $drop->name, + "drop_desc" => $drop->desc, + "drop_type" => $drop->type, + "drop_workflow" => $drop->workflow_type, + "drop_shiptocode" => $drop->shiptocode, + "drop_prid" => $drop->prid, + "drop_ktid" => $drop->ktid, + "drop_kcid" => $drop->kcid, + "drop_klid" => $drop->klid, + "drop_addr" => $drop->fulladdress, + "drop_cgroup_id" => $drop->client_group_id, + "drop_cdiv_id" => $drop->client_div_id, + "drop_cgp_id" => $drop->client_gp_id, + "drop_hex_color" => $drop->boundary_hex_color, + "drop_shape" => $drop->boundary_type, + "drop_radius" => $drop->boundary_radius, + "drop_diameter" => $drop->boundary_diameter, + "drop_area" => $drop->boundary_area, + "drop_ha" => $drop->boundary_ha, + "drop_bounds" => $drop->boundary_bounds, + "drop_latlngs" => $drop->boundary_latlngs, + "drop_points" => $drop->boundary_points, + "pic_name" => $drop->inpt_pic_name, + "pic_phone_code" => $drop->inpt_pic_phone_code, + "pic_phone_val" => $drop->inpt_pic_phone_val, + "pic_mail" => $drop->inpt_pic_mail, + ]; + OrdersDrops::updtByOrdId($order->ord_id, $updtDrop); + + // $main_item_dec = "Pengantaran Logistik
" . ucwords(strtolower($pckPoints[0]->ktid_name)) . " - " . ucwords(strtolower($dropPoints[0]->ktid_name)) . "
" . ucwords(strtolower($dropPoints[0]->name)) . ", " . ucwords(strtolower($dropPoints[0]->prid_name)) . " - " . $dropPoints[0]->shiptocode . "
" . strftime('%d %m %Y', $insPck['set_pck_at']) . "
" . $req->note_tonase; + $ktid_name = ucwords(strtolower($drop->ktid_name)); + $drop_name = ucwords(strtolower($drop->name)); + $prid_name = ucwords(strtolower($drop->prid_name)); + $shiptocode = $drop->shiptocode; + } + + $a_items = OrdersAItems::showAItem([ + "ord_id" => $order->ord_id, + "a_item_type" => OrdersAItems::A_TYPE_PRIMARY, + ]); + foreach ($a_items as $a_item) { + // splitter + $desc_br = explode("
", $a_item->desc); + $nol = $desc_br[0]; // (string) Pengantaran Logistik + $satu = explode("-", $desc_br[1]); // (array) pickup->ktid_name - drop->ktid_name + $dua_0 = explode(",", $desc_br[2]); // (array) drop->name, drop->prid_name - drop->shiptocode + $dua_1 = explode("-", $dua_0[1]); // (array) drop->prid_name - drop->shiptocode + $tiga = $desc_br[3]; // (string) DD MM YYYY + $empat = $desc_br[4]; // (string) $req->note_tonase + + // update string + $satu[1] = " " . $ktid_name; + $dua_0[0] = $drop_name; + $dua_1[0] = " " . $prid_name . " "; + $dua_1[1] = " " . $shiptocode; + + // concatination + $dua_1 = implode("-", $dua_1); + $dua_0[1] = $dua_1; + $dua_0 = implode(",", $dua_0); + $satu = implode("-", $satu); + // concatination 2 + $desc_br[0] = $nol; + $desc_br[1] = $satu; + $desc_br[2] = $dua_0; + $desc_br[3] = $tiga; + $desc_br[4] = $empat; + $main_item_desc = implode("
", $desc_br); + + OrdersAItems::updt($a_item->ord_a_item_id, [ + "desc" => $main_item_desc, + ]); + } + + DB::commit(); + + $apiResp = Responses::success("success update zone"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_user_checker_change_zone_by_zid(Request $req) + { + try { + $now = time(); + + $input = [ + "ord_id" => $req->ord_id, + "ord_code" => $req->ord_code, + "ord_drop_id" => $req->ord_drop_id, + "drop_zid" => $req->drop_zid, + ]; + $rulesInput = [ + "ord_id" => "required|integer|not_in:0", + "ord_code" => "required|string|max:12", + "ord_drop_id" => "required|integer|not_in:0", + "drop_zid" => "required|integer|not_in:0", + ]; + + // validasi input + $isValidInput = Validator::make($input, $rulesInput); + if (!$isValidInput->passes()) { + $apiResp = Responses::bad_input( + $isValidInput->messages()->first() + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $zone = Zone::showZoneById($req->drop_zid); + if (count($zone) < 1) { + $apiResp = Responses::not_found("zone not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + $orders = Orders::showOrder([ + "code" => $req->ord_code, + // 'get_stts_checker' => 1, + // 'get_prefer_type_truck' => 1, + // 'get_checker_data' => 1, + // 'get_client_pt' => 1, + // 'get_accidents' => 1, + "couple_pck_drop" => 1, + "get_pic_zone" => 1, + // 'get_user_aprv_pck' => 1, + // 'get_user_aprv_pck' => 1, + "group_by" => "ord.id", + ]); + if (count($orders) < 1) { + $apiResp = Responses::not_found("order not found"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + $order = $orders[0]; + + $user = Users::getUserById($req->auth->uid); + + DB::beginTransaction(); + + /** + * UPDATE ABOUT ZONE DROP N TRANSACTIONS + */ + + $drops = Zone::getZoneById($req->drop_zid, ["region_name" => 1]); + if (count($drops) < 1) { + $apiResp = Responses::not_found( + "Lokasi pengantaran tidak ditemukan" + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + if (empty($drops[0]->boundary_points)) { + $apiResp = Responses::bad_request( + "Lokasi pengantaran tidak valid" + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + + foreach ($drops as $iDrop => $drop) { + if ( + $drop->prid == 0 || + $drop->ktid == 0 || + $drop->kcid == 0 || + $drop->klid == 0 + ) { + $apiResp = Responses::bad_request( + "Zonasi wilayah(provinsi, kecamatan, ...) lokasi pengantaran " . + $drop->name . + " belum lengkap" + ); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + $drops[$iDrop]->inpt_pic_name = $order->drop_pic_name; + $drops[$iDrop]->inpt_pic_phone_code = 62; + $drops[$iDrop]->inpt_pic_phone_val = + (int) $order->drop_pic_phone_val; + $drops[$iDrop]->inpt_pic_mail = null; + + $updtDrop = [ + "ord_id" => $order->ord_id, + "ord_code" => $order->ord_code, + // 'stts_drop' => OrdersDrops::STTS_WAIT, + "drop_id" => $drop->id, + "drop_name" => $drop->name, + "drop_desc" => $drop->desc, + "drop_type" => $drop->type, + "drop_workflow" => $drop->workflow_type, + "drop_shiptocode" => $drop->shiptocode, + "drop_prid" => $drop->prid, + "drop_ktid" => $drop->ktid, + "drop_kcid" => $drop->kcid, + "drop_klid" => $drop->klid, + "drop_addr" => $drop->fulladdress, + "drop_cgroup_id" => $drop->client_group_id, + "drop_cdiv_id" => $drop->client_div_id, + "drop_cgp_id" => $drop->client_gp_id, + "drop_hex_color" => $drop->boundary_hex_color, + "drop_shape" => $drop->boundary_type, + "drop_radius" => $drop->boundary_radius, + "drop_diameter" => $drop->boundary_diameter, + "drop_area" => $drop->boundary_area, + "drop_ha" => $drop->boundary_ha, + "drop_bounds" => $drop->boundary_bounds, + "drop_latlngs" => $drop->boundary_latlngs, + "drop_points" => $drop->boundary_points, + "pic_name" => $drop->inpt_pic_name, + "pic_phone_code" => $drop->inpt_pic_phone_code, + "pic_phone_val" => $drop->inpt_pic_phone_val, + "pic_mail" => $drop->inpt_pic_mail, + ]; + OrdersDrops::updt($order->ord_drop_id, $updtDrop); + + // $main_item_dec = "Pengantaran Logistik
" . ucwords(strtolower($pckPoints[0]->ktid_name)) . " - " . ucwords(strtolower($dropPoints[0]->ktid_name)) . "
" . ucwords(strtolower($dropPoints[0]->name)) . ", " . ucwords(strtolower($dropPoints[0]->prid_name)) . " - " . $dropPoints[0]->shiptocode . "
" . strftime('%d %m %Y', $insPck['set_pck_at']) . "
" . $req->note_tonase; + $ktid_name = ucwords(strtolower($drop->ktid_name)); + $drop_name = ucwords(strtolower($drop->name)); + $prid_name = ucwords(strtolower($drop->prid_name)); + $shiptocode = $drop->shiptocode; + } + + $a_items = OrdersAItems::showAItem([ + "ord_id" => $order->ord_id, + "a_item_type" => OrdersAItems::A_TYPE_PRIMARY, + ]); + foreach ($a_items as $a_item) { + // splitter + $desc_br = explode("
", $a_item->desc); + $nol = $desc_br[0]; // (string) Pengantaran Logistik + $satu = explode("-", $desc_br[1]); // (array) pickup->ktid_name - drop->ktid_name + $dua_0 = explode(",", $desc_br[2]); // (array) drop->name, drop->prid_name - drop->shiptocode + $dua_1 = explode("-", $dua_0[1]); // (array) drop->prid_name - drop->shiptocode + $tiga = $desc_br[3]; // (string) DD MM YYYY + $empat = $desc_br[4]; // (string) $req->note_tonase + + // update string + $satu[1] = " " . $ktid_name; + $dua_0[0] = $drop_name; + $dua_1[0] = " " . $prid_name . " "; + $dua_1[1] = " " . $shiptocode; + + // concatination + $dua_1 = implode("-", $dua_1); + $dua_0[1] = $dua_1; + $dua_0 = implode(",", $dua_0); + $satu = implode("-", $satu); + // concatination 2 + $desc_br[0] = $nol; + $desc_br[1] = $satu; + $desc_br[2] = $dua_0; + $desc_br[3] = $tiga; + $desc_br[4] = $empat; + $main_item_desc = implode("
", $desc_br); + + OrdersAItems::updt($a_item->ord_a_item_id, [ + "desc" => $main_item_desc, + ]); + } + + DB::commit(); + + $apiResp = Responses::success("success update zone"); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + DB::rollBack(); + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } + + public function api_universal_list_zones(Request $req) + { + try { + $now = time(); + $input = []; + $rulesInput = []; + + // validasi input + // $isValidInput = Validator::make($input, $rulesInput); + // if (!$isValidInput->passes()) { + // $apiResp = Responses::bad_input($isValidInput->messages()->first()); + // return new Response($apiResp, $apiResp['meta']['code']); + // } + + $filter = []; + if ($req->cptid) { + $filter["company"] = $req->cptid; + } + if ($req->status) { + $filter["is_active"] = $req->status; + } + + if ($req->auth->role === Users::ROLE_SPECIAL_TRACKING) { + // $filter['vid'] = 0; + $filter["company"] = $req->auth->client_group_id; + } + + $list = Zone::listZones($req->auth, $filter); + + foreach ($list as $key => $row) { + $list[$key]->DT_RowIndex = $key + 1; + $list[$key]->action = "-"; + unset($list[$key]->boundary_points); + } + + $apiResp = Responses::success("success list zones"); + $apiResp["data"] = $list; + $apiResp["count"] = count($list); + return new Response($apiResp, $apiResp["meta"]["code"]); + } catch (\Exception $e) { + $apiResp = Responses::error($e->getMessage()); + return new Response($apiResp, $apiResp["meta"]["code"]); + } + } +} diff --git a/app/Http/Kernel.php b/app/Http/Kernel.php new file mode 100755 index 0000000..c87e22c --- /dev/null +++ b/app/Http/Kernel.php @@ -0,0 +1,68 @@ + [ + \App\Http\Middleware\EncryptCookies::class, + \Illuminate\Cookie\Middleware\AddQueuedCookiesToResponse::class, + \Illuminate\Session\Middleware\StartSession::class, + // \Illuminate\Session\Middleware\AuthenticateSession::class, + \Illuminate\View\Middleware\ShareErrorsFromSession::class, + \App\Http\Middleware\VerifyCsrfToken::class, + \Illuminate\Routing\Middleware\SubstituteBindings::class, + ], + + 'api' => [ + 'throttle:60,1', + \Illuminate\Routing\Middleware\SubstituteBindings::class, + ], + ]; + + /** + * The application's route middleware. + * + * These middleware may be assigned to groups or used individually. + * + * @var array + */ + protected $routeMiddleware = [ + 'auth' => \App\Http\Middleware\Authenticate::class, + 'auth.basic' => \Illuminate\Auth\Middleware\AuthenticateWithBasicAuth::class, + 'auth.user' => \App\Http\Middleware\AuthUser::class, + 'bindings' => \Illuminate\Routing\Middleware\SubstituteBindings::class, + 'cache.headers' => \Illuminate\Http\Middleware\SetCacheHeaders::class, + 'can' => \Illuminate\Auth\Middleware\Authorize::class, + 'guest' => \App\Http\Middleware\RedirectIfAuthenticated::class, + 'password.confirm' => \Illuminate\Auth\Middleware\RequirePassword::class, + 'signed' => \Illuminate\Routing\Middleware\ValidateSignature::class, + 'throttle' => \Illuminate\Routing\Middleware\ThrottleRequests::class, + 'verified' => \Illuminate\Auth\Middleware\EnsureEmailIsVerified::class, + ]; +} diff --git a/app/Http/Middleware/AuthUser.php b/app/Http/Middleware/AuthUser.php new file mode 100755 index 0000000..61af0fb --- /dev/null +++ b/app/Http/Middleware/AuthUser.php @@ -0,0 +1,242 @@ +auth = Auth::user(); + $request->auth->uid = $request->auth->id; + + if ($request->auth->role == Users::ROLE_ADMIN) { + // views + if ($request->is("home/*")) { + } elseif ($request->is("home")) { + } elseif ($request->is("dashboard/*")) { + } elseif ($request->is("dashboard")) { + } elseif ($request->is("drivers/*")) { + } elseif ($request->is("drivers")) { + } elseif ($request->is("transactions/*")) { + } elseif ($request->is("transactions")) { + } elseif ($request->is("vehicles/*")) { + } elseif ($request->is("vehicles")) { + } elseif ($request->is("clients/*")) { + } elseif ($request->is("clients")) { + } elseif ($request->is("zone/*")) { + } elseif ($request->is("zone")) { + } elseif ($request->is("users/*")) { + } elseif ($request->is("users")) { + } elseif ($request->is("profile/*")) { + } elseif ($request->is("profile")) { + } elseif ($request->is("config/*")) { + } elseif ($request->is("config")) { + } elseif ($request->is("pocket/*")) { + } elseif ($request->is("pocket")) { + } elseif ($request->is("lgb_types/*")) { + } elseif ($request->is("lgb_types")) { + } elseif ($request->is("lgb_masters/*")) { + } elseif ($request->is("lgb_masters")) { + } elseif ($request->is("insurances/*")) { + } elseif ($request->is("static_insurances/*")) { + } + // api + elseif ($request->is("api/conf/*")) { + } elseif ($request->is("api/conf")) { + } elseif ($request->is("api/osm/*")) { + } elseif ($request->is("api/osm")) { + } elseif ($request->is("api/region/*")) { + } elseif ($request->is("api/region")) { + } elseif ($request->is("api/zones/*")) { + } elseif ($request->is("api/zones")) { + } elseif ($request->is("api/vehicles/*")) { + } elseif ($request->is("api/vehicles")) { + } elseif ($request->is("api/drivers/*")) { + } elseif ($request->is("api/drivers")) { + } elseif ($request->is("api/users/*")) { + } elseif ($request->is("api/users")) { + } elseif ($request->is("api/clients/*")) { + } elseif ($request->is("api/clients")) { + } elseif ($request->is("api/tracks/*")) { + } elseif ($request->is("api/tracks")) { + } elseif ($request->is("api/transactions/*")) { + } elseif ($request->is("api/transactions")) { + } elseif ($request->is("api/transactions_spc/*")) { + } elseif ($request->is("api/transactions_spc")) { + } elseif ($request->is("api/insurances/*")) { + } elseif ($request->is("api/insurances")) { + } elseif ($request->is("api/devices/*")) { + } elseif ($request->is("api/devices")) { + } elseif ($request->is("api/user/clients/*")) { + } elseif ($request->is("api/user/clients")) { + } elseif ($request->is("api/a_items/*")) { + } elseif ($request->is("api/a_items")) { + } elseif ($request->is("api/admin/*")) { + } elseif ($request->is("api/admin")) { + } elseif ($request->is("api/static_insurances/*")) { + } elseif ($request->is("api/static_insurances")) { + } elseif ($request->is("api/menu_permissions/*")) { + } elseif ($request->is("api/menu_permissions")) { + } elseif ($request->is("api/pocket/*")) { + } elseif ($request->is("api/pocket")) { + } elseif ($request->is("api/lgb_types/*")) { + } elseif ($request->is("api/lgb_types")) { + } elseif ($request->is("api/lgb_keys/*")) { + } elseif ($request->is("api/lgb_keys")) { + } elseif ($request->is("api/dtypes/*")) { + } elseif ($request->is("api/dtypes")) { + } elseif ($request->is("api/dana/*")) { + } elseif ($request->is("api/dana")) { + } elseif ($request->is("api/universal/*")) { + } elseif ($request->is("api/universal")) { + } else { + return abort(403, "Unauthorized action."); + } + } elseif ($request->auth->role == Users::ROLE_VENDOR) { + // views + if ($request->is("home/*")) { + } elseif ($request->is("home")) { + } elseif ($request->is("dashboard/*")) { + } elseif ($request->is("dashboard")) { + } elseif ($request->is("checklist/*")) { + } elseif ($request->is("checklist")) { + } elseif ($request->is("zone/*")) { + } elseif ($request->is("zone")) { + } elseif ($request->is("drivers/*")) { + } elseif ($request->is("drivers")) { + } elseif ($request->is("vehicles/*")) { + } elseif ($request->is("vehicles")) { + } elseif ($request->is("profile/*")) { + } elseif ($request->is("transactions/*")) { + } elseif ($request->is("transactions")) { + } elseif ($request->is("profile")) { + } elseif ($request->is("user/vendor/*")) { + } elseif ($request->is("user/vendor")) { + } + // api + elseif ($request->is("api/conf")) { + } elseif ($request->is("api/osm/*")) { + } elseif ($request->is("api/osm")) { + } elseif ($request->is("api/region/*")) { + } elseif ($request->is("api/region")) { + } elseif ($request->is("api/tracks/*")) { + } elseif ($request->is("api/tracks")) { + } elseif ($request->is("api/vehicles/*")) { + } elseif ($request->is("api/vehicles")) { + } elseif ($request->is("api/drivers/*")) { + } elseif ($request->is("api/drivers")) { + } elseif ($request->is("api/user/vendor/*")) { + } elseif ($request->is("api/user/vendor")) { + } elseif ($request->is("api/transactions_spc/*")) { + } elseif ($request->is("api/transactions_spc")) { + } elseif ($request->is("api/zones/*")) { + } elseif ($request->is("api/zones")) { + } elseif ($request->is("api/users/*")) { + } elseif ($request->is("api/users")) { + } elseif ($request->is("api/universal/*")) { + } elseif ($request->is("api/universal")) { + } else { + return abort(403, "Unauthorized action."); + } + } elseif ($request->auth->role == Users::ROLE_CLIENT_ADMIN) { + // views + if ($request->is("home/*")) { + } elseif ($request->is("home")) { + } elseif ($request->is("dashboard/*")) { + } elseif ($request->is("dashboard")) { + } elseif ($request->is("zone/*")) { + } elseif ($request->is("zone")) { + } elseif ($request->is("profile/*")) { + } elseif ($request->is("profile")) { + } elseif ($request->is("user/clients/*")) { + } elseif ($request->is("user/clients")) { + } + // api + elseif ($request->is("api/conf")) { + } elseif ($request->is("api/osm/*")) { + } elseif ($request->is("api/osm")) { + } elseif ($request->is("api/region/*")) { + } elseif ($request->is("api/region")) { + } elseif ($request->is("api/zones/*")) { + } elseif ($request->is("api/zones")) { + } elseif ($request->is("api/tracks/*")) { + } elseif ($request->is("api/tracks")) { + } elseif ($request->is("api/user/clients/*")) { + } elseif ($request->is("api/user/clients")) { + } elseif ($request->is("api/users/*")) { + } elseif ($request->is("api/users")) { + } elseif ($request->is("api/universal/*")) { + } elseif ($request->is("api/universal")) { + } else { + return abort(403, "Unauthorized action."); + } + } elseif ($request->auth->role == Users::ROLE_CHECKER) { + // views + if ($request->is("user/checker/*")) { + } elseif ($request->is("user/checker")) { + } elseif ($request->is("profile/*")) { + } elseif ($request->is("profile")) { + } + // api + elseif ($request->is("api/user/checker/*")) { + } elseif ($request->is("api/user/checker")) { + } elseif ($request->is("api/users/*")) { + } elseif ($request->is("api/users")) { + } elseif ($request->is("api/universal/*")) { + } elseif ($request->is("api/universal")) { + } else { + return abort(403, "Unauthorized action."); + } + } elseif ($request->auth->role == Users::ROLE_FINANCE) { + // views + if ($request->is("finance/*")) { + } elseif ($request->is("profile/*")) { + } elseif ($request->is("profile")) { + } + // api + elseif ($request->is("api/finance/*")) { + } elseif ($request->is("api/finance")) { + } elseif ($request->is("api/a_items/*")) { + } elseif ($request->is("api/a_items")) { + } elseif ($request->is("api/users/*")) { + } elseif ($request->is("api/users")) { + } elseif ($request->is("api/dana/*")) { + } elseif ($request->is("api/dana")) { + } elseif ($request->is("api/universal/*")) { + } elseif ($request->is("api/universal")) { + } else { + return abort(403, "Unauthorized action."); + } + } elseif ($request->auth->role == Users::ROLE_SPECIAL_TRACKING) { + // views + if ($request->is("dashboard/*")) { + } elseif ($request->is("dashboard")) { + } + // api + elseif ($request->is("api/tracks/*")) { + } elseif ($request->is("api/tracks")) { + } elseif ($request->is("api/users/*")) { + } elseif ($request->is("api/users")) { + } elseif ($request->is("api/universal/*")) { + } elseif ($request->is("api/universal")) { + } else { + return abort(403, "Unauthorized action."); + } + } else { + return abort(403, "Unauthorized action."); + } + + return $next($request); + } +} diff --git a/app/Http/Middleware/Authenticate.php b/app/Http/Middleware/Authenticate.php new file mode 100755 index 0000000..5090fa4 --- /dev/null +++ b/app/Http/Middleware/Authenticate.php @@ -0,0 +1,22 @@ +expectsJson()) { + return route('login'); + } + } +} diff --git a/app/Http/Middleware/CheckForMaintenanceMode.php b/app/Http/Middleware/CheckForMaintenanceMode.php new file mode 100755 index 0000000..35b9824 --- /dev/null +++ b/app/Http/Middleware/CheckForMaintenanceMode.php @@ -0,0 +1,17 @@ +check()) { + return redirect(RouteServiceProvider::HOME); + } + + return $next($request); + } +} diff --git a/app/Http/Middleware/TrimStrings.php b/app/Http/Middleware/TrimStrings.php new file mode 100755 index 0000000..5a50e7b --- /dev/null +++ b/app/Http/Middleware/TrimStrings.php @@ -0,0 +1,18 @@ +allSubdomainsOfApplicationUrl(), + ]; + } +} diff --git a/app/Http/Middleware/TrustProxies.php b/app/Http/Middleware/TrustProxies.php new file mode 100755 index 0000000..087cac7 --- /dev/null +++ b/app/Http/Middleware/TrustProxies.php @@ -0,0 +1,29 @@ +system, 1=>admin, 2=>finance + const CRT_TYPE_SYSTEM = 0; + const CRT_TYPE_ADMIN = 1; + const CRT_TYPE_FINANCE = 2; + + public static function listAItems($filter = []) + { + $params = []; + $select = ''; + $where = ''; + + if (isset($filter['is_active'])) { + $where .= ' AND a_item.is_active = ?'; + $params[] = $filter['is_active']; + } + + if (isset($filter['crt_type'])) { + $where .= ' AND a_item.crt_type = ?'; + $params[] = $filter['crt_type']; + } + + return DB::select("SELECT + a_item.*,ut.name as type_name + $select + FROM + t_a_items as a_item + INNER JOIN t_unit_types as ut ON a_item.type = ut.id + WHERE a_item.dlt is null + $where + ORDER BY a_item.name ASC + ;", + $params); + } + + public static function showAItemsById($id) + { + return DB::select("SELECT * FROM t_a_items as a_item WHERE dlt is null AND id = ? LIMIT 1;", [$id]); + } + + public static function get() + { + return DB::select("SELECT * FROM t_a_items as a_item WHERE dlt is null ORDER BY a_item.name ASC;"); + } + + public static function getById($id) + { + return DB::select("SELECT * FROM t_a_items as a_item WHERE dlt is null AND id = ? LIMIT 1;", [$id]); + } + + public static function getByName($name, $filter = []) + { + $params = [$name]; + $where = ''; + if (isset($filter['crt_type'])) { + $where .= ' AND a_item.crt_type = ?'; + $params[] = $filter['crt_type']; + } + return DB::select("SELECT * FROM t_a_items as a_item WHERE dlt is null AND name = ? $where LIMIT 1;", $params); + } + + public static function add($data) + { + $id = DB::table("t_a_items")->insertGetId($data); + return $id; + } + + public static function updt($id, $data) + { + return DB::table("t_a_items")->where("id", $id)->update($data); + } + + public static function dlt($id) + { + return DB::table("t_a_items")->where("id", $id)->delete(); + } +} diff --git a/app/Models/Banks.php b/app/Models/Banks.php new file mode 100755 index 0000000..32997e7 --- /dev/null +++ b/app/Models/Banks.php @@ -0,0 +1,93 @@ +insertGetId($data); + return $bid; + } + + public static function updateBank($bid, $data) + { + return DB::table("t_banks")->where("id", $bid)->update($data); + } + + public static function deleteBank($bid) + { + return DB::table("t_banks")->where("id", $bid)->delete(); + } +} diff --git a/app/Models/Checkpoints.php b/app/Models/Checkpoints.php new file mode 100755 index 0000000..3fea98b --- /dev/null +++ b/app/Models/Checkpoints.php @@ -0,0 +1,80 @@ +insertGetId($data); + return $pid; + } + + public static function updateCheckpoint($id, $data) + { + return DB::table("t_checkpoints")->where("id", $id)->update($data); + } + + public static function deleteCheckpoint($id) + { + return DB::table("t_checkpoints")->where("id", $id)->delete(); + } + + public static function deleteCheckpointByPocketId($pocket_id) + { + return DB::table("t_checkpoints")->where("pocket_id", $pocket_id)->delete(); + } +} diff --git a/app/Models/Clients.php b/app/Models/Clients.php new file mode 100755 index 0000000..435af55 --- /dev/null +++ b/app/Models/Clients.php @@ -0,0 +1,172 @@ +insertGetId($data); + return $cid; + } + + public static function updateClient($cid, $data) + { + return DB::table("t_clients") + ->where("id", $cid) + ->update($data); + } + + public static function deleteClient($cid) + { + return DB::table("t_clients") + ->where("id", $cid) + ->delete(); + } + + public static function select2Client($cid = null) + { + $query = ""; + $params = []; + + if ($cid) { + $query .= "SELECT id,c_name as name FROM t_clients AS c WHERE dlt is null AND c.id = ?;"; + $params[] = $cid; + } else { + $query .= "SELECT id,c_name as name FROM t_clients AS c WHERE dlt is null;"; + } + + return DB::select($query, $params); + } + + public static function arrDiscountTypes() + { + return [Clients::DISC_TYPE_NO, Clients::DISC_TYPE_FIX, Clients::DISC_TYPE_PERCENT]; + } + + public static function select2DiscountTypes() + { + return [ + [ + "id" => Clients::DISC_TYPE_NO, + "name" => "No Discount", + ], + [ + "id" => Clients::DISC_TYPE_FIX, + "name" => "Fix Amount", + ], + [ + "id" => Clients::DISC_TYPE_PERCENT, + "name" => "Percent Amount", + ], + ]; + } +} diff --git a/app/Models/ClientsDivGroups.php b/app/Models/ClientsDivGroups.php new file mode 100755 index 0000000..2b9e152 --- /dev/null +++ b/app/Models/ClientsDivGroups.php @@ -0,0 +1,43 @@ +insertGetId($data); + return $c_div_group_id; + } + + public static function updateCDivGroup($c_div_group_id, $data) + { + return DB::table("t_clients_div_groups")->where("id", $c_div_group_id)->update($data); + } + + public static function deleteCDivGroup($c_div_group_id) + { + return DB::table("t_clients_div_groups")->where("id", $c_div_group_id)->delete(); + } +} diff --git a/app/Models/ClientsDivs.php b/app/Models/ClientsDivs.php new file mode 100755 index 0000000..116893b --- /dev/null +++ b/app/Models/ClientsDivs.php @@ -0,0 +1,43 @@ +insertGetId($data); + return $client_div_id; + } + + public static function updateCDiv($client_div_id, $data) + { + return DB::table("t_clients_divs")->where("id", $client_div_id)->update($data); + } + + public static function deleteCDiv($client_div_id) + { + return DB::table("t_clients_divs")->where("id", $client_div_id)->delete(); + } +} diff --git a/app/Models/ConfRates.php b/app/Models/ConfRates.php new file mode 100755 index 0000000..51df1c8 --- /dev/null +++ b/app/Models/ConfRates.php @@ -0,0 +1,149 @@ +insertGetId($data); + return $rid; + } + + public static function updateRate($rid, $data) + { + return DB::table("t_conf_rates")->where("id", $rid)->update($data); + } + + public static function deleteRate($rid) + { + return DB::table("t_conf_rates")->where("id", $rid)->delete(); + } + + /** + * t_conf_lane + */ + + public static function getLanesActive() + { + return DB::select("SELECT * FROM t_conf_lanes WHERE dlt is null AND is_active = 1;"); + } +} diff --git a/app/Models/ConfTruckTypes.php b/app/Models/ConfTruckTypes.php new file mode 100755 index 0000000..c3fd123 --- /dev/null +++ b/app/Models/ConfTruckTypes.php @@ -0,0 +1,104 @@ +insertGetId($data); + return $ttid; + } + + public static function updateTruckType($ttid, $data) + { + return DB::table("t_conf_truck_types")->where("id", $ttid)->update($data); + } + + public static function deleteTruckType($ttid) + { + return DB::table("t_conf_truck_types")->where("id", $ttid)->delete(); + } + + /** + * t_vehicles_types + */ + + public static function getTypeById($id) + { + return DB::select("SELECT * FROM t_vehicles_types WHERE id = ? LIMIT 1;", [$id]); + } + + public static function addTypes($data) + { + return DB::table("t_vehicles_types")->insertGetId($data); + } + + public static function updtTypes($tid, $data) + { + return DB::table("t_vehicles_types")->where("id", $tid)->update($data); + } +} diff --git a/app/Models/Dana.php b/app/Models/Dana.php new file mode 100755 index 0000000..4ffb7e9 --- /dev/null +++ b/app/Models/Dana.php @@ -0,0 +1,65 @@ +insertGetId($data); + return $pid; + } + + public static function updateDana($id, $data) + { + return DB::table("t_dana")->where("id", $id)->update($data); + } + + public static function deleteDana($id) + { + return DB::table("t_dana")->where("id", $id)->delete(); + } +} diff --git a/app/Models/DataTypes.php b/app/Models/DataTypes.php new file mode 100755 index 0000000..9706a11 --- /dev/null +++ b/app/Models/DataTypes.php @@ -0,0 +1,107 @@ +insertGetId($data); + return $data_types_id; + } + + public static function updateDataType($data_types_id, $data) + { + return DB::table("t_datatypes")->where("id", $data_types_id)->update($data); + } + + public static function deleteDataType($data_types_id) + { + return DB::table("t_datatypes")->where("id", $data_types_id)->delete(); + } +} diff --git a/app/Models/Devices.php b/app/Models/Devices.php new file mode 100755 index 0000000..e999b9b --- /dev/null +++ b/app/Models/Devices.php @@ -0,0 +1,110 @@ +insertGetId($data); + return $id; + } + + public static function updateDevice($id, $data) + { + return DB::table("t_devices")->where("id", $id)->update($data); + } + + public static function deleteDevice($id) + { + return DB::table("t_devices")->where("id", $id)->delete(); + } +} diff --git a/app/Models/Drivers.php b/app/Models/Drivers.php new file mode 100755 index 0000000..4c7d060 --- /dev/null +++ b/app/Models/Drivers.php @@ -0,0 +1,318 @@ +role == Users::ROLE_VENDOR) { + $where .= " AND d.vendor_id = " . $auth->uid; + } + + if (isset($filter["company"])) { + $where .= " AND client.id = ?"; + $params[] = $filter["company"]; + } + + // d.nik,d.fullname,d.phone,d.phone_code,d.email,d.dob,d.age,d.gender,d.blood,d.fulladdress,d.crt,d.crt_by,d.updt,d.updt_by, + // dt.ktp_img,dt.npwp_img,dt.npwp_number,dt.npwp_string,dt.license_img,dt.license_number,dt.license_exp,dt.em_fullname,dt.em_phone,dt.em_phone_code,dt.em_relationship + return DB::select( + "SELECT + " . + self::defaultSelectDriver . + " + ,client.c_name as company_name + " . + $select . + " + FROM t_drivers as d + INNER JOIN t_drivers_detail AS dt ON d.id = dt.did + LEFT JOIN t_users AS vdr ON d.vendor_id = vdr.id + LEFT JOIN t_clients AS client ON vdr.client_group_id = client.id + " . + $join . + " + WHERE d.dlt is null + " . + $where . + " + ORDER BY d.id ASC;", + $params + ); + } + + public static function getDrivers($auth, $filter = []) + { + $params = []; + $where_vendor = ""; + $join_vendor = ""; + if ($auth->role != Users::ROLE_ADMIN) { + $where_vendor .= " AND d.vendor_id = " . $auth->uid; + } + if (isset($filter["status"])) { + $where_vendor .= " AND d.status = ?"; + array_push($params, $filter["status"]); + } + return DB::select( + "SELECT * FROM t_drivers as d WHERE dlt is null " . + $where_vendor . + ";", + $params + ); + } + + public static function showDriverById($did) + { + return DB::select( + "SELECT + " . + self::defaultSelectDriver . + " + FROM t_drivers AS d + INNER JOIN t_drivers_detail AS dt ON d.id = dt.did + WHERE d.dlt is null AND d.id = ? LIMIT 1;", + [$did] + ); + } + + public static function getDriverById($did) + { + return DB::select( + "SELECT * FROM t_drivers WHERE dlt is null AND id = ? LIMIT 1;", + [$did] + ); + } + + public static function getDriverByEmail($email) + { + return DB::select( + "SELECT * FROM t_drivers WHERE dlt is null AND email = ? LIMIT 2;", + [$email] + ); + } + + public static function getDriverByPhone($phone) + { + return DB::select( + "SELECT * FROM t_drivers WHERE dlt is null AND phone = ? LIMIT 2;", + [$phone] + ); + } + + public static function getDriverByNik($nik) + { + return DB::select( + "SELECT * FROM t_drivers WHERE dlt is null AND nik = ? LIMIT 2;", + [$nik] + ); + } + + public static function getDriverByIdAllData($did) + { + return DB::select( + "SELECT + *,d.id as drv_id + FROM t_drivers as d + INNER JOIN t_drivers_detail as dt ON d.id = dt.did + WHERE d.dlt is null + AND d.id = ? + LIMIT 1;", + [$did] + ); + } + + public static function getDriversNoInOrder($auth, $filter = []) + { + $params = []; + $where_vendor = ""; + $join_vendor = ""; + if ($auth->role != Users::ROLE_ADMIN) { + $where_vendor .= " AND d.vendor_id = " . $auth->uid; + } + if (isset($filter["status"])) { + $where_vendor .= " AND d.status = ?"; + array_push($params, $filter["status"]); + } + return DB::select( + "SELECT + d.*,ord.status as ord_status + FROM t_drivers as d + LEFT JOIN (SELECT MAX(ord_id) as max_ord_id,drv_id FROM t_orders_drivers GROUP BY drv_id) as ord_drv1 ON (d.id = ord_drv1.drv_id) + LEFT JOIN t_orders as ord ON (ord_drv1.max_ord_id = ord.id) + WHERE d.dlt is null + AND (ord.status is null OR ord.status IN (" . + Orders::STTS_CLIENT_PAY . + "," . + Orders::STTS_VENDOR_PAYED . + "," . + Orders::STTS_CLOSE . + "," . + Orders::STTS_CANCEL . + ")) + " . + $where_vendor . + " + ;", + $params + ); + } + + public static function getDriversNoInOrderNew($auth, $filter = []) + { + $params = []; + $where_vendor = ""; + $join_vendor = ""; + if ($auth->role != Users::ROLE_ADMIN) { + $where_vendor .= " AND d.vendor_id = " . $auth->uid; + } + if (isset($filter["status"])) { + $where_vendor .= " AND d.status = ?"; + array_push($params, $filter["status"]); + } + return DB::select( + "SELECT + d.* + FROM t_drivers as d + WHERE d.dlt is null + AND d.is_in_ord = " . + Drivers::IN_ORD_NO . + " + " . + $where_vendor . + " + ;", + $params + ); + } + + public static function likeName($name) + { + $params = ["%" . $name . "%"]; + + return DB::select( + "SELECT drv.*,drv_dtl.bank_id,drv_dtl.bank_code,drv_dtl.bank_name,drv_dtl.bank_short_name,drv_dtl.bank_branch_name,drv_dtl.bank_acc_number,drv_dtl.bank_acc_name FROM t_drivers as drv INNER JOIN t_drivers_detail as drv_dtl ON drv.id = drv_dtl.did WHERE dlt is null AND fullname LIKE ?;", + $params + ); + } + + public static function addDriver($data) + { + $did = DB::table("t_drivers")->insertGetId($data); + return $did; + } + + public static function updateDriver($did, $data) + { + return DB::table("t_drivers") + ->where("id", $did) + ->update($data); + } + + public static function deleteDriver($did) + { + return DB::table("t_drivers") + ->where("id", $did) + ->delete(); + } + + public static function listRelationships() + { + // ENUM('wife', 'husband', 'sister', 'brother', 'father', 'mother', 'uncle', 'aunt', 'daughter', 'children', 'grandfather', 'grandmother', 'nephew', 'niece', 'family', 'sibling', 'son', 'cousin') + return [ + [ + "id" => "wife", + "name" => "Wife", + ], + [ + "id" => "husband", + "name" => "Husband", + ], + [ + "id" => "sister", + "name" => "Sister", + ], + [ + "id" => "brother", + "name" => "Brother", + ], + [ + "id" => "father", + "name" => "Father", + ], + [ + "id" => "mother", + "name" => "Mother", + ], + [ + "id" => "uncle", + "name" => "Uncle", + ], + [ + "id" => "aunt", + "name" => "Aunt", + ], + [ + "id" => "cousin", + "name" => "Cousin", + ], + [ + "id" => "daughter", + "name" => "Daughter", + ], + [ + "id" => "son", + "name" => "Son", + ], + [ + "id" => "children", + "name" => "Children", + ], + [ + "id" => "grandfather", + "name" => "Grandfather", + ], + [ + "id" => "grandmother", + "name" => "Grandmother", + ], + [ + "id" => "nephew", + "name" => "Nephew", + ], + [ + "id" => "niece", + "name" => "Niece", + ], + [ + "id" => "family", + "name" => "Family", + ], + [ + "id" => "sibling", + "name" => "Sibling", + ], + ]; + } +} diff --git a/app/Models/DriversDetail.php b/app/Models/DriversDetail.php new file mode 100755 index 0000000..30672fa --- /dev/null +++ b/app/Models/DriversDetail.php @@ -0,0 +1,40 @@ +insertGetId($data); + return $id; + } + + public static function updateDetailByDid($id, $data) + { + return DB::table("t_drivers_detail")->where("did", $id)->update($data); + } + + public static function updateDetail($id, $data) + { + return DB::table("t_drivers_detail")->where("id", $id)->update($data); + } + + public static function deleteDetail($id) + { + return DB::table("t_drivers_detail")->where("id", $id)->delete(); + } +} diff --git a/app/Models/DrvPhoneDevices.php b/app/Models/DrvPhoneDevices.php new file mode 100755 index 0000000..ff58c7d --- /dev/null +++ b/app/Models/DrvPhoneDevices.php @@ -0,0 +1,87 @@ +insertGetId($data); + return $id; + } + + public static function updt($id, $data) + { + return DB::table("t_phone_devices")->where("id", $id)->update($data); + } + + public static function updtByOrdDrvId($did, $data) + { + return DB::table("t_phone_devices")->where("did", $did)->update($data); + } + + public static function dlt($id) + { + return DB::table("t_phone_devices")->where("id", $id)->delete(); + } + + public static function dltByOrdDrvId($did) + { + return DB::table("t_phone_devices")->where("did", $did)->delete(); + } +} diff --git a/app/Models/Dummy.php b/app/Models/Dummy.php new file mode 100755 index 0000000..4f52299 --- /dev/null +++ b/app/Models/Dummy.php @@ -0,0 +1,60 @@ +insertGetId($data); + return $id; + } + + public static function getByGpsId($gps_id) + { + return DB::select("SELECT * FROM t_dummy_tracks WHERE gps_id = ?;", [$gps_id]); + } + + public static function updateDummyTrack($data) + { + return DB::table("t_dummy_tracks")->where("id", $data['id'])->update($data); + } + + public static function deleteDummyTrack($data) + { + return DB::table("t_dummy_tracks")->where("id", $data['id'])->delete(); + } + + // ------------------------------------------------------------------------------------------------------------------------------------------------------------------ + + public static function addDummyHub($data) + { + $id = DB::table("t_dummy_hubs")->insertGetId($data); + return $id; + } + + /** + * https://stackoverflow.com/questions/574691/mysql-great-circle-distance-haversine-formula + * miles: 3958.756 || 3959 + * km: 6371 + * meters: 6371000 + * more accurate using km/meters than miles i think ~ rafifmulia + */ + public static function nearestHubInCircle($lat, $lng) + { + $query = "SELECT id,name, ( 6371000 * acos( cos( radians( :lat1 ) ) * cos( radians( lat ) ) + * cos( radians( lng ) - radians( :lng ) ) + sin( radians( :lat2 ) ) * sin(radians( lat )) ) ) AS distance + FROM t_dummy_hubs + HAVING distance <= 800 + ORDER BY distance;"; + $params = [ + 'lat1' => $lat, + 'lat2' => $lat, + 'lng' => $lng, + ]; + return DB::select($query, $params); + } +} diff --git a/app/Models/Finance.php b/app/Models/Finance.php new file mode 100755 index 0000000..334c63f --- /dev/null +++ b/app/Models/Finance.php @@ -0,0 +1,621 @@ + $v) { + $binds_ids .= "?,"; + $params[] = $v; + } + if (substr($binds_ids, -1) === ',') { + $binds_ids = substr($binds_ids, 0, -1); + } + $where_where .= " AND ord_a_item.ord_id IN ($binds_ids)"; + } + + if (isset($filter['is_aprv'])) { + $where_where .= ' AND ord_a_item.is_aprv = ?'; + $params[] = $filter['is_aprv']; + } + + if (isset($filter['get_user_crt'])) { + $select_order .= ',ucrt.first_name as ucrt_name'; + $join_join .= ' LEFT JOIN t_users as ucrt ON ord_a_item.crt_by = ucrt.id'; + } + + if (isset($filter['get_user_rjct'])) { + $select_order .= ',urjct.first_name as urjct_name,urjct_bill.first_name as urjct_bill_name'; + $join_join .= ' LEFT JOIN t_users as urjct ON ord_a_item.rjct_by = urjct.id'; + $join_join .= ' LEFT JOIN t_users as urjct_bill ON ord_a_item.rjct_bill_by = urjct_bill.id'; + } + + $params[] = OrdersAItems::ONLY_CLIENT_NO; + $params[] = OrdersAItems::CALC_TO_VDR_YES; + $params[] = OrdersAItems::IS_HIDDEN_NO; + $params[] = OrdersAItems::STTS_MERGE_NO; + $params[] = OrdersAItems::STTS_MERGE_RESULT; + + if (isset($filter['group_by'])) { + $group_by .= ' GROUP BY ' . $filter['group_by']; + } + + return DB::select( + "SELECT + ord_a_item.id as ord_a_item_id,ord_a_item.v_termin_id,ord_a_item.ord_id,ord_a_item.ord_code + ,ord_a_item.desc,ord_a_item.a_item_type,ord_a_item.crt_type as a_item_crt_type + ,ord_a_item.crt as a_item_crt_at + ,ord_a_item.amt_base_flat,ord_a_item.unit_qty,ord_a_item.amt_tax_type,ord_a_item.amt_total_tax_flat,ord_a_item.amt_total_flat + ,ord_a_item.ddln_pay_at,ord_a_item.ddln_pay_type + ,ord_a_item.is_paid,ord_a_item.paid_at,ord_a_item.paid_method,ord_a_item.paid_by + ,ord_a_item.is_bill_paid,ord_a_item.paid_bill_at,ord_a_item.paid_bill_method,ord_a_item.paid_bill_by + ,ord_a_item.bank_name,ord_a_item.bank_short_name,ord_a_item.bank_acc_number,ord_a_item.bank_acc_name + ,ord_a_item.invc_to_client + ,ord_a_item.img_proof_submission + ,ord_a_item.is_aprv,ord_a_item.rjct_at,ord_a_item.rjct_by,ord_a_item.rjct_bill_at,ord_a_item.rjct_bill_by + -- ,ord_a_item.is_merge_to,ord_a_item.merge_to_a_id,ord_a_item.merge_to_ord_id,ord_a_item.merge_to_ord_code,ord_a_item.merge_to_at + -- ,ord_a_item.is_merge_from,ord_a_item.merge_from_a_id,ord_a_item.merge_from_ord_id,ord_a_item.merge_from_ord_code,ord_a_item.merge_from_at + ,ord_a_item.stts_merge,ord_a_item.merge_to_code,ord_a_item.group_merge_code,ord_a_item.merge_at + ,ord_pck.pck_name,ord_pck.set_pck_at,ord_pck.pck_addr + -- ,(SELECT nmProvinsiKel FROM t_region WHERE kodeProv = ord_pck.pck_prid LIMIT 1) as pck_prid_name + -- ,(SELECT nmKotamadyaKel FROM t_region WHERE kodeKab = ord_pck.pck_ktid LIMIT 1) as pck_ktid_name + -- ,(SELECT nmKecamatanKel FROM t_region WHERE kodeKec = ord_pck.pck_kcid LIMIT 1) as pck_kcid_name + -- ,(SELECT nmKelurahan FROM t_region WHERE kodeKel = ord_pck.pck_klid LIMIT 1) as pck_klid_name + ,ord_drop.drop_name,ord_drop.drop_addr,ord_drop.chk_at as drop_chk_at + -- ,(SELECT nmProvinsiKel FROM t_region WHERE kodeProv = ord_drop.drop_prid LIMIT 1) as drop_prid_name + -- ,(SELECT nmKotamadyaKel FROM t_region WHERE kodeKab = ord_drop.drop_ktid LIMIT 1) as drop_ktid_name + -- ,(SELECT nmKecamatanKel FROM t_region WHERE kodeKec = ord_drop.drop_kcid LIMIT 1) as drop_kcid_name + -- ,(SELECT nmKelurahan FROM t_region WHERE kodeKel = ord_drop.drop_klid LIMIT 1) as drop_klid_name + ,ord_c.c_name,ord_c.c_pt_name + " . $select_order . " + FROM t_orders_a_items as ord_a_item + INNER JOIN t_orders as ord ON ord_a_item.ord_id = ord.id + INNER JOIN t_orders_clients as ord_c ON ord.id = ord_c.ord_id + INNER JOIN t_orders_pickups as ord_pck ON ord.id = ord_pck.ord_id + INNER JOIN t_orders_drops as ord_drop ON ord.id = ord_drop.ord_id + " . $join_join . " + WHERE ord.dlt is null + AND ord_a_item.dlt is null + AND ord.is_active = " . Orders::IS_ACTIVE_YES . " + AND ord_a_item.is_active = " . OrdersAItems::IS_ACTIVE_YES . " + " . $where_where . " + AND ord_a_item.only_client = ? + AND ord_a_item.calc_to_vdr = ? + AND ord_a_item.is_hidden = ? + AND ord_a_item.stts_merge IN (?,?) + " . $group_by . " + ;", + $params + ); + } + + public static function listAdtItemsBillings($filter = []) + { + $params = []; + $select_order = ''; + $join_join = ''; + $where_where = ''; + $group_by = ''; + + if (isset($filter['ord_id'])) { + $where_where .= ' AND ord.id = ?'; + $params[] = $filter['ord_id']; + } + + if (isset($filter['is_bill_aprv'])) { + $where_where .= ' AND ord_a_item.is_bill_aprv = ?'; + $params[] = $filter['is_bill_aprv']; + } + + $params[] = OrdersAItems::ONLY_VDR_NO; + $params[] = OrdersAItems::INVC_TO_CLIENT_YES; + $params[] = OrdersAItems::IS_HIDDEN_NO; + $params[] = OrdersAItems::STTS_MERGE_NO; + $params[] = OrdersAItems::STTS_MERGE_RESULT; + + if (isset($filter['group_by'])) { + $group_by .= ' GROUP BY ' . $filter['group_by']; + } + + return DB::select( + "SELECT + ord_a_item.id as ord_a_item_id,ord_a_item.v_termin_id,ord_a_item.ord_id,ord_a_item.ord_code + ,ord_a_item.desc,ord_a_item.a_item_type,ord_a_item.crt_type as a_item_crt_type + ,ord_a_item.unit_type,ut.name as unit_type_name,ord_a_item.unit_qty + ,ord_a_item.amt_bill_base_flat,ord_a_item.unit_qty,ord_a_item.amt_bill_total_flat + ,ord_a_item.is_paid,ord_a_item.paid_at,ord_a_item.paid_method,ord_a_item.paid_by + ,ord_a_item.is_bill_paid,ord_a_item.paid_bill_at,ord_a_item.paid_bill_method,ord_a_item.paid_bill_by + ,ord_termin.id as c_group_termin_id,ord_termin.termin_is_paid,ord_termin.termin_paid_at + ,ord_termin.sequence as termin_sequence,ord_termin.termin_ddln_type + ,ord_termin.termin_tax_type,ord_termin.termin_tax_ppn_percent,ord_termin.termin_tax_ppn_flat,ord_termin.termin_tax_pph_percent,ord_termin.termin_tax_pph_flat + ,ord_termin.amt_bill_confirm,ord_termin.amt_bill_confirm_note + ,ord_invc.id as invc_id,ord_invc.code as invc_code + ,ord_invc.amt_disc_type as invc_disc_type,ord_invc.amt_disc_percent as invc_disc_percent,ord_invc.amt_disc_flat as invc_disc_flat + ,ord_invc.is_gnrt_invc + ,ord_a_item.is_aprv,ord_a_item.rjct_at,ord_a_item.rjct_by,ord_a_item.rjct_bill_at,ord_a_item.rjct_bill_by + ,ord_a_item.stts_merge,ord_a_item.merge_to_code,ord_a_item.group_merge_code,ord_a_item.merge_at + ,ord_pck.pck_name,ord_pck.set_pck_at,ord_pck.pck_addr + -- ,(SELECT nmProvinsiKel FROM t_region WHERE kodeProv = ord_pck.pck_prid LIMIT 1) as pck_prid_name + -- ,(SELECT nmKotamadyaKel FROM t_region WHERE kodeKab = ord_pck.pck_ktid LIMIT 1) as pck_ktid_name + -- ,(SELECT nmKecamatanKel FROM t_region WHERE kodeKec = ord_pck.pck_kcid LIMIT 1) as pck_kcid_name + -- ,(SELECT nmKelurahan FROM t_region WHERE kodeKel = ord_pck.pck_klid LIMIT 1) as pck_klid_name + ,ord_drop.drop_name,ord_drop.drop_addr,ord_drop.chk_at as drop_chk_at + -- ,(SELECT nmProvinsiKel FROM t_region WHERE kodeProv = ord_drop.drop_prid LIMIT 1) as drop_prid_name + -- ,(SELECT nmKotamadyaKel FROM t_region WHERE kodeKab = ord_drop.drop_ktid LIMIT 1) as drop_ktid_name + -- ,(SELECT nmKecamatanKel FROM t_region WHERE kodeKec = ord_drop.drop_kcid LIMIT 1) as drop_kcid_name + -- ,(SELECT nmKelurahan FROM t_region WHERE kodeKel = ord_drop.drop_klid LIMIT 1) as drop_klid_name + ,ord_c.c_id,ord_c.c_name,ord_c.c_pt_id,ord_c.c_pt_name + " . $select_order . " + FROM t_orders_a_items as ord_a_item + INNER JOIN t_orders as ord ON ord_a_item.ord_id = ord.id + INNER JOIN t_orders_clients as ord_c ON ord.id = ord_c.ord_id + INNER JOIN t_orders_pickups as ord_pck ON ord.id = ord_pck.ord_id + INNER JOIN t_orders_drops as ord_drop ON ord.id = ord_drop.ord_id + INNER JOIN t_orders_termins as ord_termin ON ord_a_item.c_termin_id = ord_termin.id + LEFT JOIN t_orders_invoices as ord_invc ON ord_termin.id = ord_invc.c_termin_id + LEFT JOIN t_unit_types as ut ON ord_a_item.unit_type = ut.id + " . $join_join . " + WHERE ord.dlt is null + AND ord_a_item.dlt is null + AND ord.is_active = " . Orders::IS_ACTIVE_YES . " + AND ord_a_item.is_active = " . OrdersAItems::IS_ACTIVE_YES . " + " . $where_where . " + AND only_vdr = ? + AND invc_to_client = ? + AND ord_a_item.is_hidden = ? + AND ord_a_item.stts_merge IN (?,?) + " . $group_by . " + ;", + $params + ); + } + + public static function listLedgerBl($filter = []) + { + $params = [ + OrdersAItems::IS_ACTIVE_YES, OrdersAItems::ONLY_VDR_NO, OrdersAItems::INVC_TO_CLIENT_YES, OrdersAItems::IS_APRV_YES, OrdersAItems::IS_PAID_YES, OrdersAItems::STTS_MERGE_NO, OrdersAItems::STTS_MERGE_RESULT, + OrdersAItems::IS_ACTIVE_YES, OrdersAItems::ONLY_CLIENT_NO, OrdersAItems::CALC_TO_VDR_YES, OrdersAItems::IS_APRV_YES, OrdersAItems::IS_PAID_YES, OrdersAItems::STTS_MERGE_NO, OrdersAItems::STTS_MERGE_RESULT, + ]; + $select_order = ''; + $join_join = ''; + $where_where = ''; + $group_by = ''; + + if (isset($filter['ord_id'])) { + $where_where .= ' AND ord.id = ?'; + $params[] = $filter['ord_id']; + } + + if (isset($filter['with_items'])) { + $select_order .= " + ,ord_a_item.id as ord_a_item_id + ,ord_a_item.a_item_type,ord_a_item.desc as item_desc,ord_a_item.unit_type,unit_type.name as unit_type_name,ord_a_item.unit_qty + ,ord_a_item.amt_base_flat,ord_a_item.amt_result_flat,ord_a_item.amt_total_flat + ,ord_a_item.amt_bill_base_flat,ord_a_item.amt_bill_result_flat,ord_a_item.amt_bill_total_flat + ,ord_a_item.is_paid,ord_a_item.paid_at,ord_a_item.is_bill_paid,ord_a_item.paid_bill_at + ,ord_a_item.invc_to_client,ord_a_item.calc_to_vdr,ord_a_item.is_adm_price,ord_a_item.only_client,ord_a_item.only_vdr,ord_a_item.is_hidden,ord_a_item.is_tax,ord_a_item.is_disc + ,ord_a_item.is_aprv,ord_a_item.is_bill_aprv + "; + $join_join .= " + INNER JOIN t_orders_a_items as ord_a_item ON ord.id = ord_a_item.ord_id + LEFT JOIN t_unit_types as unit_type ON ord_a_item.unit_type = unit_type.id + "; + // perlu diperbaiki cara if di query, jika kalkulasi ke vendor maka is_aprv = , jika ke client is_bill_aprv = 1 + $where_where .= ' AND ord_a_item.dlt is null AND (ord_a_item.calc_to_vdr = ' . OrdersAItems::CALC_TO_VDR_YES . ' OR ord_a_item.invc_to_client = ' . OrdersAItems::INVC_TO_CLIENT_YES . ') AND (ord_a_item.is_aprv = ' . OrdersAItems::IS_APRV_YES . ' OR ord_a_item.is_bill_aprv = ' . OrdersAItems::IS_APRV_YES . ')'; + } + + if (isset($filter['start_date']) && isset($filter['end_date'])) { + $where_where .= ' AND ord.crt BETWEEN ? AND ?'; + $params[] = $filter['start_date']; + $params[] = $filter['end_date']; + } + + if (isset($filter['group_by'])) { + $group_by .= ' GROUP BY ' . $filter['group_by']; + } + + return DB::select( + "SELECT + ord.id as ord_id,ord.code as ord_code,ord.status as ord_status + ,@total_in:=(SELECT SUM(amt_bill_total_flat) FROM t_orders_a_items WHERE dlt is null AND is_active = ? AND only_vdr = ? AND invc_to_client = ? AND is_bill_aprv = ? AND is_bill_paid = ? AND stts_merge IN (?,?) AND ord_id = ord.id) as total_in + ,@total_out:=(SELECT SUM(amt_total_flat) FROM t_orders_a_items WHERE dlt is null AND is_active = ? AND only_client = ? AND calc_to_vdr = ? AND is_aprv = ? AND is_paid = ? AND stts_merge IN (?,?) AND ord_id = ord.id) as total_out + ,(IFNULL(@total_in, 0) - IFNULL(@total_out, 0)) as total_bl + ,ord_pck.pck_name,ord_pck.set_pck_at,ord_pck.pck_addr + ,(SELECT nmProvinsiKel FROM t_region WHERE kodeProv = ord_pck.pck_prid LIMIT 1) as pck_prid_name + ,(SELECT nmKotamadyaKel FROM t_region WHERE kodeKab = ord_pck.pck_ktid LIMIT 1) as pck_ktid_name + -- ,(SELECT nmKecamatanKel FROM t_region WHERE kodeKec = ord_pck.pck_kcid LIMIT 1) as pck_kcid_name + -- ,(SELECT nmKelurahan FROM t_region WHERE kodeKel = ord_pck.pck_klid LIMIT 1) as pck_klid_name + ,ord_drop.drop_name,ord_drop.drop_addr + ,(SELECT nmProvinsiKel FROM t_region WHERE kodeProv = ord_drop.drop_prid LIMIT 1) as drop_prid_name + ,(SELECT nmKotamadyaKel FROM t_region WHERE kodeKab = ord_drop.drop_ktid LIMIT 1) as drop_ktid_name + -- ,(SELECT nmKecamatanKel FROM t_region WHERE kodeKec = ord_drop.drop_kcid LIMIT 1) as drop_kcid_name + -- ,(SELECT nmKelurahan FROM t_region WHERE kodeKel = ord_drop.drop_klid LIMIT 1) as drop_klid_name + ,ord_c.c_name,ord_c.c_pt_name + ,ord_vdr.vdr_name,ord_vdr.vdr_pt_name + " . $select_order . " + FROM t_orders as ord + INNER JOIN t_orders_clients as ord_c ON ord.id = ord_c.ord_id + INNER JOIN t_orders_pickups as ord_pck ON ord.id = ord_pck.ord_id + INNER JOIN t_orders_drops as ord_drop ON ord.id = ord_drop.ord_id + INNER JOIN t_orders_vendors as ord_vdr ON ord.id = ord_vdr.ord_id + " . $join_join . " + WHERE ord.dlt is null + AND ord.is_active = " . Orders::IS_ACTIVE_YES . " + " . $where_where . " + " . $group_by . " + ;", + $params + ); + } + + public static function summaryLedgerBl($filter = []) + { + $params = []; + $select_order = ''; + $join_join = ''; + $where_where = ''; + // for sum + $join_sum = ''; + $where_sum = ''; + $params_sum_totin = [OrdersAItems::IS_ACTIVE_YES, OrdersAItems::ONLY_VDR_NO, OrdersAItems::INVC_TO_CLIENT_YES, OrdersAItems::IS_APRV_YES, OrdersAItems::IS_PAID_YES, OrdersAItems::STTS_MERGE_NO, OrdersAItems::STTS_MERGE_RESULT]; + $params_sum_totout = [OrdersAItems::IS_ACTIVE_YES, OrdersAItems::ONLY_CLIENT_NO, OrdersAItems::CALC_TO_VDR_YES, OrdersAItems::IS_APRV_YES, OrdersAItems::IS_PAID_YES, OrdersAItems::STTS_MERGE_NO, OrdersAItems::STTS_MERGE_RESULT]; + + if (isset($filter['start_date']) && isset($filter['end_date'])) { + $join_sum .= ' INNER JOIN t_orders as o ON a.ord_id = o.id'; + $where_sum .= ' AND o.crt BETWEEN ? AND ?'; + array_push($params_sum_totin, $filter['start_date'], $filter['end_date']); + array_push($params_sum_totout, $filter['start_date'], $filter['end_date']); + } + + // php spread operator was invented on 7.2 + $params_real = array_merge($params_sum_totin, $params_sum_totout, $params); + + return DB::select( + "SELECT + @total_in:=(SELECT SUM(amt_bill_total_flat) FROM t_orders_a_items as a $join_sum WHERE a.dlt is null AND a.is_active = ? AND a.only_vdr = ? AND a.invc_to_client = ? AND a.is_bill_aprv = ? AND a.is_bill_paid = ? AND a.stts_merge IN (?,?) $where_sum) as total_in + ,@total_out:=(SELECT SUM(amt_total_flat) FROM t_orders_a_items as a $join_sum WHERE a.dlt is null AND a.is_active = ? AND a.only_client = ? AND a.calc_to_vdr = ? AND a.is_aprv = ? AND a.is_paid = ? AND a.stts_merge IN (?,?) $where_sum) as total_out + ,(IFNULL(@total_in, 0) - IFNULL(@total_out, 0)) as total_bl + " . $select_order . " + FROM t_orders_a_items as ord_a + " . $join_join . " + WHERE ord_a.dlt is null + AND ord_a.is_active = " . OrdersAItems::IS_ACTIVE_YES . " + " . $where_where . " + LIMIT 1 + ;", + $params_real + ); + } + + /** + * Baru saja pembayaran dilunaskan baik dari client / vendor + * false => error + * 0 => not paid, 1 => just paid off, 2 => paid off + */ + public static function checkJustPaidOff($ord_id) + { + $order = Orders::showOrder(['id' => $ord_id]); + if (count($order) < 1 || $order === false) return false; + $out = [ + 'invc_paid' => 0, + 'vdr_paid' => 0, + 'invc_vdr_paid' => 0, + ]; + $currentBill = Finance::listBillings(['ord_id' => $ord_id]); + $currentPay = Finance::listPayments(['ord_id' => $ord_id]); + // paid off + if ($currentBill[0]->total_billing === $currentBill[0]->total_payed || $currentPay[0]->total_payment === $currentPay[0]->total_payed) { + if ($currentBill[0]->total_billing === $currentBill[0]->total_payed) { + // just paid off + if ($order[0]->is_invc_paid !== Orders::IS_PAID_YES) { + $out['invc_paid'] = 1; + } else { + $out['invc_paid'] = 2; + } + } + if ($currentPay[0]->total_payment === $currentPay[0]->total_payed) { + // just paid off + if ($order[0]->is_vdr_paid !== Orders::IS_PAID_YES) { + $out['vdr_paid'] = 1; + } else { + $out['vdr_paid'] = 2; + } + } + if ($currentBill[0]->total_billing === $currentBill[0]->total_payed && $currentPay[0]->total_payment === $currentPay[0]->total_payed) { + // just paid off + if ($out['invc_paid'] === 1 || $out['vdr_paid'] === 1) { + $out['invc_vdr_paid'] = 1; + } else { + $out['invc_vdr_paid'] = 2; + } + } + } + return $out; + } + + public static function updtChangeInvc($c_termin_id) + { + $ord_invc = OrdersInvoices::getByTerminId($c_termin_id); + if ($ord_invc !== false && count($ord_invc) > 0) { + OrdersInvoices::updt($ord_invc[0]->id, [ + 'is_gnrt_invc' => OrdersInvoices::IS_GNRT_INVC_NO, + ]); + return true; + } + return false; + } + + public static function availOrdToMerge($filter = []) + { + $params = []; + $select = ''; + $join = ''; + $where = ''; + $group_by = ''; + + $where .= ' AND ord.stts_merge IN (?,?)'; + $params[] = OrdersAItems::STTS_MERGE_NO; + $params[] = OrdersAItems::STTS_MERGE_RESULT; + + if (isset($filter['except_ord_id'])) { + $where .= ' AND ord.id = ?'; + $params[] = $filter['except_ord_id']; + } + + return DB::select( + "SELECT + ord.* + " . $select . " + FROM t_orders as ord + " . $join . " + WHERE ord.dlt is null + AND ord.stts_merge = " . Orders::STTS_MERGE_NO . " + " . $where . " + ORDER BY ord.id DESC + " . $group_by . " + LIMIT 100 + ;", + $params + ); + } +} diff --git a/app/Models/Insurances.php b/app/Models/Insurances.php new file mode 100755 index 0000000..0cea638 --- /dev/null +++ b/app/Models/Insurances.php @@ -0,0 +1,65 @@ += ? AND premi_max_price <= ?) OR (premi_min_price <= ? AND premi_max_price >= ?)) ORDER BY premi_price DESC;", [$price, $price, $price, $price]); + } + + public static function addInsurance($data) + { + $iid = DB::table("t_insurances")->insertGetId($data); + return $iid; + } + + public static function updateInsurance($iid, $data) + { + return DB::table("t_insurances")->where("id", $iid)->update($data); + } + + public static function deleteInsurance($iid) + { + return DB::table("t_insurances")->where("id", $iid)->delete(); + } +} diff --git a/app/Models/LogbookKeys.php b/app/Models/LogbookKeys.php new file mode 100755 index 0000000..4be5f50 --- /dev/null +++ b/app/Models/LogbookKeys.php @@ -0,0 +1,106 @@ +insertGetId($data); + return $lgb_key_id; + } + + public static function updateLgbKey($lgb_key_id, $data) + { + return DB::table("t_lgb_keys")->where("id", $lgb_key_id)->update($data); + } + + public static function deleteLgbKey($lgb_key_id) + { + return DB::table("t_lgb_keys")->where("id", $lgb_key_id)->delete(); + } +} diff --git a/app/Models/LogbookTypes.php b/app/Models/LogbookTypes.php new file mode 100755 index 0000000..e20258e --- /dev/null +++ b/app/Models/LogbookTypes.php @@ -0,0 +1,107 @@ +insertGetId($data); + return $lgb_type_id; + } + + public static function updateLgbType($lgb_type_id, $data) + { + return DB::table("t_lgb_types")->where("id", $lgb_type_id)->update($data); + } + + public static function deleteLgbType($lgb_type_id) + { + return DB::table("t_lgb_types")->where("id", $lgb_type_id)->delete(); + } +} diff --git a/app/Models/Orders.php b/app/Models/Orders.php new file mode 100755 index 0000000..1a68ae4 --- /dev/null +++ b/app/Models/Orders.php @@ -0,0 +1,635 @@ + $v) { + $binds_codes .= "?,"; + $params[] = $v; + } + if (substr($binds_codes, -1) === ",") { + $binds_codes = substr($binds_codes, 0, -1); + } + $where_order .= " AND ord.code IN ($binds_codes)"; + } elseif (isset($filter["group_merge_code"])) { + $where_order .= " AND ord.group_merge_code IN (?)"; + $params[] = $filter["group_merge_code"]; + } else { + return false; + } + + if (isset($filter["center_pck"])) { + $select_order .= ",ST_AsText(ST_Centroid(pck_points)) as pck_center"; + } + + if (isset($filter["get_prefer_type_truck"])) { + $select_order .= ",tt.name as prefer_truck_type_name"; + $join_order .= " LEFT JOIN t_vehicles_types as tt ON ord_c.prefer_truck_type = tt.id"; + } + + if (isset($filter["get_additional_vehicles_info"])) { + $select_order .= + ",ord_vhc.vhc_type_id, tt2.name as vhc_type_name, ord_vhc.vhc_brand_id, tb.name as vhc_brand_name"; + $join_order .= " LEFT JOIN t_vehicles_types as tt2 ON ord_vhc.vhc_type_id = tt2.id"; + $join_order .= " LEFT JOIN t_vehicles_brands as tb ON ord_vhc.vhc_brand_id = tb.id"; + } + + if (isset($filter["get_zone_data"])) { + $select_order .= + ",ord_pck.pck_hex_color,ord_pck.pck_shape,ord_pck.pck_radius,ord_pck.pck_bounds,ord_pck.pck_latlngs,ST_AsText(ST_Centroid(pck_points)) as pck_center"; + $select_order .= + ",ord_drop.drop_hex_color,ord_drop.drop_shape,ord_drop.drop_radius,ord_drop.drop_bounds,ord_drop.drop_latlngs,ST_AsText(ST_Centroid(drop_points)) as drop_center"; + } + + if (isset($filter["get_zone_zonasi"])) { + $select_order .= + ",(SELECT nmProvinsiKel FROM t_region WHERE kodeProv = ord_pck.pck_prid LIMIT 1) as pck_prid_name ,(SELECT nmKotamadyaKel FROM t_region WHERE kodeKab = ord_pck.pck_ktid LIMIT 1) as pck_ktid_name"; + $select_order .= + ",(SELECT nmProvinsiKel FROM t_region WHERE kodeProv = ord_drop.drop_prid LIMIT 1) as drop_prid_name ,(SELECT nmKotamadyaKel FROM t_region WHERE kodeKab = ord_drop.drop_ktid LIMIT 1) as drop_ktid_name"; + } + + if (isset($filter["get_pic_zone"])) { + $select_order .= + ",ord_pck.pic_name as pck_pic_name,ord_pck.pic_phone_code as pck_pic_phone_code,ord_pck.pic_phone_val as pck_pic_phone_val,ord_pck.pic_mail as pck_pic_mail"; + $select_order .= + ",ord_drop.pic_name as drop_pic_name,ord_drop.pic_phone_code as drop_pic_phone_code,ord_drop.pic_phone_val as drop_pic_phone_val,ord_drop.pic_mail as drop_pic_mail"; + } + if (isset($filter["get_client_pt"])) { + $select_order .= + ",ord_c.c_pt_id,ord_c.c_pt_name,ord_c.c_pt_phone_code,ord_c.c_pt_phone_val,ord_c.c_pt_mail,ord_c.c_pt_addr"; + $select_order .= + ",ord_c.c_pt_pic_name,ord_c.c_pt_pic_phone_code,ord_c.c_pt_pic_phone_val,ord_c.c_pt_pic_mail,ord_c.c_pt_pic_addr"; + } + + if (isset($filter["get_exp_vendor"])) { + $select_order .= ",ord_vdr.is_exp as vdr_is_exp,ord_vdr.exp_at as vdr_exp_at"; + } + if (isset($filter["vdr_id"])) { + $select_order .= ",ord_vdr.find_vhcs"; + $where_order .= " AND ord_vdr.vdr_id = ?"; + array_push($params, $filter["vdr_id"]); + $join_order .= " LEFT JOIN t_orders_vendors as ord_vdr ON ord.id = ord_vdr.ord_id"; + } else { + $join_order .= + " + LEFT JOIN ( SELECT MIN(respond_at) as respond_at,ord_id,vdr_id FROM t_orders_vendors WHERE status = " . + OrdersVendors::STTS_ACC . + " GROUP BY ord_id ) AS ord_vdr1 ON (ord.id = ord_vdr1.ord_id) + LEFT JOIN t_orders_vendors as ord_vdr ON ( ord_vdr.respond_at = ord_vdr1.respond_at) + "; + } + + if (isset($filter["get_drv_bank"])) { + $select_order .= + ",ord_drv.drv_bank_id,ord_drv.drv_bank_code,ord_drv.drv_bank_name,ord_drv.drv_bank_short_name,ord_drv.drv_bank_branch_name,ord_drv.drv_bank_acc_number,ord_drv.drv_bank_acc_name"; + } + if (isset($filter["get_vdr_bank"])) { + $select_order .= + ",ord_vdr.vdr_bank_id,ord_vdr.vdr_bank_code,ord_vdr.vdr_bank_name,ord_vdr.vdr_bank_short_name,ord_vdr.vdr_bank_acc_number,ord_vdr.vdr_bank_acc_name"; + } + + if (isset($filter["get_stts_checker"])) { + $select_order .= + " ,ord_pck.chk_id as pck_chk_id,ord_pck.chk_at as pck_chk_at,ord_pck.chk_stts as pck_chk_stts"; + $select_order .= + " ,ord_drop.chk_id as drop_chk_id,ord_drop.chk_at as drop_chk_at,ord_drop.chk_stts as drop_chk_stts"; + } + if (isset($filter["chk_id"])) { + if ($filter["chk_type"] == Users::CHK_TYPE_PICKUP) { + $where_order .= " AND (ord_pck.chk_id = ? OR ord_pck.chk_id = 0) "; + array_push($params, $filter["chk_id"]); + } elseif ($filter["chk_type"] == Users::CHK_TYPE_DROP) { + $where_order .= " AND (ord_drop.chk_id = ? OR ord_drop.chk_id = 0) "; + array_push($params, $filter["chk_id"]); + } + } + if (isset($filter["get_checker_user"])) { + $select_order .= + " ,ord_pck.chk_name as pck_chk_name,ord_pck.chk_mail as pck_chk_mail,ord_pck.chk_phone_val as pck_chk_phone_val"; + $select_order .= + " ,ord_drop.chk_name as drop_chk_name,ord_drop.chk_mail as drop_chk_mail,ord_drop.chk_phone_val as drop_chk_phone_val"; + } + + if (isset($filter["get_bid_info"])) { + $select_order .= + " ,ord_vdr.is_mailing_bid,ord_vdr.is_mailing_bid_at,ord_vdr.is_want,ord_vdr.is_want_at"; + } + + // get img pickup and drop + if (isset($filter["get_checker_data"])) { + $select_order .= + " ,ord_pck.chk_seal_number as ord_pck_seal_number,ord_pck.chk_seal_img as ord_pck_seal_img,ord_pck.chk_drv_armd_img as ord_pck_drv_armd_img,ord_pck.chk_nopol_img as ord_pck_nopol_img,ord_pck.chk_docs_client_img as ord_pck_docs_client_img,ord_pck.chk_seal_install_img as ord_pck_seal_install_img,ord_pck.chk_goods_img as ord_pck_goods_img"; + $select_order .= + " ,ord_drop.chk_arrived_img as ord_drop_arrived_img,ord_drop.chk_handover_img as ord_drop_handover_img,ord_drop.chk_do_ttd_img as ord_drop_do_ttd_img,ord_drop.chk_spk_img as ord_drop_spk_img"; + } + + if (isset($filter["get_accidents"])) { + $select_order .= + ",ord_acdnt.id as ord_acdnt_id,ord_acdnt.accident_location as ord_acdnt_location,ord_acdnt.accident_story as ord_acdnt_story,ord_acdnt.accident_imgs as ord_acdnt_imgs"; + $select_order .= + ",ord_acdnt.new_nopol1 as ord_acdnt_new_nopol1,ord_acdnt.new_nopol2 as ord_acdnt_new_nopol2,ord_acdnt.new_nopol3 as ord_acdnt_new_nopol3,ord_acdnt.new_vhc_type_id as ord_acdnt_new_vhc_type_id"; + $select_order .= ",tt3.name as ord_acdnt_new_vhc_type_name"; + $select_order .= + ",ord_acdnt.new_drv_name as ord_acdnt_new_drv_name,ord_acdnt.new_drv_phone_code as ord_acdnt_new_drv_phone_code,ord_acdnt.new_drv_phone_val as ord_acdnt_new_drv_phone_val"; + $select_order .= ",ord_acdnt.crt as ord_acdnt_crt_at,ord_acdnt.updt as ord_acdnt_updt_at"; + $join_order .= " LEFT JOIN t_orders_accidents as ord_acdnt ON ord.id = ord_acdnt.ord_id"; + $join_order .= " LEFT JOIN t_vehicles_types as tt3 ON ord_vhc.vhc_type_id = tt3.id"; + } + + if (isset($filter["select_region_pck_drop"])) { + $select_order .= + ",(SELECT nmKotamadyaKel FROM t_region WHERE kodeKab = ord_pck.pck_ktid LIMIT 1) pck_ktname, (SELECT nmKotamadyaKel FROM t_region WHERE kodeKab = ord_drop.drop_ktid LIMIT 1) drop_ktname"; + } + + if (isset($filter["couple_pck_drop"])) { + $select_order .= + " ,ord_pck_drop.id as ord_pck_drop_id,ord_pck_drop.stts as stts_delivery,ord_pck_drop.is_aprv_pck,ord_pck_drop.aprv_pck_at"; + $join_order .= " INNER JOIN t_orders_pck_drop as ord_pck_drop ON ord.id = ord_pck_drop.ord_id"; + $join_order .= " INNER JOIN t_orders_pickups as ord_pck ON ord_pck_drop.pck_id = ord_pck.id"; + $join_order .= " INNER JOIN t_orders_drops as ord_drop ON ord_pck_drop.drop_id = ord_drop.id"; + + if (isset($filter["ord_pck_drop_id"])) { + $where_order .= " AND ord_pck_drop.id = ?"; + array_push($params, $filter["ord_pck_drop_id"]); + } + if (isset($filter["get_user_aprv_pck"])) { + $select_order .= + " ,(SELECT first_name FROM t_users WHERE id = ord_pck_drop.aprv_pck_by LIMIT 1) as aprv_pck_by_name"; + } + } else { + $join_order .= " INNER JOIN t_orders_pickups as ord_pck ON ord.id = ord_pck.ord_id"; + $join_order .= " INNER JOIN t_orders_drops as ord_drop ON ord.id = ord_drop.ord_id"; + } + + if (isset($filter["join_pockets"])) { + $select_order .= + " ,ord_pocket.pocket_id,ord_pocket.pocket_type,ord_pocket.id as ord_pocket_id,ord_pocket.pocket_name"; + $join_order .= " INNER JOIN t_orders_pockets as ord_pocket ON ord.id = ord_pocket.ord_id"; + } + + if (isset($filter["group_by"])) { + $group_by .= " GROUP BY " . $filter["group_by"]; + } + + if (!isset($filter["limit"])) { + $filter["limit"] = 1; + } + + return DB::select( + "SELECT + " . + Orders::defaultSelectedOrdersDetail . + " + " . + $select_order . + " + FROM t_orders as ord + INNER JOIN t_orders_clients as ord_c ON ord.id = ord_c.ord_id + LEFT JOIN t_orders_rates as ord_rate ON ord.id = ord_rate.ord_id + LEFT JOIN t_orders_drivers as ord_drv ON ord.id = ord_drv.ord_id + LEFT JOIN t_orders_vehicles as ord_vhc ON ord.id = ord_vhc.ord_id + " . + $join_order . + " + " . + Orders::defaultWhereOrdersDetail . + " + " . + $where_order . + " + " . + $group_by . + " + LIMIT " . + $filter["limit"] . + ";", + $params, + ); + } + + public static function getOrders() + { + return DB::select("SELECT * FROM t_orders WHERE dlt is null;"); + } + + public static function getOrdersClientActive($client_id) + { + $stts = + Orders::STTS_WAIT . + "," . + Orders::STTS_CONFIRM . + "," . + Orders::STTS_HAVE_GET_VHC . + "," . + Orders::STTS_PCK . + "," . + Orders::STTS_GO . + "," . + Orders::STTS_ARV . + "," . + Orders::STTS_DROP; + return DB::select( + "SELECT + ord.*,ord_c.* + ,ord_c.pay_at as client_pay_at,ord_c.is_pay as client_is_pay + FROM t_orders as ord + INNER JOIN t_orders_clients as ord_c ON ord.id = ord_c.ord_id + WHERE ord.dlt is null AND ord.status IN (?) AND ord_c.c_id = ?;", + [$stts, $client_id], + ); + } + + public static function getOrdersByClient($client_id, $limit = 1000) + { + return DB::select( + "SELECT + ord.*,ord_c.* + ,ord_c.pay_at as client_pay_at,ord_c.is_pay as client_is_pay + FROM t_orders as ord + INNER JOIN t_orders_clients as ord_c ON ord.id = ord_c.ord_id + WHERE ord.dlt is null AND ord_c.c_id = ? + LIMIT ?;", + [$client_id, $limit], + ); + } + + public static function getOrderById($ordid) + { + return DB::select("SELECT * FROM t_orders WHERE dlt is null AND id = ? LIMIT 1;", [$ordid]); + } + + public static function getOrderByCode($ordcode) + { + return DB::select("SELECT * FROM t_orders WHERE dlt is null AND code = ? LIMIT 1;", [$ordcode]); + } + + // special case utk generate order code tanpa where dlt is null + public static function getOrderLikeCode($ordcode) + { + // return DB::select("SELECT COUNT(id) as total FROM t_orders WHERE dlt is null AND code LIKE ? LIMIT 1;", [$ordcode.'%']); + return DB::select("SELECT COUNT(id) as total FROM t_orders WHERE code LIKE ? LIMIT 1;", [ + $ordcode . "%", + ]); + } + + public static function getPoints($filter) + { + $params = []; + $select = ""; + $join = ""; + $where = ""; + $limit = ""; + + if (isset($filter["id"])) { + $where .= " AND ord.id = ? "; + array_push($params, $filter["id"]); + } elseif (isset($filter["code"])) { + $where .= " AND ord.code = ? "; + array_push($params, $filter["code"]); + } else { + return false; + } + + if (isset($filter["point_id"])) { + $where .= " AND topd.id = ? "; + array_push($params, $filter["point_id"]); + } + + if (isset($filter["center_pck"])) { + $select .= ",ST_AsText(ST_Centroid(pck_points)) as pck_center"; + } + + if (isset($filter["get_zone_data"])) { + $select .= + ",ord_pck.pck_hex_color,ord_pck.pck_shape,ord_pck.pck_radius,ord_pck.pck_bounds,ord_pck.pck_latlngs,ST_AsText(ST_Centroid(pck_points)) as pck_center"; + $select .= + ",ord_drop.drop_hex_color,ord_drop.drop_shape,ord_drop.drop_radius,ord_drop.drop_bounds,ord_drop.drop_latlngs,ST_AsText(ST_Centroid(drop_points)) as drop_center"; + } + + if (isset($filter["get_pic_zone"])) { + $select .= + ",ord_pck.pic_name as pck_pic_name,ord_pck.pic_phone_code as pck_pic_phone_code,ord_pck.pic_phone_val as pck_pic_phone_val,ord_pck.pic_mail as pck_pic_mail"; + $select .= + ",ord_drop.pic_name as drop_pic_name,ord_drop.pic_phone_code as drop_pic_phone_code,ord_drop.pic_phone_val as drop_pic_phone_val,ord_drop.pic_mail as drop_pic_mail"; + } + + if (isset($filter["select_region_pck_drop"])) { + $select .= + ",(SELECT nmKotamadyaKel FROM t_region WHERE kodeKab = ord_pck.pck_ktid LIMIT 1) pck_ktname, (SELECT nmKotamadyaKel FROM t_region WHERE kodeKab = ord_drop.drop_ktid LIMIT 1) drop_ktname"; + } + + if (isset($filter["limit"])) { + $limit .= " LIMIT " . $filter["limit"]; + } + + // -- total_pck must be equal to total_drop + return DB::select( + "SELECT + ord.* + ,ord.id as ord_id,ord.code as ord_code + ,ord_pck.id as ord_pck_id,ord_pck.pck_id as ord_pck_zone_id,ord_pck.pck_name,ord_pck.pck_addr,ord_pck.set_pck_at,ord_pck.pck_at,ord_pck.pck_enter_at,ord_pck.pck_leave_at + ,ord_drop.id as ord_drop_id,ord_drop.drop_id as ord_drop_zone_id,ord_drop.drop_name,ord_drop.drop_addr,ord_drop.drop_at,ord_drop.drop_enter_at,ord_drop.drop_leave_at + ,topd.id as point_id + " . + $select . + " + FROM t_orders as ord + LEFT JOIN t_orders_pck_drop topd ON + topd.ord_id = ord.id + LEFT JOIN t_orders_pickups as ord_pck ON + topd.pck_id = ord_pck.id + LEFT JOIN t_orders_drops as ord_drop ON + topd.drop_id = ord_drop.id + " . + $join . + " + " . + Orders::defaultWhereOrdersDetail . + " + " . + $where . + " + " . + $limit . + " + ", + $params, + ); + } + + public static function addOrder($data) + { + $ordid = DB::table("t_orders")->insertGetId($data); + return $ordid; + } + + public static function updateOrder($ordid, $data) + { + return DB::table("t_orders") + ->where("id", $ordid) + ->update($data); + } + + public static function deleteOrder($ordid) + { + return DB::table("t_orders") + ->where("id", $ordid) + ->delete(); + } +} \ No newline at end of file diff --git a/app/Models/OrdersAItems.php b/app/Models/OrdersAItems.php new file mode 100755 index 0000000..574a659 --- /dev/null +++ b/app/Models/OrdersAItems.php @@ -0,0 +1,397 @@ +refer ddln_pay_at, 2=>refer to order finish(pengantaran selesai) + const DDLN_PAY_TYPE_TIME = 1; + const DDLN_PAY_TYPE_ORD_FINISH = 2; + + const IS_PAID_NO = 0; + const IS_PAID_YES = 1; + + const IS_HIDDEN_NO = 0; + const IS_HIDDEN_YES = 1; + + // tax yang berlaku utk 1 row saja + const IS_TAX_NO = 0; + const IS_TAX_YES = 1; + + const IS_DISC_NO = 0; + const IS_DISC_YES = 1; + + const IS_SUBTRACT_NO = 0; + const IS_SUBTRACT_YES = 1; + + // 1=>transfer + const PAID_TYPE_TF = 1; + + const INVC_TO_CLIENT_YES = 1; + const INVC_TO_CLIENT_NO = 2; + + const CALC_TO_VDR_YES = 1; + const CALC_TO_VDR_NO = 2; + + const ONLY_CLIENT_YES = 1; + const ONLY_CLIENT_NO = 2; + + const ONLY_VDR_YES = 1; + const ONLY_VDR_NO = 2; + + const IS_ADM_PRICE_NO = 0; + const IS_ADM_PRICE_YES = 1; + + const IS_APRV_NO = 0; + const IS_APRV_YES = 1; + + const IS_ACTIVE_NO = 0; + const IS_ACTIVE_YES = 1; + + // tax yang include dengan itemnya + const AMT_TAX_TYPE_WITHOUT = 0; // tanpa pajak + const AMT_TAX_TYPE_INCLUDE = 1; // termasuk pajak || pajak dibayarkan sendiri oleh (client/vendor) + const AMT_TAX_TYPE_EXCLUDE = 2; // belum termasuk pajak || pajak dibayarkan oleh bonceng + const PPN_PERCENT = 1.1; + const PPN_PERCENT_INCLUDE = 1.011; + const PPH_PERCENT = 2; + + // merge satuan + const IS_MERGE_NO = 0; + const IS_MERGE_YES = 1; + + // merge per trx + const STTS_MERGE_NO = 0; + const STTS_MERGE_TO = 1; + const STTS_MERGE_RESULT = 2; + + // 0=>system, 1=>admin, 2=>finance + const CRT_TYPE_SYSTEM = 0; + const CRT_TYPE_ADMIN = 1; + const CRT_TYPE_FINANCE = 2; + + /** + * termin_at itu deadline pembayaran + * column merge disini untuk merge satuan: + * is_merge_to, merge_to_a_id, merge_to_ord_id, merge_to_ord_code, merge_to_at, merge_to_by + * is_merge_from, merge_from_a_id, merge_from_ord_id, merge_from_ord_code, merge_from_at, merge_from_by + * column merge disini untuk merge per trx: + * stts_merge, merge_to_code, group_merge_code, merge_at + */ + + public static function listAItems($filter = []) + { + $params = []; + $select = ''; + $where = ''; + + if (isset($filter['c_termin_id'])) { + $where .= ' AND ord_a_item.c_termin_id = ?'; + $params[] = $filter['c_termin_id']; + } + + if (isset($filter['is_hidden'])) { + $where .= ' AND ord_a_item.is_hidden = ?'; + $params[] = $filter['is_hidden']; + } + + if (isset($filter['is_tax'])) { + $where .= ' AND ord_a_item.is_tax = ?'; + $params[] = $filter['is_tax']; + } + + if (isset($filter['is_ppn'])) { + $where .= ' AND ord_a_item.is_ppn = ?'; + $params[] = $filter['is_ppn']; + } + + if (isset($filter['is_pph'])) { + $where .= ' AND ord_a_item.is_pph = ?'; + $params[] = $filter['is_pph']; + } + + if (isset($filter['is_disc'])) { + $where .= ' AND ord_a_item.is_disc = ?'; + $params[] = $filter['is_disc']; + } + + return DB::select("SELECT + ord_a_item.id as ord_a_item_id + ,ord_a_item.* + $select + FROM + t_orders_a_items as ord_a_item + WHERE dlt is null + $where + ;", + $params); + } + + public static function get() + { + return DB::select("SELECT * FROM t_orders_a_items;"); + } + + public static function showAItem($filter = []) + { + $params = []; + $join = ''; + $select = ''; + $where = ''; + $group_by = ''; + $limit = ''; + + if (isset($filter['ord_a_item_id'])) { + $where .= ' AND ord_a_item.id = ?'; + $params[] = $filter['ord_a_item_id']; + } else if (isset($filter['group_merge_code'])) { + $where .= ' AND ord_a_item.group_merge_code IN (?)'; + $params[] = $filter['group_merge_code']; + } + + if (isset($filter['ord_id'])) { + $where .= ' AND ord_a_item.ord_id = ?'; + $params[] = $filter['ord_id']; + } + + if (isset($filter['exclude_ord_a_item_id'])) { + $where .= ' AND ord_a_item.id != ?'; + $params[] = $filter['exclude_ord_a_item_id']; + } + + if (isset($filter['is_adm_price'])) { + $where .= ' AND ord_a_item.is_adm_price = ?'; + $params[] = $filter['is_adm_price']; + } + if (isset($filter['is_active'])) { + $where .= ' AND ord_a_item.is_active = ?'; + $params[] = $filter['is_active']; + } + if (isset($filter['a_item_type'])) { + $where .= ' AND ord_a_item.a_item_type = ?'; + $params[] = $filter['a_item_type']; + } + if (isset($filter['v_termin_id_not_zero'])) { + $where .= ' AND ord_a_item.v_termin_id != 0'; + } + if (isset($filter['c_termin_id_not_zero'])) { + $where .= ' AND ord_a_item.c_termin_id != 0'; + } + + if (isset($filter['get_user_crt'])) { + $select .= ',ucrt.first_name as ucrt_name'; + $join .= ' LEFT JOIN t_users as ucrt ON ord_a_item.crt_by = ucrt.id'; + } + + if (isset($filter['get_user_rjct'])) { + $select .= ',urjct.first_name as urjct_name,urjct_bill.first_name as urjct_bill_name'; + $join .= ' LEFT JOIN t_users as urjct ON ord_a_item.rjct_by = urjct.id'; + $join .= ' LEFT JOIN t_users as urjct_bill ON ord_a_item.rjct_bill_by = urjct_bill.id'; + } + + if (isset($filter['prev_main_item_id'])) { + $where .= ' AND ord_a_item.id < ?'; + $params[] = $filter['prev_main_item_id']; + } + + if (isset($filter['limit'])) { + $limit .= ' LIMIT ?'; + $params[] = $filter['limit']; + } + + return DB::select("SELECT + ord_a_item.id as ord_a_item_id + ,ord_a_item.* + $select + FROM + t_orders_a_items as ord_a_item + $join + WHERE ord_a_item.dlt is null + $where + $group_by + $limit + ;", + $params); + } + + public static function showAItemById($ord_a_item_id, $filter = []) + { + $params = []; + $join = ''; + $select = ''; + $where = ''; + + if (isset($filter['is_adm_price'])) { + $where .= ' AND ord_a_item.is_adm_price = ?'; + $params[] = $filter['is_adm_price']; + } + + if (isset($filter['get_user_crt'])) { + $select .= ',ucrt.first_name as ucrt_name'; + $join .= ' LEFT JOIN t_users as ucrt ON ord_a_item.crt_by = ucrt.id'; + } + + if (isset($filter['get_user_rjct'])) { + $select .= ',urjct.first_name as urjct_name,urjct_bill.first_name as urjct_bill_name'; + $join .= ' LEFT JOIN t_users as urjct ON ord_a_item.rjct_by = urjct.id'; + $join .= ' LEFT JOIN t_users as urjct_bill ON ord_a_item.rjct_bill_by = urjct_bill.id'; + } + + $params[] = $ord_a_item_id; + + return DB::select("SELECT + ord_a_item.id as ord_a_item_id + ,ord_a_item.* + $select + FROM + t_orders_a_items as ord_a_item + $join + WHERE ord_a_item.dlt is null + $where + AND ord_a_item.id = ? + ;", + $params); + } + + public static function showAItemByIds($ids) + { + $params = []; + $select = ''; + $where = ''; + + if ($ids && count($ids) > 0) { + $binds_ids = ""; + foreach ($ids as $k => $v) { + $binds_ids .= "?,"; + $params[] = $v; + } + if (substr($binds_ids, -1) === ',') { + $binds_ids = substr($binds_ids, 0, -1); + } + $where .= " AND ord_a_item.id IN ($binds_ids)"; + } else { + $where .= " AND ord_a_item.id = ?"; + $params[] = 0; + } + + return DB::select("SELECT + ord_a_item.id as ord_a_item_id + ,ord_a_item.* + ,ut.name as unit_type_name + $select + FROM t_orders_a_items as ord_a_item + LEFT JOIN t_unit_types as ut ON ord_a_item.unit_type = ut.id + WHERE ord_a_item.dlt is null + $where + ;", + $params); + } + + // termin ids + public static function showAItemByVids($tids, $filter = []) + { + $params = []; + $select = ''; + $where = ''; + + if ($tids && count($tids) > 0) { + $binds_ids = ""; + foreach ($tids as $k => $v) { + $binds_ids .= "?,"; + $params[] = $v; + } + if (substr($binds_ids, -1) === ',') { + $binds_ids = substr($binds_ids, 0, -1); + } + if (isset($filter['c_termin_id'])) { + $where .= " AND ord_a_item.c_termin_id IN ($binds_ids)"; + } else { + $where .= " AND ord_a_item.v_termin_id IN ($binds_ids)"; + } + } else { + if (isset($filter['c_termin_id'])) { + $where .= " AND ord_a_item.c_termin_id = ?"; + } else { + $where .= " AND ord_a_item.v_termin_id = ?"; + } + $params[] = 0; + } + + if (isset($filter['a_item_type'])) { + $where .= " AND ord_a_item.a_item_type = ?"; + $params[] = $filter['a_item_type']; + } + + return DB::select("SELECT + ord_a_item.id as ord_a_item_id + ,ord_a_item.* + ,ut.name as unit_type_name + $select + FROM t_orders_a_items as ord_a_item + LEFT JOIN t_unit_types as ut ON ord_a_item.unit_type = ut.id + WHERE ord_a_item.dlt is null + $where + ;", + $params); + } + + public static function getById($id) + { + return DB::select("SELECT * FROM t_orders_a_items WHERE id = ? LIMIT 1;", [$id]); + } + + public static function getByOrdCode($code) + { + return DB::select("SELECT * FROM t_orders_a_items WHERE ord_code = ? LIMIT 1;", [$code]); + } + + public static function getByOrdId($ordid) + { + return DB::select("SELECT * FROM t_orders_a_items WHERE ord_id = ? LIMIT 1;", [$ordid]); + } + + public static function add($data) + { + $id = DB::table("t_orders_a_items")->insertGetId($data); + return $id; + } + + public static function updt($id, $data) + { + return DB::table("t_orders_a_items")->where("id", $id)->update($data); + } + + public static function updtByOrdId($ord_id, $data) + { + return DB::table("t_orders_a_items")->where("ord_id", $ord_id)->update($data); + } + + public static function dlt($id) + { + return DB::table("t_orders_a_items")->where("id", $id)->delete(); + } + + public static function dltByOrdId($ord_id) + { + return DB::table("t_orders_a_items")->where("ord_id", $ord_id)->delete(); + } +} diff --git a/app/Models/OrdersAccidents.php b/app/Models/OrdersAccidents.php new file mode 100755 index 0000000..d8e46bc --- /dev/null +++ b/app/Models/OrdersAccidents.php @@ -0,0 +1,50 @@ +insertGetId($data); + return $id; + } + + public static function updateAccident($id, $data) + { + return DB::table("t_orders_accidents")->where("id", $id)->update($data); + } + + public static function updateAccidentByOrdId($ord_id, $data) + { + return DB::table("t_orders_accidents")->where("ord_id", $ord_id)->update($data); + } + + public static function deleteAccident($id) + { + return DB::table("t_orders_accidents")->where("id", $id)->delete(); + } + + public static function deleteAccidentByOrdId($ord_id) + { + return DB::table("t_orders_accidents")->where("ord_id", $ord_id)->delete(); + } +} diff --git a/app/Models/OrdersCheckpoints.php b/app/Models/OrdersCheckpoints.php new file mode 100755 index 0000000..5072fd2 --- /dev/null +++ b/app/Models/OrdersCheckpoints.php @@ -0,0 +1,142 @@ +insertGetId($data); + return $pid; + } + + public static function updateCheckpoint($id, $data) + { + return DB::table("t_orders_checkpoints")->where("id", $id)->update($data); + } + + public static function updtByOrdId($ord_id, $data) + { + return DB::table("t_orders_checkpoints")->where("ord_id", $ord_id)->update($data); + } + + public static function deleteCheckpoint($id) + { + return DB::table("t_orders_checkpoints")->where("id", $id)->delete(); + } + + public static function deleteCheckpointByPocketId($pocket_id) + { + return DB::table("t_orders_checkpoints")->where("pocket_id", $pocket_id)->delete(); + } + + public static function deleteCheckpointByOrdPocketId($ord_pocket_id) + { + return DB::table("t_orders_checkpoints")->where("ord_pocket_id", $ord_pocket_id)->delete(); + } +} diff --git a/app/Models/OrdersClients.php b/app/Models/OrdersClients.php new file mode 100755 index 0000000..6c6fab3 --- /dev/null +++ b/app/Models/OrdersClients.php @@ -0,0 +1,62 @@ +insertGetId($data); + return $id; + } + + public static function updt($id, $data) + { + return DB::table("t_orders_clients")->where("id", $id)->update($data); + } + + public static function updtByOrdId($ord_id, $data) + { + return DB::table("t_orders_clients")->where("ord_id", $ord_id)->update($data); + } + + public static function dlt($id) + { + return DB::table("t_orders_clients")->where("id", $id)->delete(); + } + + public static function dltByOrdId($ord_id) + { + return DB::table("t_orders_clients")->where("ord_id", $ord_id)->delete(); + } +} diff --git a/app/Models/OrdersDrivers.php b/app/Models/OrdersDrivers.php new file mode 100755 index 0000000..844a8f0 --- /dev/null +++ b/app/Models/OrdersDrivers.php @@ -0,0 +1,60 @@ +insertGetId($data); + return $id; + } + + public static function updt($id, $data) + { + return DB::table("t_orders_drivers")->where("id", $id)->update($data); + } + + public static function updtByOrdId($ord_id, $data) + { + return DB::table("t_orders_drivers")->where("ord_id", $ord_id)->update($data); + } + + public static function dlt($id) + { + return DB::table("t_orders_drivers")->where("id", $id)->delete(); + } + + public static function dltByOrdId($ord_id) + { + return DB::table("t_orders_drivers")->where("ord_id", $ord_id)->delete(); + } +} diff --git a/app/Models/OrdersDriversUploads.php b/app/Models/OrdersDriversUploads.php new file mode 100755 index 0000000..3cf0b98 --- /dev/null +++ b/app/Models/OrdersDriversUploads.php @@ -0,0 +1,111 @@ +insertGetId($data); + return $id; + } + + public static function updt($id, $data) + { + return DB::table("t_orders_drivers_uploads")->where("id", $id)->update($data); + } + + public static function updtByOrdId($ord_id, $data) + { + return DB::table("t_orders_drivers_uploads")->where("ord_id", $ord_id)->update($data); + } + + public static function dlt($id) + { + return DB::table("t_orders_drivers_uploads")->where("id", $id)->delete(); + } + + public static function dltByOrdId($ord_id) + { + return DB::table("t_orders_drivers_uploads")->where("ord_id", $ord_id)->delete(); + } +} diff --git a/app/Models/OrdersDrops.php b/app/Models/OrdersDrops.php new file mode 100755 index 0000000..d1bf94e --- /dev/null +++ b/app/Models/OrdersDrops.php @@ -0,0 +1,63 @@ +insertGetId($data); + return $id; + } + + public static function updt($id, $data) + { + return DB::table("t_orders_drops")->where("id", $id)->update($data); + } + + public static function updtByOrdId($ord_id, $data) + { + return DB::table("t_orders_drops")->where("ord_id", $ord_id)->update($data); + } + + public static function dlt($id) + { + return DB::table("t_orders_drops")->where("id", $id)->delete(); + } + + public static function dltByOrdId($ord_id) + { + return DB::table("t_orders_drops")->where("ord_id", $ord_id)->delete(); + } +} diff --git a/app/Models/OrdersInsurances.php b/app/Models/OrdersInsurances.php new file mode 100755 index 0000000..4f2a9b2 --- /dev/null +++ b/app/Models/OrdersInsurances.php @@ -0,0 +1,59 @@ +insertGetId($data); + return $id; + } + + public static function updt($id, $data) + { + return DB::table("t_orders_insurances")->where("id", $id)->update($data); + } + + public static function updtByOrdId($ord_id, $data) + { + return DB::table("t_orders_insurances")->where("ord_id", $ord_id)->update($data); + } + + public static function dlt($id) + { + return DB::table("t_orders_insurances")->where("id", $id)->delete(); + } + + public static function dltByOrdId($ord_id) + { + return DB::table("t_orders_insurances")->where("ord_id", $ord_id)->delete(); + } +} diff --git a/app/Models/OrdersInvoices.php b/app/Models/OrdersInvoices.php new file mode 100755 index 0000000..0dbc0ee --- /dev/null +++ b/app/Models/OrdersInvoices.php @@ -0,0 +1,109 @@ +refer pay_due_at, 2=>jatuh tempo 14 hari kerja + const PAY_DUE_TYPE_TIME = 1; + const PAY_DUE_TYPE_14_WORK_DAY = 2; + + const IS_PAID_NO = 0; + const IS_PAID_YES = 1; + + const IS_GNRT_INVC_NO = 0; + const IS_GNRT_INVC_YES = 1; + + // 1=>transfer + const PAID_TYPE_TF = 1; + + // 1=>admin, 2=>finance + const CRT_TYPE_SYSTEM = 0; + const CRT_TYPE_ADMIN = 1; + const CRT_TYPE_FINANCE = 2; + + // 1=>client + const INVC_FOR_CLIENT = 1; + + const DFT_TAX_PERCENT = 0; + + public static function get() + { + return DB::select("SELECT * FROM t_orders_invoices WHERE dlt is null;"); + } + + public static function getById($id) + { + return DB::select("SELECT * FROM t_orders_invoices WHERE dlt is null AND id = ? LIMIT 1;", [$id]); + } + + public static function getByCode($code) + { + return DB::select("SELECT * FROM t_orders_invoices WHERE dlt is null AND code = ? LIMIT 1;", [$code]); + } + + public static function getByOrdCode($code) + { + return DB::select("SELECT * FROM t_orders_invoices WHERE dlt is null AND ord_code = ? LIMIT 1;", [$code]); + } + + public static function getByOrdId($ordid) + { + return DB::select("SELECT * FROM t_orders_invoices WHERE dlt is null AND ord_id = ? LIMIT 1;", [$ordid]); + } + + public static function getByTerminId($terminid) + { + return DB::select("SELECT * FROM t_orders_invoices WHERE dlt is null AND c_termin_id = ? LIMIT 1;", [$terminid]); + } + + public static function getLikeCode($code) + { + return DB::select("SELECT COUNT(id) as total FROM t_orders_invoices WHERE dlt is null AND code LIKE ? LIMIT 1;", [$code.'%']); + } + + public static function getLikeCodeLastRunningNumber($code) + { + return DB::select("SELECT code FROM t_orders_invoices WHERE dlt is null AND code LIKE ? ORDER BY code DESC LIMIT 1;", [$code.'%']); + } + + public static function add($data) + { + $id = DB::table("t_orders_invoices")->insertGetId($data); + return $id; + } + + public static function updt($id, $data) + { + return DB::table("t_orders_invoices")->where("id", $id)->update($data); + } + + public static function updtByOrdId($ord_id, $data) + { + return DB::table("t_orders_invoices")->where("ord_id", $ord_id)->update($data); + } + + public static function dlt($id) + { + return DB::table("t_orders_invoices")->where("id", $id)->delete(); + } + + public static function dltByOrdId($ord_id) + { + return DB::table("t_orders_invoices")->where("ord_id", $ord_id)->delete(); + } +} diff --git a/app/Models/OrdersItems.php b/app/Models/OrdersItems.php new file mode 100755 index 0000000..a31af1f --- /dev/null +++ b/app/Models/OrdersItems.php @@ -0,0 +1,87 @@ +insertGetId($data); + return $id; + } + + public static function updt($id, $data) + { + return DB::table("t_orders_items")->where("id", $id)->update($data); + } + + public static function updtByOrdId($ord_id, $data) + { + return DB::table("t_orders_items")->where("ord_id", $ord_id)->update($data); + } + + public static function dlt($id) + { + return DB::table("t_orders_items")->where("id", $id)->delete(); + } + + public static function dltByOrdId($ord_id) + { + return DB::table("t_orders_items")->where("ord_id", $ord_id)->delete(); + } +} diff --git a/app/Models/OrdersLogsTf.php b/app/Models/OrdersLogsTf.php new file mode 100755 index 0000000..f3ec468 --- /dev/null +++ b/app/Models/OrdersLogsTf.php @@ -0,0 +1,103 @@ +insertGetId($data); + return $pid; + } + + public static function updateLogsTf($id, $data) + { + return DB::table("t_orders_logs_tf")->where("id", $id)->update($data); + } + + public static function updtByOrdId($ord_id, $data) + { + return DB::table("t_orders_logs_tf")->where("ord_id", $ord_id)->update($data); + } + + public static function deleteLogsTf($id) + { + return DB::table("t_orders_logs_tf")->where("id", $id)->delete(); + } +} diff --git a/app/Models/OrdersPckDrop.php b/app/Models/OrdersPckDrop.php new file mode 100755 index 0000000..7f47c0b --- /dev/null +++ b/app/Models/OrdersPckDrop.php @@ -0,0 +1,70 @@ +insertGetId($data); + return $id; + } + + public static function updt($id, $data) + { + return DB::table("t_orders_pck_drop")->where("id", $id)->update($data); + } + + public static function updtByOrdId($ord_id, $data) + { + return DB::table("t_orders_pck_drop")->where("ord_id", $ord_id)->update($data); + } + + public static function dlt($id) + { + return DB::table("t_orders_pck_drop")->where("id", $id)->delete(); + } + + public static function dltByOrdId($ord_id) + { + return DB::table("t_orders_pck_drop")->where("ord_id", $ord_id)->delete(); + } +} diff --git a/app/Models/OrdersPickups.php b/app/Models/OrdersPickups.php new file mode 100755 index 0000000..7f9d447 --- /dev/null +++ b/app/Models/OrdersPickups.php @@ -0,0 +1,63 @@ +insertGetId($data); + return $id; + } + + public static function updt($id, $data) + { + return DB::table("t_orders_pickups")->where("id", $id)->update($data); + } + + public static function updtByOrdId($ord_id, $data) + { + return DB::table("t_orders_pickups")->where("ord_id", $ord_id)->update($data); + } + + public static function dlt($id) + { + return DB::table("t_orders_pickups")->where("id", $id)->delete(); + } + + public static function dltByOrdId($ord_id) + { + return DB::table("t_orders_pickups")->where("ord_id", $ord_id)->delete(); + } +} diff --git a/app/Models/OrdersPockets.php b/app/Models/OrdersPockets.php new file mode 100755 index 0000000..faa953e --- /dev/null +++ b/app/Models/OrdersPockets.php @@ -0,0 +1,104 @@ +insertGetId($data); + return $pocket_id; + } + + public static function updatePocket($pocket_id, $data) + { + return DB::table("t_orders_pockets")->where("id", $pocket_id)->update($data); + } + + public static function updtByOrdId($ord_id, $data) + { + return DB::table("t_orders_pockets")->where("ord_id", $ord_id)->update($data); + } + + public static function deletePocket($pocket_id) + { + return DB::table("t_orders_pockets")->where("id", $pocket_id)->delete(); + } +} diff --git a/app/Models/OrdersRates.php b/app/Models/OrdersRates.php new file mode 100755 index 0000000..afb399f --- /dev/null +++ b/app/Models/OrdersRates.php @@ -0,0 +1,60 @@ +insertGetId($data); + return $id; + } + + public static function updt($id, $data) + { + return DB::table("t_orders_rates")->where("id", $id)->update($data); + } + + public static function updtByOrdId($ord_id, $data) + { + return DB::table("t_orders_rates")->where("ord_id", $ord_id)->update($data); + } + + public static function dlt($id) + { + return DB::table("t_orders_rates")->where("id", $id)->delete(); + } + + public static function dltByOrdId($ord_id) + { + return DB::table("t_orders_rates")->where("ord_id", $ord_id)->delete(); + } +} diff --git a/app/Models/OrdersTermins.php b/app/Models/OrdersTermins.php new file mode 100755 index 0000000..240ab5f --- /dev/null +++ b/app/Models/OrdersTermins.php @@ -0,0 +1,149 @@ +refer termin_ddln_at, 2=>refer to order finish(pengantaran selesai) + const DDLN_TERMIN_TYPE_TIME = 1; + const DDLN_TERMIN_TYPE_ORD_FINISH = 2; + + const IS_PAID_NO = 0; + const IS_PAID_YES = 1; + + // 1=>transfer + const PAID_TYPE_TF = 1; + + // 1=>admin, 2=>finance + const CRT_TYPE_SYSTEM = 0; + const CRT_TYPE_ADMIN = 1; + const CRT_TYPE_FINANCE = 2; + + const IS_ACTIVE_NO = 0; + const IS_ACTIVE_YES = 1; + + // 1=>client, 2=>vendor + const TERMIN_FOR_CLIENT = 1; + const TERMIN_FOR_VENDOR = 2; + + // merge per trx + const STTS_MERGE_NO = 0; + const STTS_MERGE_TO = 1; + const STTS_MERGE_RESULT = 2; + + /** + * termin_at itu deadline pembayaran + * column merge disini untuk merge per trx + */ + + public static function listWithFilter($filter = []) + { + $params = []; + $select = ''; + $where = ''; + + if (isset($filter['ord_id'])) { + $where .= ' AND ord_id = ?'; + $params[] = $filter['ord_id']; + } else if (isset($filter['ord_code'])) { + $where .= ' AND ord_code = ?'; + $params[] = $filter['ord_code']; + } + + if (isset($filter['termin_for'])) { + $where .= ' AND termin_for = ?'; + $params[] = $filter['termin_for']; + } + + if (isset($filter['crt_type'])) { + $where .= ' AND crt_type = ?'; + $params[] = $filter['crt_type']; + } + + if (isset($filter['termin_is_paid'])) { + $where .= ' AND termin_is_paid = ?'; + $params[] = $filter['termin_is_paid']; + } + + if (isset($filter['in_stts_merge'])) { + if (is_array($filter['in_stts_merge'])) { + $where .= ' AND stts_merge IN ('; + foreach ($filter['in_stts_merge'] as $in) { + $where .= '?,'; + $params[] = $in; + } + if (strpos(substr($where, -1), ',') !== false) { + $where = substr($where, 0, -1) . ')'; + } + } + } + + return DB::select("SELECT + ord_termin.* + $select + FROM t_orders_termins as ord_termin + WHERE dlt is null + $where + ;", $params); + } + + public static function get() + { + return DB::select("SELECT * FROM t_orders_termins WHERE dlt is null;"); + } + + public static function getById($id) + { + return DB::select("SELECT * FROM t_orders_termins WHERE dlt is null AND id = ? LIMIT 1;", [$id]); + } + + public static function getByOrdCode($code) + { + return DB::select("SELECT * FROM t_orders_termins WHERE dlt is null AND ord_code = ? LIMIT 1;", [$code]); + } + + public static function getByOrdId($ordid) + { + return DB::select("SELECT * FROM t_orders_termins WHERE dlt is null AND ord_id = ? LIMIT 1;", [$ordid]); + } + + public static function add($data) + { + $id = DB::table("t_orders_termins")->insertGetId($data); + return $id; + } + + public static function updt($id, $data) + { + return DB::table("t_orders_termins")->where("id", $id)->update($data); + } + + public static function updtByOrdId($ord_id, $data) + { + return DB::table("t_orders_termins")->where("ord_id", $ord_id)->update($data); + } + + public static function dlt($id) + { + return DB::table("t_orders_termins")->where("id", $id)->delete(); + } + + public static function dltByOrdId($ord_id) + { + return DB::table("t_orders_termins")->where("ord_id", $ord_id)->delete(); + } +} diff --git a/app/Models/OrdersVehicles.php b/app/Models/OrdersVehicles.php new file mode 100755 index 0000000..56dffba --- /dev/null +++ b/app/Models/OrdersVehicles.php @@ -0,0 +1,60 @@ +insertGetId($data); + return $id; + } + + public static function updt($id, $data) + { + return DB::table("t_orders_vehicles")->where("id", $id)->update($data); + } + + public static function updtByOrdId($ord_id, $data) + { + return DB::table("t_orders_vehicles")->where("ord_id", $ord_id)->update($data); + } + + public static function dlt($id) + { + return DB::table("t_orders_vehicles")->where("id", $id)->delete(); + } + + public static function dltByOrdId($ord_id) + { + return DB::table("t_orders_vehicles")->where("ord_id", $ord_id)->delete(); + } +} diff --git a/app/Models/OrdersVendors.php b/app/Models/OrdersVendors.php new file mode 100755 index 0000000..5791487 --- /dev/null +++ b/app/Models/OrdersVendors.php @@ -0,0 +1,193 @@ +origin_prov, + $filter["active_rates"]->dest_city, + $filter["active_rates"]->dest_district, + $filter["active_rates"]->sell_ftl, + $filter["active_rates"]->long_time + ); + if ($filter["prefer_truck_type"]) { + $query .= " AND v.type_id = ?"; + $params[] = $filter["prefer_truck_type"]; + } + $query .= " GROUP BY rate.vdr_id"; + return DB::select($query, $params); + } + + public static function add($data) + { + $id = DB::table("t_orders_vendors")->insertGetId($data); + return $id; + } + + public static function updt($id, $data) + { + return DB::table("t_orders_vendors") + ->where("id", $id) + ->update($data); + } + + public static function updtByOrdId($ord_id, $data) + { + return DB::table("t_orders_vendors") + ->where("ord_id", $ord_id) + ->update($data); + } + + public static function dlt($id) + { + return DB::table("t_orders_vendors") + ->where("id", $id) + ->delete(); + } + + public static function dltByOrdId($ord_id) + { + return DB::table("t_orders_vendors") + ->where("ord_id", $ord_id) + ->delete(); + } +} diff --git a/app/Models/PocketMoney.php b/app/Models/PocketMoney.php new file mode 100755 index 0000000..c5dc882 --- /dev/null +++ b/app/Models/PocketMoney.php @@ -0,0 +1,149 @@ +insertGetId($data); + return $pocket_id; + } + + public static function updatePocket($pocket_id, $data) + { + return DB::table("t_pocket_money")->where("id", $pocket_id)->update($data); + } + + public static function deletePocket($pocket_id) + { + return DB::table("t_pocket_money")->where("id", $pocket_id)->delete(); + } + + public static function getTypes() + { + $datas = []; + for ($i=0; $i<2; $i++) { + $datas[$i] = new \stdClass(); + if ($i === 0) { + $datas[$i]->id = PocketMoney::TYPE_BUNDLE; + $datas[$i]->name = PocketMoney::TYPE_BUNDLE_TEXT; + } else if ($i === 1) { + $datas[$i]->id = PocketMoney::TYPE_CHECKPOINTS; + $datas[$i]->name = PocketMoney::TYPE_CHECKPOINTS_TEXT; + } + } + return $datas; + } + + public static function getFlows() + { + $datas = []; + for ($i=0; $i<3; $i++) { + $datas[$i] = new \stdClass(); + if ($i === 0) { + $datas[$i]->id = PocketMoney::FLOW_DEPARTURE; + $datas[$i]->name = PocketMoney::FLOW_DEPARTURE_TEXT; + } else if ($i === 1) { + $datas[$i]->id = PocketMoney::FLOW_ARRIVAL; + $datas[$i]->name = PocketMoney::FLOW_ARRIVAL_TEXT; + } else if ($i === 2) { + $datas[$i]->id = PocketMoney::FLOW_HYBRID; + $datas[$i]->name = PocketMoney::FLOW_HYBRID_TEXT; + } + } + return $datas; + } +} diff --git a/app/Models/Region.php b/app/Models/Region.php new file mode 100755 index 0000000..827ac7d --- /dev/null +++ b/app/Models/Region.php @@ -0,0 +1,49 @@ +insertGetId($data); + return $id; + } + + public static function updateInsurance($id, $data) + { + return DB::table("t_static_insurances")->where("id", $id)->update($data); + } + + public static function deleteInsurance($id) + { + return DB::table("t_static_insurances")->where("id", $id)->delete(); + } +} diff --git a/app/Models/Tracks.php b/app/Models/Tracks.php new file mode 100755 index 0000000..dcab50c --- /dev/null +++ b/app/Models/Tracks.php @@ -0,0 +1,555 @@ +no signal, 2=>extremely weak signal 3=>very weak signal, 4=>good signal, 5=>strong signal + const STTS_GSM_DFT = 0; // default + const STTS_GSM_NO_SIGNAL = 1; + const STTS_GSM_BAD_SIGNAL = 2; + const STTS_GSM_WEAK_SIGNAL = 3; + const STTS_GSM_GOOD_SIGNAL = 4; + const STTS_GSM_STRONG_SIGNAL = 5; + + // type source + const SOURCE_GPS_TRACKER = 1; + const SOURCE_SMARTPHONE = 2; + + /** + * perlu tambahin filter untuk melihat tracking yang sesuai dengan vehiclenya aja + * karena ada case: + * device sudah sampai dilokasi pengantaran dan dimatikan, ketika dipakai lagi data tracking yang lama kelihatan dan loncat + * untuk mengatasi itu di service_tracking juga perlu validasi tambahan, entah seperti apa caranya + */ + public static function listCurrentTracks($filter = []) + { + $now = time(); + $params = []; + + $query = "SELECT"; + $query .= + " v.id as vid,v.device_id,v.name as vhc_name,c.name as vhc_cat_name,t.name as vhc_type_name"; + $query .= " ,v.nopol1,v.nopol2,v.nopol3,vd.fvhc_img"; + $query .= " ,v.is_track_holiday,v.track_sch_d,v.track_sch_h,vd.speed_limit,v.crt as vhc_crt"; + $query .= " ,client.id as client_group_id,client.c_name as client_group_name"; + $query .= " ,tr.ignition,tr.stts_engine,tr.stts_gps,tr.stts_gsm"; + $query .= " ,tr.pre_milleage,tr.sum_milleage,tr.vhc_milleage,v.sum_milleage AS vhc_sum_milleage_1"; + + // FRO + // $query .= " ,(SELECT SUM(pre_milleage) FROM " . self::T_TRACKS . " WHERE vhc_id = v.id LIMIT 1) as vhc_sum_milleage"; + + // $query .= " ,(SELECT crt_s FROM " . self::T_TRACKS . " WHERE stts_engine = " . self::STTS_EN_IDLING . " AND vhc_id = v.id AND crt_s >= ( + // SELECT crt_s FROM " . self::T_TRACKS . " WHERE stts_engine IN (" . self::STTS_EN_STOPING . "," . self::STTS_EN_MOVING . ") AND vhc_id = v.id AND crt_s <= tr.crt_s ORDER BY id DESC LIMIT 1 + // ) ORDER BY id ASC LIMIT 1) as lst_idle_at"; + + // $query .= " ,(SELECT crt_s FROM " . self::T_TRACKS . " WHERE stts_engine = " . self::STTS_EN_STOPING . " AND vhc_id = v.id AND crt_s >= ( + // SELECT crt_s FROM " . self::T_TRACKS . " WHERE stts_engine IN (" . self::STTS_EN_IDLING . "," . self::STTS_EN_MOVING . ") AND vhc_id = v.id AND crt_s <= tr.crt_s ORDER BY id DESC LIMIT 1 + // ) ORDER BY id ASC LIMIT 1) as lst_stop_at"; + + $query .= + " ,tr.id AS lst_master_id,tr.latitude AS lst_lat,tr.longitude AS lst_lng,tr.speed AS lst_speed,tr.orientation AS lst_orientation"; + $query .= " ,tr.crt AS lst_loc_crt,tr.crt_d AS lst_loc_crt_d,tr.crt_s AS lst_loc_crt_s"; + $query .= + " ,tr_addr.master_id AS lst_addr_master_id,tr_addr.country_text AS lst_country_text,tr_addr.state_text AS lst_state_text,tr_addr.city_text AS lst_city_text"; + $query .= + " ,tr_addr.district_text AS lst_district_text,tr_addr.village_text AS lst_village_text,tr_addr.postcode AS lst_postcode"; + $query .= " ,tr_addr.streets AS lst_streets,tr_addr.fulladdress AS lst_fulladdress"; + + // FRO + // $query .= " ,(SELECT COUNT(id) FROM " . self::T_TRACKS . " WHERE vhc_id = v.id AND action = 'heartbeat' AND crt BETWEEN ".($now-(10*60))." AND ".$now." LIMIT 1) as lst_heartbeat"; // heartbeat last data on further 10 minutes + + if (isset($filter["active_rates"])) { + $query .= + ",rate.vdr_id as rate_vdr_id,rate.vhc_type as rate_vhc_type,rate.origin_prov as rate_origin_prov,rate.dest_city as rate_dest_city,rate.dest_district as rate_dest_district"; + $query .= + ",rate.fast_time as rate_fast_time,rate.long_time as rate_long_time,rate.sell_kg as rate_sell_kg,rate.sell_cbm as rate_sell_cbm,rate.sell_ftl as rate_sell_ftl"; + } + if (isset($filter["get_order_data"])) { + $query .= + ",ord.id as ord_id,ord.code as ord_code,ord.status as ord_stts,ord.crt as ord_crt,ord_pck.pck_name as ord_pck_name,ord_pck.pck_addr as ord_pck_addr,ord_drop.drop_name as ord_drop_name,ord_drop.drop_addr as ord_drop_addr"; + $query .= + ",(SELECT nmKotamadyaKel FROM t_region WHERE kodeKab = ord_pck.pck_ktid LIMIT 1) ord_pck_ktname, (SELECT nmKotamadyaKel FROM t_region WHERE kodeKab = ord_drop.drop_ktid LIMIT 1) ord_drop_ktname"; + $query .= + ",ord_drv.drv_name as ord_drv_name,ord_drv.drv_phone_val as ord_drv_phone_val,ord_drv.drv_phone2_val as ord_drv_phone2_val,ord_drv.drv_addr as ord_drv_addr"; + $query .= ",ord_c.c_name as ord_c_name,ord_c.c_pt_name as ord_c_pt_name"; + } + $query .= " FROM t_vehicles AS v"; + $query .= " INNER JOIN t_vehicles_detail AS vd ON v.id = vd.vid"; + $query .= " INNER JOIN t_vehicles_types AS t ON v.type_id = t.id"; + $query .= " INNER JOIN t_vehicles_cats AS c ON v.cat_id = c.id"; + $query .= " LEFT JOIN t_users AS vendor ON v.vendor_id = vendor.id"; + $query .= " LEFT JOIN t_clients AS client ON vendor.client_group_id = client.id"; + // get last updated row from many rows + // $query .= " LEFT JOIN ( SELECT MAX(crt) max_crt, device_id FROM " . self::T_TRACKS . " WHERE latitude is not null AND longitude is not null GROUP BY device_id ORDER BY crt DESC ) AS tr1 ON (v.device_id = tr1.device_id)"; // cara lama berlaku utk gps tracker saja + // // $query .= " LEFT JOIN ( SELECT MAX(crt) max_crt, device_id, vhc_id FROM " . self::T_TRACKS . " WHERE latitude is not null AND longitude is not null GROUP BY vhc_id ORDER BY crt DESC ) AS tr1 ON (v.id = tr1.vhc_id)"; // support gps tracker dan smartphone / apapun yang mempunyai device_id(IMEI) + // $query .= " LEFT JOIN " . self::T_TRACKS . " AS tr ON (tr.crt = tr1.max_crt)"; + // get last updated tracking from updated table realtime + // $query .= " LEFT JOIN db_trucking.t_gps_tracks_rltm AS tr ON tr.vhc_id = v.id"; + $query .= " LEFT JOIN t_gps_tracks_rltm AS tr ON tr.vhc_id = v.id"; + // $query .= " LEFT JOIN " . self::T_TRACKS_ADDR . " AS tr_addr ON tr.id = tr_addr.master_id"; + + //FRO + $query .= + " LEFT JOIN " . + self::T_TRACKS_ADDR . + " AS tr_addr ON tr.latitude = tr_addr.lat and tr.longitude = tr_addr.lng"; + + if (isset($filter["active_rates"])) { + // $query .= " INNER JOIN t_conf_rates as rate ON v.type_id = rate.vhc_type"; + $query .= " INNER JOIN t_conf_rates as rate ON v.vendor_id = rate.vdr_id"; + } + if (isset($filter["get_order_data"])) { + // the old way => only 1 order 1 vehicle + // $query .= " LEFT JOIN t_orders as ord ON v.ord_id = ord.id"; + // $query .= " LEFT JOIN t_orders_pickups as ord_pck ON v.ord_id = ord_pck.ord_id"; + // $query .= " LEFT JOIN t_orders_drops as ord_drop ON v.ord_id = ord_drop.ord_id"; + // $query .= " LEFT JOIN t_orders_drivers as ord_drv ON v.ord_id = ord_drv.ord_id"; + // $query .= " LEFT JOIN t_orders_clients as ord_c ON v.ord_id = ord_c.ord_id"; + + // the new way => can handle 2 order in 1 vehicle + $query .= " LEFT JOIN t_orders_vehicles as ord_vhc ON v.id = ord_vhc.vhc_id"; + $query .= " LEFT JOIN t_orders as ord ON ord_vhc.ord_id = ord.id"; + $query .= " LEFT JOIN t_orders_pickups as ord_pck ON ord_vhc.ord_id = ord_pck.ord_id"; + $query .= " LEFT JOIN t_orders_drops as ord_drop ON ord_vhc.ord_id = ord_drop.ord_id"; + $query .= " LEFT JOIN t_orders_drivers as ord_drv ON ord_vhc.ord_id = ord_drv.ord_id"; + $query .= " LEFT JOIN t_orders_clients as ord_c ON ord_vhc.ord_id = ord_c.ord_id"; + } + $query .= " WHERE v.dlt is null"; + // $query .= " AND tr.action IN ('location','alarm')"; // kalo gamau ngambil data heartbeat(idling) + // $query .= " AND tr.device_id = v.device_id"; // cara lama berlaku utk gps tracker saja + // $query .= " AND tr.vhc_id = v.id"; // support gps tracker dan smartphone / apapun yang mempunyai device_id(IMEI) // bikin lemot + $query .= " AND tr.latitude != 0 AND tr.latitude is not null"; + if (isset($filter["status"])) { + $query .= " AND v.status = ?"; + $params[] = $filter["status"]; + } + if (isset($filter["is_in_ord"])) { + $query .= " AND v.is_in_ord = ?"; + $params[] = $filter["is_in_ord"]; + } + if (isset($filter["nopol1"]) && isset($filter["nopol2"]) && isset($filter["nopol3"])) { + $query .= " AND v.nopol1 = ? AND v.nopol2 = ? AND v.nopol3 = ?"; + array_push($params, $filter["nopol1"], $filter["nopol2"], $filter["nopol3"]); + } + if (isset($filter["vid"])) { + $query .= " AND v.id = ?"; + $params[] = $filter["vid"]; + } + if (isset($filter["vids"])) { + if ($filter["vids"] && count($filter["vids"]) > 0) { + $binds_vids = ""; + foreach ($filter["vids"] as $k => $v) { + $binds_vids .= "?,"; + $params[] = $v; + } + if (substr($binds_vids, -1) === ",") { + $binds_vids = substr($binds_vids, 0, -1); + } + $query .= " AND v.id IN ($binds_vids)"; + } else { + $query .= " AND v.id = ?"; + $params[] = 0; + } + } + if (isset($filter["own_by_vdr_id"])) { + $query .= " AND v.vendor_id = ?"; + $params[] = $filter["own_by_vdr_id"]; + } + if (isset($filter["active_rates"])) { + // v1 + // $query .= " AND rate.vdr_id != 0 AND rate.dest_city != 0 AND rate.dest_district != 0"; + // $query .= " AND rate.origin_prov = ? AND (rate.dest_city = ? OR rate.dest_district = ?) AND rate.sell_kg = ? AND rate.sell_cbm = ? AND rate.long_time = ?"; + // array_push($params, $filter['active_rates']->origin_prov, $filter['active_rates']->dest_city, $filter['active_rates']->dest_district, $filter['active_rates']->sell_kg, $filter['active_rates']->sell_cbm, $filter['active_rates']->long_time); + // v2 + $query .= + " AND rate.vdr_id != 0 AND rate.dest_city != 0 AND rate.is_active = " . ConfRates::IS_ACTIVE; + $query .= + " AND rate.origin_prov = ? AND (rate.dest_city = ? OR rate.dest_district = ?) AND rate.sell_ftl = ? AND rate.long_time = ?"; + array_push( + $params, + $filter["active_rates"]->origin_prov, + $filter["active_rates"]->dest_city, + $filter["active_rates"]->dest_district, + $filter["active_rates"]->sell_ftl, + $filter["active_rates"]->long_time + ); + } + if (isset($filter["prefer_truck_type"])) { + $query .= " AND v.type_id = ?"; + $params[] = $filter["prefer_truck_type"]; + } + if (isset($filter["get_order_data"])) { + if (isset($filter["client_id"])) { + $query .= " AND ord_c.c_id = ?"; + $params[] = $filter["client_id"]; + } + } + if (isset($filter["company"])) { + $query .= " AND client.id = ?"; + $params[] = $filter["company"]; + } + + // $query .= " AND v.id = 70"; + + $query .= " GROUP BY v.id"; + $query .= " ORDER BY tr.crt_d DESC"; + $query .= " LIMIT 500;"; + + // dd($query); + + $list = DB::select($query, $params); + foreach ($list as $_list) { + $_query = + " SELECT SUM(pre_milleage) as vhc_sum_milleage FROM " . self::T_TRACKS . " WHERE vhc_id = ?"; + $_query = DB::select($_query, [$_list->vid]); + $_list->vhc_sum_milleage = $_query[0]->vhc_sum_milleage; + + $_query = + " + SELECT + crt_s as lst_idle_at + FROM + " . + self::T_TRACKS . + " + WHERE + stts_engine = " . + self::STTS_EN_IDLING . + " + AND vhc_id = ? + AND crt_s >= ( + SELECT + crt_s + FROM + " . + self::T_TRACKS . + " + WHERE + stts_engine IN ( + " . + self::STTS_EN_STOPING . + ", + " . + self::STTS_EN_MOVING . + ") + AND vhc_id = ? + AND crt_s <= ? + ORDER BY + id DESC + LIMIT 1 + ) + ORDER BY + id ASC + LIMIT 1"; + $_query = DB::select($_query, [$_list->vid, $_list->vid, $_list->lst_loc_crt_s]); + $_list->lst_idle_at = count($_query) == 0 ? "" : $_query[0]->lst_idle_at; + + $_query = + "SELECT crt_s as lst_stop_at FROM " . + self::T_TRACKS . + " WHERE stts_engine = " . + self::STTS_EN_STOPING . + " AND vhc_id = ? AND crt_s >= ( + SELECT crt_s FROM " . + self::T_TRACKS . + " WHERE stts_engine IN (" . + self::STTS_EN_IDLING . + "," . + self::STTS_EN_MOVING . + ") AND vhc_id = ? AND crt_s <= ? ORDER BY id DESC LIMIT 1 + ) ORDER BY id ASC LIMIT 1 "; + $_query = DB::select($_query, [$_list->vid, $_list->vid, $_list->lst_loc_crt_s]); + $_list->lst_stop_at = count($_query) == 0 ? "" : $_query[0]->lst_stop_at; + + $_query = + " SELECT COUNT(id) as lst_heartbeat FROM " . + self::T_TRACKS . + " WHERE vhc_id = ? AND action = 'heartbeat' AND crt BETWEEN " . + ($now - 10 * 60) . + " AND " . + $now . + " LIMIT 1"; + $_query = DB::select($_query, [$_list->vid]); + $_list->lst_heartbeat = count($_query) == 0 ? "" : $_query[0]->lst_heartbeat; + } + return $list; + } + + public static function lastMoveTracks($vid, $filter = []) + { + $now = time(); + $params = []; + + /** + * bikin lemot 30s timeout karena ada 2 join di rows yang banyak + * solution: indexing column + * show index from t_gps_tracks_address; + * create index addr_device_id on t_gps_tracks_address (device_id); + * create index addr_master_id on t_gps_tracks_address (master_id); + * show index from t_gps_tracks; + * create index tracks_device_id on t_gps_tracks (device_id); + * show index from t_vehicles; + * create index vhc_device_id on t_vehicles (device_id); + * + * solution not working. Don't reinvent the wheel + * create view. not working + */ + + $query = "SELECT"; + $query .= " v.id as vid,v.device_id,v.nopol1,v.nopol2,v.nopol3"; + $query .= " ,tr.id as master_id,tr.latitude,tr.longitude,tr.speed,tr.orientation"; + $query .= " ,tr.crt AS lst_loc_crt,tr.crt_d AS lst_loc_crt_d,tr.crt_s AS lst_loc_crt_s"; + $query .= " ,tr.ignition,tr.stts_engine"; + $query .= " ,tr.pre_milleage,tr.sum_milleage,tr.vhc_milleage,v.sum_milleage AS vhc_sum_milleage_1"; + $query .= " ,addr.master_id AS addr_master_id,addr.crt AS addr_loc_crt"; + $query .= + " ,addr.country_text,addr.state_text,addr.city_text,addr.district_text,addr.village_text,addr.postcode,addr.streets,addr.postcode,addr.fulladdress"; + $query .= " FROM t_vehicles AS v"; + // $query .= " INNER JOIN " . self::T_TRACKS . " AS tr ON v.device_id = tr.device_id"; // cara lama berlaku utk gps tracker saja + $query .= " INNER JOIN " . self::T_TRACKS . " AS tr ON v.id = tr.vhc_id"; // support gps tracker dan smartphone / apapun yang mempunyai device_id(IMEI) + $query .= " LEFT JOIN " . self::T_TRACKS_ADDR . " AS addr ON tr.id = addr.master_id"; + $query .= " WHERE v.dlt is null"; + $query .= " AND v.id = ?"; + array_push($params, $vid); + $query .= " AND tr.latitude is not null"; + $query .= " AND tr.longitude is not null"; + + // last move based on date + // $query .= " AND tr.crt BETWEEN ? AND ?"; + // array_push($params, strtotime('-24 hours', $now), $now); + + if (isset($filter["start_date"]) && isset($filter["end_date"])) { + $query .= " AND tr.crt_d BETWEEN ? AND ?"; + array_push($params, $filter["start_date"], $filter["end_date"]); + } + + if (isset($filter["start_at"])) { + $query .= " AND tr.crt > ?"; + $params[] = $filter["start_at"]; + } + + // last move based on last count data + $query .= " GROUP BY tr.crt_d"; + $query .= " ORDER BY tr.crt_d DESC"; + // array_push($params, strtotime('-24 hours', $now), $now); + + if (isset($filter["limit"])) { + $query .= " LIMIT ?"; + $params[] = $filter["limit"] ?? 500; + } + + $query .= " ;"; + + return DB::select($query, $params); + } + + public static function nearestInCircle($lat, $lng, $rad, $filter = []) + { + $earth_rad = Helper::EARTH_RADIUS_M; + $t_gps_tracks = self::T_TRACKS; + + $select_select = ""; + $join_join = ""; + $where_where = ""; + + $params = [ + "lat1" => $lat, + "lat2" => $lat, + "lng" => $lng, + "v_status" => Vehicles::STTS_ACTIVE, + "v_is_in_ord" => Vehicles::IN_ORD_NO, + "rad" => $rad, + ]; + + if (isset($filter["active_rates"])) { + $select_select .= + ",rate.vdr_id as rate_vdr_id,rate.vhc_type as rate_vhc_type,rate.origin_prov as rate_origin_prov,rate.dest_city as rate_dest_city,rate.dest_district as rate_dest_district"; + $select_select .= + ",rate.fast_time as rate_fast_time,rate.long_time as rate_long_time,rate.sell_kg as rate_sell_kg,rate.sell_cbm"; + } + if (isset($filter["active_rates"])) { + // $join_join .= " INNER JOIN t_conf_rates as rate ON v.type_id = rate.vhc_type"; + $join_join .= " INNER JOIN t_conf_rates as rate ON v.vendor_id = rate.vdr_id"; + } + if (isset($filter["active_rates"])) { + // v1 + // $where_where .= " AND rate.vdr_id != 0 AND rate.dest_city != 0 AND rate.dest_district != 0"; + // $where_where .= " AND rate.origin_prov = :origin_prov AND (rate.dest_city = :dest_city OR rate.dest_district = :dest_district) AND rate.sell_kg = :sell_kg AND rate.sell_cbm = :sell_cbm AND rate.long_time = :long_time"; + // v2 + $where_where .= + " AND rate.vdr_id != 0 AND rate.dest_city != 0 AND rate.is_active = " . ConfRates::IS_ACTIVE; + $where_where .= + " AND rate.origin_prov = :origin_prov AND (rate.dest_city = :dest_city OR rate.dest_district = :dest_district) AND rate.sell_ftl = :sell_ftl AND rate.long_time = :long_time"; + $params["origin_prov"] = $filter["active_rates"]->origin_prov; + $params["dest_city"] = $filter["active_rates"]->dest_city; + $params["dest_district"] = $filter["active_rates"]->dest_district; + // v1 + // $params['sell_kg'] = $filter['active_rates']->sell_kg; + // $params['sell_cbm'] = $filter['active_rates']->sell_cbm; + // v2 + $params["sell_ftl"] = $filter["active_rates"]->sell_ftl; + $params["long_time"] = $filter["active_rates"]->long_time; + } + if (isset($filter["prefer_truck_type"])) { + $where_where .= " AND v.type_id = :prefer_truck_type"; + $params["prefer_truck_type"] = $filter["prefer_truck_type"]; + } + + $query = "SELECT v.*,tr.latitude,tr.longitude,tr.id as master_id + ,u.first_name as vendor_name,u.phone as vendor_phone,u.phone_code as vendor_phone_code,u.email as vendor_mail,u.fulladdress as vendor_addr + ,( $earth_rad * acos( cos( radians( :lat1 ) ) * cos( radians( tr.latitude ) ) + * cos( radians( tr.longitude ) - radians( :lng ) ) + sin( radians( :lat2 ) ) * sin(radians( tr.latitude )) ) ) AS distance + $select_select + FROM $t_gps_tracks as tr + INNER JOIN t_vehicles as v ON tr.vhc_id = v.id + INNER JOIN t_users as u ON v.vendor_id = u.id + -- get last updated row from many rows + LEFT JOIN ( SELECT MAX(crt) max_crt, vhc_id FROM $t_gps_tracks WHERE latitude is not null AND longitude is not null GROUP BY vhc_id ORDER BY crt DESC ) AS tr1 ON (v.id = tr1.vhc_id) + $join_join + WHERE v.dlt is null + AND v.status = :v_status + AND v.is_in_ord = :v_is_in_ord + AND tr.latitude is not null + AND tr.longitude != 0 + -- get last updated row from many rows + AND tr.crt = tr1.max_crt + $where_where + GROUP BY tr.vhc_id + HAVING distance <= :rad + -- ORDER BY distance ASC + ORDER BY tr.crt DESC + ;"; + return DB::select($query, $params); + } + + public static function addTracks($data) + { + $id = DB::table(self::T_TRACKS)->insertGetId($data); + return $id; + } + + public static function addTracksAddr($data) + { + $id = DB::table(self::T_TRACKS_ADDR)->insertGetId($data); + return $id; + } + + public static function listLogsGps($filter = []) + { + $params = []; + $where_where = ""; + $limit = ""; + + if (isset($filter["crt_greater_than"])) { + $where_where .= " AND crt > ?"; + $params[] = $filter["crt_greater_than"]; + } + + if (isset($filter["limit"])) { + $limit .= " LIMIT ?"; + $params[] = $filter["limit"]; + } + + return DB::select( + "SELECT + * + FROM " . + self::T_TRACKS . + " as tr + WHERE device_id is not null + AND device_id != 0 + " . + $where_where . + " + ORDER BY tr.crt DESC + " . + $limit . + " + ", + $params + ); + } + + public static function gpsLocsAddr($filter = []) + { + $params = []; + $select = ""; + $join = ""; + $where = ""; + $order_by = ""; + $group_by = ""; + $limit = ""; + + if (isset($filter["source"])) { + $where .= " AND tr.source = ?"; + $params[] = $filter["source"]; + } + + if (isset($filter["vhc_id"])) { + $where .= " AND tr.vhc_id = ?"; + $params[] = $filter["vhc_id"]; + } + + if (isset($filter["drv_id"])) { + $where .= " AND tr.drv_id = ?"; + $params[] = $filter["drv_id"]; + } + + if (isset($filter["group_by"])) { + $group_by .= " GROUP BY " . $filter["group_by"]; + } + if (isset($filter["order_by"])) { + $order_by .= " ORDER BY " . $filter["order_by"]; + } + if (isset($filter["limit"])) { + $limit .= " LIMIT " . $filter["limit"]; + } + + return DB::select( + "SELECT + tr.* + ,tr_addr.country_id,tr_addr.country_text,tr_addr.state_id,tr_addr.state_text,tr_addr.city_id,tr_addr.city_text + ,tr_addr.district_id,tr_addr.district_text,tr_addr.village_id,tr_addr.village_text,tr_addr.postcode,tr_addr.streets,tr_addr.fulladdress + ,tr_addr.stts_reverse_geo + $select + FROM t_gps_tracks as tr + LEFT JOIN t_gps_tracks_address as tr_addr ON tr.id = tr_addr.master_id + $join + WHERE tr.latitude is not null AND tr.longitude != 0 + $where + $group_by + $order_by + $limit + ;", + $params + ); + } +} \ No newline at end of file diff --git a/app/Models/UnitTypes.php b/app/Models/UnitTypes.php new file mode 100755 index 0000000..cb93a2c --- /dev/null +++ b/app/Models/UnitTypes.php @@ -0,0 +1,94 @@ +paket,2=>orang,3=>unit,4=>pcs + const UNIT_TYPE_PAKET = 1; + const UNIT_TYPE_ORANG = 2; + const UNIT_TYPE_UNIT = 3; + const UNIT_TYPE_PCS = 4; + const UNIT_TYPE_LITER = 5; + const UNIT_TYPE_CBM = 6; + const UNIT_TYPE_KG = 7; + const UNIT_TYPE_KOLI = 8; + const UNIT_TYPE_DAY = 9; + const UNIT_TYPE_HOUR = 10; + const UNIT_TYPE_MINUTE = 11; + const UNIT_TYPE_SECOND = 12; + const UNIT_TYPE_METER = 13; + const UNIT_TYPE_KM = 14; + const UNIT_TYPE_GRAM = 15; + const UNIT_TYPE_METER_PERSEGI = 16; + const UNIT_TYPE_LOT = 17; + const UNIT_TYPE_LS = 18; + + public static function listUnitTypes($filter = []) + { + $params = []; + $select = ''; + $where = ''; + + if (isset($filter['is_active'])) { + $where .= ' AND ut.is_active = ?'; + $params[] = $filter['is_active']; + } + + if (isset($filter['is_publish'])) { + $where .= ' AND ut.is_publish = ?'; + $params[] = $filter['is_publish']; + } + + return DB::select("SELECT + ut.* + $select + FROM + t_unit_types as ut + WHERE dlt is null + $where + ORDER BY ut.name ASC + ;", + $params); + } + + public static function get() + { + return DB::select("SELECT * FROM t_unit_types as ut WHERE dlt is null ORDER BY ut.name ASC;"); + } + + public static function getById($id) + { + return DB::select("SELECT * FROM t_unit_types as ut WHERE dlt is null AND id = ? ORDER BY ut.name ASC LIMIT 1;", [$id]); + } + + public static function getByName($name) + { + return DB::select("SELECT * FROM t_unit_types as ut WHERE dlt is null AND name = ? ORDER BY ut.name ASC LIMIT 1;", [$name]); + } + + public static function add($data) + { + $id = DB::table("t_unit_types")->insertGetId($data); + return $id; + } + + public static function updt($id, $data) + { + return DB::table("t_unit_types")->where("id", $id)->update($data); + } + + public static function dlt($id) + { + return DB::table("t_unit_types")->where("id", $id)->delete(); + } +} diff --git a/app/Models/Users.php b/app/Models/Users.php new file mode 100755 index 0000000..e8238bb --- /dev/null +++ b/app/Models/Users.php @@ -0,0 +1,268 @@ +insertGetId($data); + return $uid; + } + + public static function updateUser($uid, $data) + { + return DB::table("t_users") + ->where("id", $uid) + ->update($data); + } + + public static function updateUsersByGroupClientId($cid, $data) + { + return DB::table("t_users") + ->where("client_group_id", $cid) + ->update($data); + } + + public static function deleteUser($uid, $data) + { + return DB::table("t_users") + ->where("id", $uid) + ->delete(); + } + + public static function arrStatus() + { + return [Users::STATUS_ACTIVE, Users::STATUS_NOT_ACTIVE]; + } + + public static function arrRoles() + { + return [ + Users::ROLE_SU, + Users::ROLE_SUPERADMIN, + Users::ROLE_ADMIN, + Users::ROLE_FINANCE, + Users::ROLE_VENDOR, + Users::ROLE_CHECKER, + Users::ROLE_USER, + Users::ROLE_CLIENT_ADMIN, + Users::ROLE_CLIENT_STAFF, + Users::ROLE_CLIENT_USER, + Users::ROLE_SPECIAL_TRACKING, + ]; + } + + public static function listRoles($currentRole) + { + if ($currentRole == Users::ROLE_SUPERADMIN) { + return DB::select( + "SELECT * FROM t_users_roles WHERE dlt is null AND status = 1 AND id IN (?,?,?,?,?,?);", + [ + // Users::ROLE_SUPERADMIN, + Users::ROLE_ADMIN, + Users::ROLE_FINANCE, + Users::ROLE_VENDOR, + Users::ROLE_CHECKER, + Users::ROLE_CLIENT_ADMIN, + Users::ROLE_SPECIAL_TRACKING, + ] + ); + } elseif ($currentRole == Users::ROLE_ADMIN) { + return DB::select( + "SELECT * FROM t_users_roles WHERE dlt is null AND status = 1 AND id IN (?,?,?,?,?,?);", + [ + Users::ROLE_ADMIN, + Users::ROLE_FINANCE, + Users::ROLE_VENDOR, + Users::ROLE_CHECKER, + Users::ROLE_CLIENT_ADMIN, + Users::ROLE_SPECIAL_TRACKING, + ] + ); + } elseif ($currentRole == Users::ROLE_CLIENT_ADMIN) { + // return DB::select("SELECT * FROM t_users_roles WHERE dlt is null AND id IN (?,?);", [ + // Users::ROLE_CLIENT_STAFF, + // Users::ROLE_CLIENT_USER, + // ]); + } + return []; + } +} diff --git a/app/Models/UsersMenuPermissions.php b/app/Models/UsersMenuPermissions.php new file mode 100755 index 0000000..e5e4fd9 --- /dev/null +++ b/app/Models/UsersMenuPermissions.php @@ -0,0 +1,76 @@ +insertGetId($data); + return $id; + } + + public static function updt($id, $data) + { + return DB::table("t_permissions_menus")->where("id", $id)->update($data); + } + + public static function dlt($id) + { + return DB::table("t_permissions_menus")->where("id", $id)->delete(); + } +} diff --git a/app/Models/Vehicles.php b/app/Models/Vehicles.php new file mode 100755 index 0000000..08f018f --- /dev/null +++ b/app/Models/Vehicles.php @@ -0,0 +1,334 @@ +role == Users::ROLE_VENDOR) { + $where .= " AND v.vendor_id = " . $auth->uid; + } + + if (isset($filter["company"])) { + $where .= " AND client.id = ?"; + $params[] = $filter["company"]; + } + + // vd.speed_limit,vd.fuel_capacity,vd.fuel_drop_treshold,vd.max_pressure,vd.fvhc_img, + return DB::select( + "SELECT + " . + self::defaultSelectVehicle . + " + ,client.c_name as company_name + " . + $select . + " + FROM t_vehicles as v + INNER JOIN t_vehicles_detail AS vd ON v.id = vd.vid + LEFT JOIN t_vehicles_cats AS c ON v.cat_id = c.id + LEFT JOIN t_vehicles_types AS t ON v.type_id = t.id + LEFT JOIN t_vehicles_brands AS b ON v.brand_id = b.id + LEFT JOIN t_vehicles_models AS m ON v.model_id = m.id + LEFT JOIN t_drivers AS dc ON v.c_did = dc.id + LEFT JOIN t_drivers AS da ON v.a_did = da.id + LEFT JOIN t_users AS vdr ON v.vendor_id = vdr.id + LEFT JOIN t_clients AS client ON vdr.client_group_id = client.id + LEFT JOIN t_devices AS dvc ON v.device_id = dvc.device_id + WHERE v.dlt is null + " . + $where . + " + ORDER BY v.id ASC;", + $params + ); + } + + public static function getVehicles() + { + return DB::select("SELECT * FROM t_vehicles WHERE dlt is null;"); + } + + public static function showVehicleById($vid) + { + return DB::select( + "SELECT + " . + self::defaultSelectVehicle . + " + FROM t_vehicles as v + INNER JOIN t_vehicles_detail AS vd ON v.id = vd.vid + LEFT JOIN t_vehicles_cats AS c ON v.cat_id = c.id + LEFT JOIN t_vehicles_types AS t ON v.type_id = t.id + LEFT JOIN t_vehicles_brands AS b ON v.brand_id = b.id + LEFT JOIN t_vehicles_models AS m ON v.model_id = m.id + LEFT JOIN t_drivers AS dc ON v.c_did = dc.id + LEFT JOIN t_drivers AS da ON v.a_did = da.id + LEFT JOIN t_devices AS dvc ON v.device_id = dvc.device_id + WHERE v.dlt is null + AND v.id = ? + LIMIT 1;", + [$vid] + ); + } + + public static function getVehicleById($vid) + { + return DB::select( + "SELECT * FROM t_vehicles WHERE dlt is null AND id = ? LIMIT 1;", + [$vid] + ); + } + + public static function getVehicleByDeviceId($device_id) + { + return DB::select( + "SELECT v.*,vd.tax_exp,vd.kir_exp FROM t_vehicles as v INNER JOIN t_vehicles_detail as vd ON v.id = vd.vid WHERE v.dlt is null AND v.device_id = ? LIMIT 1;", + [$device_id] + ); + } + + public static function getVehicleBySimcard($simcard) + { + return DB::select( + "SELECT * FROM t_vehicles WHERE dlt is null AND simcard = ? LIMIT 1;", + [$simcard] + ); + } + + public static function getVehicleByPlatNo($nopol1, $nopol2, $nopol3) + { + return DB::select( + "SELECT v.*,vd.tax_exp,vd.kir_exp FROM t_vehicles as v INNER JOIN t_vehicles_detail as vd ON v.id = vd.vid WHERE v.dlt is null AND v.nopol1 = ? AND v.nopol2 = ? AND v.nopol3 = ? LIMIT 2;", + [$nopol1, $nopol2, $nopol3] + ); + } + + public static function searchVehicleByPlatNo($nopol1, $nopol2, $nopol3) + { + return DB::select( + "SELECT v.*,vd.tax_exp,vd.kir_exp FROM t_vehicles as v INNER JOIN t_vehicles_detail as vd ON v.id = vd.vid WHERE v.dlt is null AND v.nopol1 LIKE '%" . + $nopol1 . + "%' AND v.nopol2 LIKE '%" . + $nopol2 . + "%' AND v.nopol3 LIKE '%" . + $nopol3 . + "%';" + ); + } + + public static function getVehicleByIdAllData($vid) + { + return DB::select( + "SELECT + *,v.id as vhc_id + FROM t_vehicles as v + INNER JOIN t_vehicles_detail as vd ON v.id = vd.vid + WHERE v.dlt is null + AND v.id = ? + LIMIT 1;", + [$vid] + ); + } + + public static function getVehiclesInIds($vids) + { + $params = []; + $where_in = ""; + + $vids = explode(",", $vids); + foreach ($vids as $vid) { + $where_in .= "?,"; + array_push($params, $vid); + } + if (strpos($where_in, ",") !== false) { + $where_in = substr($where_in, 0, -1); + } + return DB::select( + "SELECT * FROM t_vehicles WHERE dlt is null AND id IN (" . + $where_in . + ");", + $params + ); + } + + public static function getVehiclesInIdsActiveNoInOrder($vids) + { + $params = []; + $where_in = ""; + + $vids = explode(",", $vids); + foreach ($vids as $vid) { + $where_in .= "?,"; + array_push($params, $vid); + } + if (strpos($where_in, ",") !== false) { + $where_in = substr($where_in, 0, -1); + } + return DB::select( + "SELECT + v.*,ord.status as ord_status + FROM t_vehicles as v + LEFT JOIN (SELECT MAX(ord_id) as max_ord_id,vhc_id FROM t_orders_vehicles GROUP BY vhc_id) as ord_vhc1 ON (v.id = ord_vhc1.vhc_id) + LEFT JOIN t_orders as ord ON (ord_vhc1.max_ord_id = ord.id) + WHERE v.dlt is null + AND v.status = " . + Vehicles::STTS_ACTIVE . + " + AND v.is_in_ord = " . + Vehicles::IN_ORD_NO . + " + AND (ord.status is null OR ord.status IN (" . + Orders::STTS_CLIENT_PAY . + "," . + Orders::STTS_VENDOR_PAYED . + "," . + Orders::STTS_CLOSE . + "," . + Orders::STTS_CANCEL . + ")) + AND v.id IN (" . + $where_in . + ") + ;", + $params + ); + } + + public static function getVehiclesInVendorIdsActiveNoInOrder( + $vendorIds, + $prefer_truck_type = 0 + ) { + $params = []; + $where_in = ""; + $where_where = ""; + + $vendorIds = explode(",", $vendorIds); + foreach ($vendorIds as $vendorId) { + $where_in .= "?,"; + array_push($params, $vendorId); + } + if (strpos($where_in, ",") !== false) { + $where_in = substr($where_in, 0, -1); + } + + if ($prefer_truck_type != 0) { + $where_where = " AND v.type_id = ?"; + array_push($params, $prefer_truck_type); + } + + return DB::select( + "SELECT + v.*,ord.status as ord_status + FROM t_vehicles as v + LEFT JOIN (SELECT MAX(ord_id) as max_ord_id,vhc_id FROM t_orders_vehicles GROUP BY vhc_id) as ord_vhc1 ON (v.id = ord_vhc1.vhc_id) + LEFT JOIN t_orders as ord ON (ord_vhc1.max_ord_id = ord.id) + INNER JOIN t_gps_tracks as tr ON v.device_id = tr.device_id + WHERE v.dlt is null + AND v.status = " . + Vehicles::STTS_ACTIVE . + " + AND v.is_in_ord = " . + Vehicles::IN_ORD_NO . + " + AND (ord.status is null OR ord.status IN (" . + Orders::STTS_CLIENT_PAY . + "," . + Orders::STTS_VENDOR_PAYED . + "," . + Orders::STTS_CLOSE . + "," . + Orders::STTS_CANCEL . + ")) + AND v.vendor_id IN (" . + $where_in . + ") + $where_where + GROUP BY v.id + ;", + $params + ); + } + + public static function addVehicle($data) + { + $vid = DB::table("t_vehicles")->insertGetId($data); + return $vid; + } + + public static function updateVehicle($vid, $data) + { + return DB::table("t_vehicles") + ->where("id", $vid) + ->update($data); + } + + public static function deleteVehicle($vid) + { + return DB::table("t_vehicles") + ->where("id", $vid) + ->delete(); + } + + // default 1: truck + public static function listCats() + { + return DB::select( + "SELECT * FROM t_vehicles_cats WHERE dlt is null AND is_active = 1;" + ); + } + + // default 1: unknown + public static function listBrands() + { + return DB::select( + "SELECT * FROM t_vehicles_brands WHERE dlt is null AND is_active = 1;" + ); + } + + public static function listTypes() + { + return DB::select( + "SELECT * FROM t_vehicles_types WHERE dlt is null AND is_active = 1;" + ); + } + + public static function listModels() + { + return DB::select( + "SELECT * FROM t_vehicles_models WHERE dlt is null AND is_active = 1;" + ); + } +} diff --git a/app/Models/VehiclesDetail.php b/app/Models/VehiclesDetail.php new file mode 100755 index 0000000..12f98b9 --- /dev/null +++ b/app/Models/VehiclesDetail.php @@ -0,0 +1,45 @@ +insertGetId($data); + return $id; + } + + public static function updateDetail($id, $data) + { + return DB::table("t_vehicles_detail")->where("id", $id)->update($data); + } + + public static function updateDetailByVid($vid, $data) + { + return DB::table("t_vehicles_detail")->where("vid", $vid)->update($data); + } + + public static function deleteDetail($id) + { + return DB::table("t_vehicles_detail")->where("id", $id)->delete(); + } + + public static function deleteDetailByVid($vid) + { + return DB::table("t_vehicles_detail")->where("vid", $vid)->delete(); + } +} diff --git a/app/Models/Zone.php b/app/Models/Zone.php new file mode 100755 index 0000000..83235a7 --- /dev/null +++ b/app/Models/Zone.php @@ -0,0 +1,388 @@ +role == Users::ROLE_CLIENT_ADMIN) { + $query .= " AND z.client_group_id = " . $auth->client_group_id; + } + + if ($auth->role == Users::ROLE_VENDOR) { + $query .= " AND z.client_group_id = " . $auth->client_group_id; + } + + if (isset($filter["is_active"])) { + if ($filter["is_active"] == self::STATUS_ACTIVE) { + $query .= " AND z.status = " . self::STATUS_ACTIVE; + } elseif ($filter["is_active"] == self::STATUS_INACTIVE) { + $query .= " AND z.status = " . self::STATUS_INACTIVE; + } + } + + if (isset($filter["company"])) { + $query .= " AND c.id = ?"; + $params[] = $filter["company"]; + } + + if (isset($filter["workflow_type"])) { + $query .= " AND z.workflow_type = ?"; + $params[] = $filter["workflow_type"]; + } + if (isset($filter["type"])) { + $query .= " AND z.type = ?"; + $params[] = $filter["type"]; + } + + return DB::select($query, $params); + + // return DB::select("SELECT z.* + // ,c.c_name AS client_group_name + // ,zt.name AS type_name,zw.name AS workflow_type_name + // ,uc.role AS crt_role,up.role AS updt_role + // ,uc1.c_name AS crt_client_group_name,up1.c_name AS updt_client_group_name + // ,uc2.name AS crt_role_name,up2.name AS updt_role_name + // FROM t_zones AS z + // LEFT JOIN t_clients AS c ON z.client_group_id = c.id + // LEFT JOIN t_zones_types AS zt ON z.type = zt.id + // LEFT JOIN t_zones_workflows AS zw ON z.workflow_type = zw.id + // LEFT JOIN t_users AS uc ON z.crt_by = uc.id + // LEFT JOIN t_clients AS uc1 ON uc.client_group_id = uc1.id + // LEFT JOIN t_users AS up ON z.updt_by = up.id + // LEFT JOIN t_clients AS up1 ON uc.client_group_id = up1.id + // LEFT JOIN t_users_roles AS uc2 ON uc.role = uc2.id + // LEFT JOIN t_users_roles AS up2 ON up.role = up2.id + // WHERE z.dlt is null + // ;"); + } + + public static function getActiveZones($client_group_id = 0, $type = 0, $workflow_type = 0) + { + $where_client_group_id = ""; + if ($client_group_id != 0) { + $where_client_group_id = " AND z.client_group_id = " . $client_group_id; + } + + $where_type = ""; + if ($type != 0) { + $where_type = " AND z.type = " . $type; + } + + $where_workflow_type = ""; + if ($workflow_type != 0) { + $where_workflow_type = " AND z.workflow_type = " . $workflow_type; + } + + return DB::select( + "SELECT + z.* + FROM t_zones as z WHERE z.dlt is null AND z.status = " . + Zone::STATUS_ACTIVE . + $where_client_group_id . + $where_type . + $where_workflow_type . + " ;" + ); + } + + public static function showZoneById($zid) + { + return DB::select( + "SELECT z.* + ,c.c_name AS client_group_name + ,zt.name AS type_name,zw.name AS workflow_type_name + ,(SELECT nmProvinsiKel FROM t_region WHERE kodeProv = z.prid LIMIT 1) as prid_name + ,(SELECT nmKotamadyaKel FROM t_region WHERE kodeKab = z.ktid LIMIT 1) as ktid_name + ,(SELECT nmKecamatanKel FROM t_region WHERE kodeKec = z.kcid LIMIT 1) as kcid_name + ,(SELECT nmKelurahan FROM t_region WHERE kodeKel = z.klid LIMIT 1) as klid_name + ,uc.role AS crt_role,up.role AS updt_role + ,uc1.c_name AS crt_client_group_name,up1.c_name AS updt_client_group_name + ,uc2.name AS crt_role_name,up2.name AS updt_role_name + FROM t_zones AS z + LEFT JOIN t_clients AS c ON z.client_group_id = c.id + LEFT JOIN t_zones_types AS zt ON z.type = zt.id + LEFT JOIN t_zones_workflows AS zw ON z.workflow_type = zw.id + LEFT JOIN t_users AS uc ON z.crt_by = uc.id + LEFT JOIN t_clients AS uc1 ON uc.client_group_id = uc1.id + LEFT JOIN t_users AS up ON z.updt_by = up.id + LEFT JOIN t_clients AS up1 ON uc.client_group_id = up1.id + LEFT JOIN t_users_roles AS uc2 ON uc.role = uc2.id + LEFT JOIN t_users_roles AS up2 ON up.role = up2.id + WHERE z.dlt is null + AND z.id = ? + LIMIT 1;", + [$zid] + ); + } + + public static function getZoneById($zid, $filter = []) + { + $select = ""; + + if (isset($filter["region_name"])) { + $select .= DB::raw( + ",(SELECT nmProvinsiKel FROM t_region WHERE kodeProv = z.prid LIMIT 1) as prid_name ,(SELECT nmKotamadyaKel FROM t_region WHERE kodeKab = z.ktid LIMIT 1) as ktid_name" + ); + } + + return DB::select("SELECT z.* $select FROM t_zones as z WHERE z.dlt is null AND z.id = ? LIMIT 1;", [ + $zid, + ]); + } + + public static function getZoneByIds($zids) + { + // dd($zids); + $params = []; + $where_in = ""; + foreach ($zids as $zid) { + $where_in .= "?,"; + array_push($params, $zid); + } + if (strpos($where_in, ",") !== false) { + $where_in = substr($where_in, 0, -1); + } + return DB::select( + "SELECT z.* + ,(SELECT nmProvinsiKel FROM t_region WHERE kodeProv = z.prid LIMIT 1) as prid_name + ,(SELECT nmKotamadyaKel FROM t_region WHERE kodeKab = z.ktid LIMIT 1) as ktid_name + -- ,(SELECT nmKecamatanKel FROM t_region WHERE kodeKec = z.kcid LIMIT 1) as kcid_name + -- ,(SELECT nmKelurahan FROM t_region WHERE kodeKel = z.klid LIMIT 1) as klid_name + FROM t_zones as z WHERE z.dlt is null AND z.id IN ($where_in);", + $params + ); + } + + public static function getZoneByName($name) + { + return DB::select("SELECT * FROM t_zones WHERE dlt is null AND name = ? LIMIT 2;", [$name]); + } + + public static function insideZoneCircle($lat, $lng) + { + return DB::select( + "SELECT + " . + Zone::defaultSelectInsideZone . + " + ,ST_Distance_Sphere( ST_GeomFromText('POINT($lng $lat)'), z.boundary_points) AS distance_meters + ,MBRContains( boundary_points, ST_GeomFromText('POINT($lng $lat)') ) as is_contain + ,MBRWithin( ST_GeomFromText('POINT($lng $lat)'), boundary_points ) as is_within + FROM t_zones AS z + INNER JOIN t_zones_types AS zt ON z.type = zt.id + INNER JOIN t_zones_workflows AS zw ON z.workflow_type = zw.id + LEFT JOIN t_clients AS c ON z.client_group_id = c.id + WHERE z.dlt is null AND z.status = ? AND z.boundary_type IN (?) + HAVING boundary_radius >= distance_meters + ;", + [Zone::STATUS_ACTIVE, Zone::ZONE_BOUNDARY_CIRCLE] + ); + } + + public static function insideZoneShape($lat, $lng) + { + return DB::select( + "SELECT + " . + Zone::defaultSelectInsideZone . + " + ,ST_Distance_Sphere( ST_GeomFromText('POINT($lng $lat)'), z.boundary_points) AS distance_meters + ,MBRContains( boundary_points, ST_GeomFromText('POINT($lng $lat)') ) as is_contain + ,MBRWithin( ST_GeomFromText('POINT($lng $lat)'), boundary_points ) as is_within + FROM t_zones AS z + INNER JOIN t_zones_types AS zt ON z.type = zt.id + INNER JOIN t_zones_workflows AS zw ON z.workflow_type = zw.id + LEFT JOIN t_clients AS c ON z.client_group_id = c.id + WHERE z.dlt is null AND z.status = ? AND z.boundary_type IN (?,?) + HAVING is_within = 1 AND is_contain = 1 + ;", + [Zone::STATUS_ACTIVE, Zone::ZONE_BOUNDARY_POLYGON, Zone::ZONE_BOUNDARY_RECTANGLE] + ); + } + + public static function insideOrdZoneCircle($lat, $lng, $filter = []) + { + $params = [Zone::STATUS_ACTIVE, Zone::ZONE_BOUNDARY_CIRCLE]; + $where = ""; + + if (isset($filter["zid"])) { + $where .= " AND z.id = ?"; + $params[] = $filter["zid"]; + } + + return DB::select( + "SELECT + " . + Zone::defaultSelectInsideZone . + " + ,ST_Distance_Sphere( ST_GeomFromText('POINT($lng $lat)'), z.boundary_points) AS distance_meters + ,MBRContains( boundary_points, ST_GeomFromText('POINT($lng $lat)') ) as is_contain + ,MBRWithin( ST_GeomFromText('POINT($lng $lat)'), boundary_points ) as is_within + FROM t_zones AS z + INNER JOIN t_zones_types AS zt ON z.type = zt.id + INNER JOIN t_zones_workflows AS zw ON z.workflow_type = zw.id + LEFT JOIN t_clients AS c ON z.client_group_id = c.id + WHERE z.dlt is null AND z.status = ? AND z.boundary_type IN (?) + $where + HAVING boundary_radius >= distance_meters + ;", + $params + ); + } + + public static function insideOrdZoneShape($lat, $lng, $filter = []) + { + $params = [Zone::STATUS_ACTIVE, Zone::ZONE_BOUNDARY_POLYGON, Zone::ZONE_BOUNDARY_RECTANGLE]; + $where = ""; + + if (isset($filter["zid"])) { + $where .= " AND z.id = ?"; + $params[] = $filter["zid"]; + } + + return DB::select( + "SELECT + " . + Zone::defaultSelectInsideZone . + " + ,ST_Distance_Sphere( ST_GeomFromText('POINT($lng $lat)'), z.boundary_points) AS distance_meters + ,MBRContains( boundary_points, ST_GeomFromText('POINT($lng $lat)') ) as is_contain + ,MBRWithin( ST_GeomFromText('POINT($lng $lat)'), boundary_points ) as is_within + FROM t_zones AS z + INNER JOIN t_zones_types AS zt ON z.type = zt.id + INNER JOIN t_zones_workflows AS zw ON z.workflow_type = zw.id + LEFT JOIN t_clients AS c ON z.client_group_id = c.id + WHERE z.dlt is null AND z.status = ? AND z.boundary_type IN (?,?) + $where + HAVING is_within = 1 AND is_contain = 1 + ;", + $params + ); + } + + public static function addZone($data) + { + $zid = DB::table("t_zones")->insertGetId($data); + return $zid; + } + + public static function updateZone($zid, $data) + { + return DB::table("t_zones") + ->where("id", $zid) + ->update($data); + } + + public static function updateZonesByGroupClientId($zid, $data) + { + return DB::table("t_zones") + ->where("id", $zid) + ->update($data); + } + + public static function deleteZone($zid, $data) + { + return DB::table("t_zones") + ->where("id", $zid) + ->delete(); + } + + public static function arrStatus() + { + return [Zone::STATUS_ACTIVE, Zone::STATUS_INACTIVE]; + } + + public static function arrTypes() + { + return [Zone::ZONE_TYPE_WAREHOUSE]; + } + + public static function listTypes() + { + return DB::select("SELECT * FROM t_zones_types WHERE dlt is null;"); + } + + public static function arrWorkflows() + { + return [Zone::ZONE_WORKFLOW_PICKUP, Zone::ZONE_WORKFLOW_DEST, Zone::ZONE_WORKFLOW_PARKING]; + } + + public static function listWorkflows() + { + return DB::select("SELECT * FROM t_zones_workflows WHERE dlt is null;"); + } + + public static function arrBoundarys() + { + return [Zone::ZONE_BOUNDARY_CIRCLE, Zone::ZONE_BOUNDARY_POLYGON, Zone::ZONE_BOUNDARY_RECTANGLE]; + } + + public static function listBoundarys() + { + return [ + [ + "id" => Zone::ZONE_BOUNDARY_CIRCLE, + "name" => Zone::ZONE_BOUNDARY_NAME_CIRCLE, + ], + [ + "id" => Zone::ZONE_BOUNDARY_POLYGON, + "name" => Zone::ZONE_BOUNDARY_NAME_POLYGON, + ], + [ + "id" => Zone::ZONE_BOUNDARY_RECTANGLE, + "name" => Zone::ZONE_BOUNDARY_NAME_RECTANGLE, + ], + ]; + } +} diff --git a/app/Providers/AppServiceProvider.php b/app/Providers/AppServiceProvider.php new file mode 100755 index 0000000..20e6af0 --- /dev/null +++ b/app/Providers/AppServiceProvider.php @@ -0,0 +1,30 @@ +app->environment("production")) { + $this->app["request"]->server->set("HTTPS", "on"); + } + } +} diff --git a/app/Providers/AuthServiceProvider.php b/app/Providers/AuthServiceProvider.php new file mode 100755 index 0000000..3049068 --- /dev/null +++ b/app/Providers/AuthServiceProvider.php @@ -0,0 +1,30 @@ + 'App\Policies\ModelPolicy', + ]; + + /** + * Register any authentication / authorization services. + * + * @return void + */ + public function boot() + { + $this->registerPolicies(); + + // + } +} diff --git a/app/Providers/BroadcastServiceProvider.php b/app/Providers/BroadcastServiceProvider.php new file mode 100755 index 0000000..395c518 --- /dev/null +++ b/app/Providers/BroadcastServiceProvider.php @@ -0,0 +1,21 @@ + [ + SendEmailVerificationNotification::class, + ], + ]; + + /** + * Register any events for your application. + * + * @return void + */ + public function boot() + { + parent::boot(); + + // + } +} diff --git a/app/Providers/RouteServiceProvider.php b/app/Providers/RouteServiceProvider.php new file mode 100755 index 0000000..540d17b --- /dev/null +++ b/app/Providers/RouteServiceProvider.php @@ -0,0 +1,80 @@ +mapApiRoutes(); + + $this->mapWebRoutes(); + + // + } + + /** + * Define the "web" routes for the application. + * + * These routes all receive session state, CSRF protection, etc. + * + * @return void + */ + protected function mapWebRoutes() + { + Route::middleware('web') + ->namespace($this->namespace) + ->group(base_path('routes/web.php')); + } + + /** + * Define the "api" routes for the application. + * + * These routes are typically stateless. + * + * @return void + */ + protected function mapApiRoutes() + { + Route::prefix('api') + ->middleware('api') + ->namespace($this->namespace) + ->group(base_path('routes/api.php')); + } +} diff --git a/app/Responses.php b/app/Responses.php new file mode 100755 index 0000000..eea5738 --- /dev/null +++ b/app/Responses.php @@ -0,0 +1,110 @@ + [ + 'code' => 200, + 'type' => 'success', + 'message' => 'success', + ], + ]; + + if ($msg) $apiResp['meta']['message'] = $msg; + + return $apiResp; + } + + public static function created($msg = null) + { + $apiResp = [ + 'meta' => [ + 'code' => 201, + 'type' => 'success', + 'message' => 'created', + ], + ]; + + if ($msg) $apiResp['meta']['message'] = $msg; + + return $apiResp; + } + + public static function accepted($msg = null) + { + $apiResp = [ + 'meta' => [ + 'code' => 202, + 'type' => 'success', + 'message' => 'accepted', + ], + ]; + + if ($msg) $apiResp['meta']['message'] = $msg; + + return $apiResp; + } + + public static function bad_request($msg = null) + { + $apiResp = [ + 'meta' => [ + 'code' => 400, + 'type' => 'bad_request', + 'message' => 'bad request', + ], + ]; + + if ($msg) $apiResp['meta']['message'] = $msg; + + return $apiResp; + } + + public static function not_found($msg = null) + { + $apiResp = [ + 'meta' => [ + 'code' => 404, + 'type' => 'not_found', + 'message' => 'not found', + ], + ]; + + if ($msg) $apiResp['meta']['message'] = $msg; + + return $apiResp; + } + + public static function bad_input($msg = null) + { + $apiResp = [ + 'meta' => [ + 'code' => 422, + 'type' => 'unprocessable_entity', + 'message' => 'bad input', + ], + ]; + + if ($msg) $apiResp['meta']['message'] = $msg; + + return $apiResp; + } + + public static function error($msg = null) + { + $apiResp = [ + 'meta' => [ + 'code' => 500, + 'type' => 'error', + 'message' => 'error', + ], + ]; + if (env('APP_DEBUG')) $apiResp['meta']['message'] = $msg; + + return $apiResp; + } +} diff --git a/app/User.php b/app/User.php new file mode 100755 index 0000000..8d9063c --- /dev/null +++ b/app/User.php @@ -0,0 +1,41 @@ + 'datetime', + ]; +} diff --git a/artisan b/artisan new file mode 100755 index 0000000..5c23e2e --- /dev/null +++ b/artisan @@ -0,0 +1,53 @@ +#!/usr/bin/env php +make(Illuminate\Contracts\Console\Kernel::class); + +$status = $kernel->handle( + $input = new Symfony\Component\Console\Input\ArgvInput, + new Symfony\Component\Console\Output\ConsoleOutput +); + +/* +|-------------------------------------------------------------------------- +| Shutdown The Application +|-------------------------------------------------------------------------- +| +| Once Artisan has finished running, we will fire off the shutdown events +| so that any final work may be done by the application before we shut +| down the process. This is the last thing to happen to the request. +| +*/ + +$kernel->terminate($input, $status); + +exit($status); diff --git a/bootstrap/app.php b/bootstrap/app.php new file mode 100755 index 0000000..037e17d --- /dev/null +++ b/bootstrap/app.php @@ -0,0 +1,55 @@ +singleton( + Illuminate\Contracts\Http\Kernel::class, + App\Http\Kernel::class +); + +$app->singleton( + Illuminate\Contracts\Console\Kernel::class, + App\Console\Kernel::class +); + +$app->singleton( + Illuminate\Contracts\Debug\ExceptionHandler::class, + App\Exceptions\Handler::class +); + +/* +|-------------------------------------------------------------------------- +| Return The Application +|-------------------------------------------------------------------------- +| +| This script returns the application instance. The instance is given to +| the calling script so we can separate the building of the instances +| from the actual running of the application and sending responses. +| +*/ + +return $app; diff --git a/bootstrap/cache/.gitignore b/bootstrap/cache/.gitignore new file mode 100755 index 0000000..d6b7ef3 --- /dev/null +++ b/bootstrap/cache/.gitignore @@ -0,0 +1,2 @@ +* +!.gitignore diff --git a/composer.json b/composer.json new file mode 100755 index 0000000..85c4b33 --- /dev/null +++ b/composer.json @@ -0,0 +1,67 @@ +{ + "name": "laravel/laravel", + "type": "project", + "description": "The Laravel Framework.", + "keywords": [ + "framework", + "laravel" + ], + "license": "MIT", + "require": { + "php": "^8.0.2|^8.2.0", + "barryvdh/laravel-dompdf": "^1.0", + "fruitcake/laravel-cors": "^2.0", + "guzzlehttp/guzzle": "^7.0", + "hidehalo/nanoid-php": "^1.1", + "jurosh/pdf-merge": "^2.1", + "laravel/framework": "^9.0.0", + "laravel/tinker": "^2.5", + "laravel/ui": "^4.0", + "yajra/laravel-datatables": "^9.0" + }, + "require-dev": { + "spatie/laravel-ignition": "^1.0", + "fakerphp/faker": "^1.9.1", + "mockery/mockery": "^1.3.1", + "nunomaduro/collision": "^6.1", + "phpunit/phpunit": "^8.5.8|^9.3.3" + }, + "config": { + "optimize-autoloader": true, + "preferred-install": "dist", + "sort-packages": true + }, + "extra": { + "laravel": { + "dont-discover": [] + } + }, + "autoload": { + "psr-4": { + "App\\": "app/" + }, + "classmap": [ + "database/seeds", + "database/factories" + ] + }, + "autoload-dev": { + "psr-4": { + "Tests\\": "tests/" + } + }, + "minimum-stability": "dev", + "prefer-stable": true, + "scripts": { + "post-autoload-dump": [ + "Illuminate\\Foundation\\ComposerScripts::postAutoloadDump", + "@php artisan package:discover --ansi" + ], + "post-root-package-install": [ + "@php -r \"file_exists('.env') || copy('.env.example', '.env');\"" + ], + "post-create-project-cmd": [ + "@php artisan key:generate --ansi" + ] + } +} diff --git a/composer.lock b/composer.lock new file mode 100755 index 0000000..b163bfa --- /dev/null +++ b/composer.lock @@ -0,0 +1,9257 @@ +{ + "_readme": [ + "This file locks the dependencies of your project to a known state", + "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", + "This file is @generated automatically" + ], + "content-hash": "f12f1aa4bd9db1e1402035c18249d8ae", + "packages": [ + { + "name": "asm89/stack-cors", + "version": "v2.2.0", + "source": { + "type": "git", + "url": "https://github.com/asm89/stack-cors.git", + "reference": "50f57105bad3d97a43ec4a485eb57daf347eafea" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/asm89/stack-cors/zipball/50f57105bad3d97a43ec4a485eb57daf347eafea", + "reference": "50f57105bad3d97a43ec4a485eb57daf347eafea", + "shasum": "" + }, + "require": { + "php": "^7.3|^8.0", + "symfony/http-foundation": "^5.3|^6|^7", + "symfony/http-kernel": "^5.3|^6|^7" + }, + "require-dev": { + "phpunit/phpunit": "^9", + "squizlabs/php_codesniffer": "^3.5" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.2-dev" + } + }, + "autoload": { + "psr-4": { + "Asm89\\Stack\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Alexander", + "email": "iam.asm89@gmail.com" + } + ], + "description": "Cross-origin resource sharing library and stack middleware", + "homepage": "https://github.com/asm89/stack-cors", + "keywords": [ + "cors", + "stack" + ], + "support": { + "issues": "https://github.com/asm89/stack-cors/issues", + "source": "https://github.com/asm89/stack-cors/tree/v2.2.0" + }, + "time": "2023-11-14T13:51:46+00:00" + }, + { + "name": "barryvdh/laravel-dompdf", + "version": "v1.0.2", + "source": { + "type": "git", + "url": "https://github.com/barryvdh/laravel-dompdf.git", + "reference": "de83130d029289e1b59f28b41c314ce1d157b4a0" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/barryvdh/laravel-dompdf/zipball/de83130d029289e1b59f28b41c314ce1d157b4a0", + "reference": "de83130d029289e1b59f28b41c314ce1d157b4a0", + "shasum": "" + }, + "require": { + "dompdf/dompdf": "^1.2.1", + "illuminate/support": "^6|^7|^8|^9", + "php": "^7.2 || ^8.0" + }, + "require-dev": { + "nunomaduro/larastan": "^1|^2", + "orchestra/testbench": "^4|^5|^6|^7", + "phpro/grumphp": "^1", + "squizlabs/php_codesniffer": "^3.5" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0-dev" + }, + "laravel": { + "providers": [ + "Barryvdh\\DomPDF\\ServiceProvider" + ], + "aliases": { + "PDF": "Barryvdh\\DomPDF\\Facade\\Pdf" + } + } + }, + "autoload": { + "psr-4": { + "Barryvdh\\DomPDF\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Barry vd. Heuvel", + "email": "barryvdh@gmail.com" + } + ], + "description": "A DOMPDF Wrapper for Laravel", + "keywords": [ + "dompdf", + "laravel", + "pdf" + ], + "support": { + "issues": "https://github.com/barryvdh/laravel-dompdf/issues", + "source": "https://github.com/barryvdh/laravel-dompdf/tree/v1.0.2" + }, + "funding": [ + { + "url": "https://fruitcake.nl", + "type": "custom" + }, + { + "url": "https://github.com/barryvdh", + "type": "github" + } + ], + "time": "2022-05-19T15:08:38+00:00" + }, + { + "name": "brick/math", + "version": "0.11.0", + "source": { + "type": "git", + "url": "https://github.com/brick/math.git", + "reference": "0ad82ce168c82ba30d1c01ec86116ab52f589478" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/brick/math/zipball/0ad82ce168c82ba30d1c01ec86116ab52f589478", + "reference": "0ad82ce168c82ba30d1c01ec86116ab52f589478", + "shasum": "" + }, + "require": { + "php": "^8.0" + }, + "require-dev": { + "php-coveralls/php-coveralls": "^2.2", + "phpunit/phpunit": "^9.0", + "vimeo/psalm": "5.0.0" + }, + "type": "library", + "autoload": { + "psr-4": { + "Brick\\Math\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "description": "Arbitrary-precision arithmetic library", + "keywords": [ + "Arbitrary-precision", + "BigInteger", + "BigRational", + "arithmetic", + "bigdecimal", + "bignum", + "brick", + "math" + ], + "support": { + "issues": "https://github.com/brick/math/issues", + "source": "https://github.com/brick/math/tree/0.11.0" + }, + "funding": [ + { + "url": "https://github.com/BenMorel", + "type": "github" + } + ], + "time": "2023-01-15T23:15:59+00:00" + }, + { + "name": "carbonphp/carbon-doctrine-types", + "version": "3.2.0", + "source": { + "type": "git", + "url": "https://github.com/CarbonPHP/carbon-doctrine-types.git", + "reference": "18ba5ddfec8976260ead6e866180bd5d2f71aa1d" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/CarbonPHP/carbon-doctrine-types/zipball/18ba5ddfec8976260ead6e866180bd5d2f71aa1d", + "reference": "18ba5ddfec8976260ead6e866180bd5d2f71aa1d", + "shasum": "" + }, + "require": { + "php": "^8.1" + }, + "conflict": { + "doctrine/dbal": "<4.0.0 || >=5.0.0" + }, + "require-dev": { + "doctrine/dbal": "^4.0.0", + "nesbot/carbon": "^2.71.0 || ^3.0.0", + "phpunit/phpunit": "^10.3" + }, + "type": "library", + "autoload": { + "psr-4": { + "Carbon\\Doctrine\\": "src/Carbon/Doctrine/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "KyleKatarn", + "email": "kylekatarnls@gmail.com" + } + ], + "description": "Types to use Carbon in Doctrine", + "keywords": [ + "carbon", + "date", + "datetime", + "doctrine", + "time" + ], + "support": { + "issues": "https://github.com/CarbonPHP/carbon-doctrine-types/issues", + "source": "https://github.com/CarbonPHP/carbon-doctrine-types/tree/3.2.0" + }, + "funding": [ + { + "url": "https://github.com/kylekatarnls", + "type": "github" + }, + { + "url": "https://opencollective.com/Carbon", + "type": "open_collective" + }, + { + "url": "https://tidelift.com/funding/github/packagist/nesbot/carbon", + "type": "tidelift" + } + ], + "time": "2024-02-09T16:56:22+00:00" + }, + { + "name": "dflydev/dot-access-data", + "version": "v3.0.2", + "source": { + "type": "git", + "url": "https://github.com/dflydev/dflydev-dot-access-data.git", + "reference": "f41715465d65213d644d3141a6a93081be5d3549" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/dflydev/dflydev-dot-access-data/zipball/f41715465d65213d644d3141a6a93081be5d3549", + "reference": "f41715465d65213d644d3141a6a93081be5d3549", + "shasum": "" + }, + "require": { + "php": "^7.1 || ^8.0" + }, + "require-dev": { + "phpstan/phpstan": "^0.12.42", + "phpunit/phpunit": "^7.5 || ^8.5 || ^9.3", + "scrutinizer/ocular": "1.6.0", + "squizlabs/php_codesniffer": "^3.5", + "vimeo/psalm": "^4.0.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "3.x-dev" + } + }, + "autoload": { + "psr-4": { + "Dflydev\\DotAccessData\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Dragonfly Development Inc.", + "email": "info@dflydev.com", + "homepage": "http://dflydev.com" + }, + { + "name": "Beau Simensen", + "email": "beau@dflydev.com", + "homepage": "http://beausimensen.com" + }, + { + "name": "Carlos Frutos", + "email": "carlos@kiwing.it", + "homepage": "https://github.com/cfrutos" + }, + { + "name": "Colin O'Dell", + "email": "colinodell@gmail.com", + "homepage": "https://www.colinodell.com" + } + ], + "description": "Given a deep data structure, access data by dot notation.", + "homepage": "https://github.com/dflydev/dflydev-dot-access-data", + "keywords": [ + "access", + "data", + "dot", + "notation" + ], + "support": { + "issues": "https://github.com/dflydev/dflydev-dot-access-data/issues", + "source": "https://github.com/dflydev/dflydev-dot-access-data/tree/v3.0.2" + }, + "time": "2022-10-27T11:44:00+00:00" + }, + { + "name": "doctrine/inflector", + "version": "2.0.10", + "source": { + "type": "git", + "url": "https://github.com/doctrine/inflector.git", + "reference": "5817d0659c5b50c9b950feb9af7b9668e2c436bc" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/doctrine/inflector/zipball/5817d0659c5b50c9b950feb9af7b9668e2c436bc", + "reference": "5817d0659c5b50c9b950feb9af7b9668e2c436bc", + "shasum": "" + }, + "require": { + "php": "^7.2 || ^8.0" + }, + "require-dev": { + "doctrine/coding-standard": "^11.0", + "phpstan/phpstan": "^1.8", + "phpstan/phpstan-phpunit": "^1.1", + "phpstan/phpstan-strict-rules": "^1.3", + "phpunit/phpunit": "^8.5 || ^9.5", + "vimeo/psalm": "^4.25 || ^5.4" + }, + "type": "library", + "autoload": { + "psr-4": { + "Doctrine\\Inflector\\": "lib/Doctrine/Inflector" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Guilherme Blanco", + "email": "guilhermeblanco@gmail.com" + }, + { + "name": "Roman Borschel", + "email": "roman@code-factory.org" + }, + { + "name": "Benjamin Eberlei", + "email": "kontakt@beberlei.de" + }, + { + "name": "Jonathan Wage", + "email": "jonwage@gmail.com" + }, + { + "name": "Johannes Schmitt", + "email": "schmittjoh@gmail.com" + } + ], + "description": "PHP Doctrine Inflector is a small library that can perform string manipulations with regard to upper/lowercase and singular/plural forms of words.", + "homepage": "https://www.doctrine-project.org/projects/inflector.html", + "keywords": [ + "inflection", + "inflector", + "lowercase", + "manipulation", + "php", + "plural", + "singular", + "strings", + "uppercase", + "words" + ], + "support": { + "issues": "https://github.com/doctrine/inflector/issues", + "source": "https://github.com/doctrine/inflector/tree/2.0.10" + }, + "funding": [ + { + "url": "https://www.doctrine-project.org/sponsorship.html", + "type": "custom" + }, + { + "url": "https://www.patreon.com/phpdoctrine", + "type": "patreon" + }, + { + "url": "https://tidelift.com/funding/github/packagist/doctrine%2Finflector", + "type": "tidelift" + } + ], + "time": "2024-02-18T20:23:39+00:00" + }, + { + "name": "doctrine/lexer", + "version": "3.0.1", + "source": { + "type": "git", + "url": "https://github.com/doctrine/lexer.git", + "reference": "31ad66abc0fc9e1a1f2d9bc6a42668d2fbbcd6dd" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/doctrine/lexer/zipball/31ad66abc0fc9e1a1f2d9bc6a42668d2fbbcd6dd", + "reference": "31ad66abc0fc9e1a1f2d9bc6a42668d2fbbcd6dd", + "shasum": "" + }, + "require": { + "php": "^8.1" + }, + "require-dev": { + "doctrine/coding-standard": "^12", + "phpstan/phpstan": "^1.10", + "phpunit/phpunit": "^10.5", + "psalm/plugin-phpunit": "^0.18.3", + "vimeo/psalm": "^5.21" + }, + "type": "library", + "autoload": { + "psr-4": { + "Doctrine\\Common\\Lexer\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Guilherme Blanco", + "email": "guilhermeblanco@gmail.com" + }, + { + "name": "Roman Borschel", + "email": "roman@code-factory.org" + }, + { + "name": "Johannes Schmitt", + "email": "schmittjoh@gmail.com" + } + ], + "description": "PHP Doctrine Lexer parser library that can be used in Top-Down, Recursive Descent Parsers.", + "homepage": "https://www.doctrine-project.org/projects/lexer.html", + "keywords": [ + "annotations", + "docblock", + "lexer", + "parser", + "php" + ], + "support": { + "issues": "https://github.com/doctrine/lexer/issues", + "source": "https://github.com/doctrine/lexer/tree/3.0.1" + }, + "funding": [ + { + "url": "https://www.doctrine-project.org/sponsorship.html", + "type": "custom" + }, + { + "url": "https://www.patreon.com/phpdoctrine", + "type": "patreon" + }, + { + "url": "https://tidelift.com/funding/github/packagist/doctrine%2Flexer", + "type": "tidelift" + } + ], + "time": "2024-02-05T11:56:58+00:00" + }, + { + "name": "dompdf/dompdf", + "version": "v1.2.2", + "source": { + "type": "git", + "url": "https://github.com/dompdf/dompdf.git", + "reference": "5031045d9640b38cfc14aac9667470df09c9e090" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/dompdf/dompdf/zipball/5031045d9640b38cfc14aac9667470df09c9e090", + "reference": "5031045d9640b38cfc14aac9667470df09c9e090", + "shasum": "" + }, + "require": { + "ext-dom": "*", + "ext-mbstring": "*", + "phenx/php-font-lib": "^0.5.4", + "phenx/php-svg-lib": "^0.3.3 || ^0.4.0", + "php": "^7.1 || ^8.0" + }, + "require-dev": { + "ext-json": "*", + "ext-zip": "*", + "mockery/mockery": "^1.3", + "phpunit/phpunit": "^7.5 || ^8 || ^9", + "squizlabs/php_codesniffer": "^3.5" + }, + "suggest": { + "ext-gd": "Needed to process images", + "ext-gmagick": "Improves image processing performance", + "ext-imagick": "Improves image processing performance", + "ext-zlib": "Needed for pdf stream compression" + }, + "type": "library", + "autoload": { + "psr-4": { + "Dompdf\\": "src/" + }, + "classmap": [ + "lib/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "LGPL-2.1" + ], + "authors": [ + { + "name": "Fabien Ménager", + "email": "fabien.menager@gmail.com" + }, + { + "name": "Brian Sweeney", + "email": "eclecticgeek@gmail.com" + }, + { + "name": "Gabriel Bull", + "email": "me@gabrielbull.com" + } + ], + "description": "DOMPDF is a CSS 2.1 compliant HTML to PDF converter", + "homepage": "https://github.com/dompdf/dompdf", + "support": { + "issues": "https://github.com/dompdf/dompdf/issues", + "source": "https://github.com/dompdf/dompdf/tree/v1.2.2" + }, + "time": "2022-04-27T13:50:54+00:00" + }, + { + "name": "dragonmantank/cron-expression", + "version": "v3.3.3", + "source": { + "type": "git", + "url": "https://github.com/dragonmantank/cron-expression.git", + "reference": "adfb1f505deb6384dc8b39804c5065dd3c8c8c0a" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/dragonmantank/cron-expression/zipball/adfb1f505deb6384dc8b39804c5065dd3c8c8c0a", + "reference": "adfb1f505deb6384dc8b39804c5065dd3c8c8c0a", + "shasum": "" + }, + "require": { + "php": "^7.2|^8.0", + "webmozart/assert": "^1.0" + }, + "replace": { + "mtdowling/cron-expression": "^1.0" + }, + "require-dev": { + "phpstan/extension-installer": "^1.0", + "phpstan/phpstan": "^1.0", + "phpstan/phpstan-webmozart-assert": "^1.0", + "phpunit/phpunit": "^7.0|^8.0|^9.0" + }, + "type": "library", + "autoload": { + "psr-4": { + "Cron\\": "src/Cron/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Chris Tankersley", + "email": "chris@ctankersley.com", + "homepage": "https://github.com/dragonmantank" + } + ], + "description": "CRON for PHP: Calculate the next or previous run date and determine if a CRON expression is due", + "keywords": [ + "cron", + "schedule" + ], + "support": { + "issues": "https://github.com/dragonmantank/cron-expression/issues", + "source": "https://github.com/dragonmantank/cron-expression/tree/v3.3.3" + }, + "funding": [ + { + "url": "https://github.com/dragonmantank", + "type": "github" + } + ], + "time": "2023-08-10T19:36:49+00:00" + }, + { + "name": "egulias/email-validator", + "version": "4.0.2", + "source": { + "type": "git", + "url": "https://github.com/egulias/EmailValidator.git", + "reference": "ebaaf5be6c0286928352e054f2d5125608e5405e" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/egulias/EmailValidator/zipball/ebaaf5be6c0286928352e054f2d5125608e5405e", + "reference": "ebaaf5be6c0286928352e054f2d5125608e5405e", + "shasum": "" + }, + "require": { + "doctrine/lexer": "^2.0 || ^3.0", + "php": ">=8.1", + "symfony/polyfill-intl-idn": "^1.26" + }, + "require-dev": { + "phpunit/phpunit": "^10.2", + "vimeo/psalm": "^5.12" + }, + "suggest": { + "ext-intl": "PHP Internationalization Libraries are required to use the SpoofChecking validation" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.0.x-dev" + } + }, + "autoload": { + "psr-4": { + "Egulias\\EmailValidator\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Eduardo Gulias Davis" + } + ], + "description": "A library for validating emails against several RFCs", + "homepage": "https://github.com/egulias/EmailValidator", + "keywords": [ + "email", + "emailvalidation", + "emailvalidator", + "validation", + "validator" + ], + "support": { + "issues": "https://github.com/egulias/EmailValidator/issues", + "source": "https://github.com/egulias/EmailValidator/tree/4.0.2" + }, + "funding": [ + { + "url": "https://github.com/egulias", + "type": "github" + } + ], + "time": "2023-10-06T06:47:41+00:00" + }, + { + "name": "fruitcake/laravel-cors", + "version": "v2.2.0", + "source": { + "type": "git", + "url": "https://github.com/fruitcake/laravel-cors.git", + "reference": "783a74f5e3431d7b9805be8afb60fd0a8f743534" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/fruitcake/laravel-cors/zipball/783a74f5e3431d7b9805be8afb60fd0a8f743534", + "reference": "783a74f5e3431d7b9805be8afb60fd0a8f743534", + "shasum": "" + }, + "require": { + "asm89/stack-cors": "^2.0.1", + "illuminate/contracts": "^6|^7|^8|^9", + "illuminate/support": "^6|^7|^8|^9", + "php": ">=7.2" + }, + "require-dev": { + "laravel/framework": "^6|^7.24|^8", + "orchestra/testbench-dusk": "^4|^5|^6|^7", + "phpunit/phpunit": "^6|^7|^8|^9", + "squizlabs/php_codesniffer": "^3.5" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.1-dev" + }, + "laravel": { + "providers": [ + "Fruitcake\\Cors\\CorsServiceProvider" + ] + } + }, + "autoload": { + "psr-4": { + "Fruitcake\\Cors\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fruitcake", + "homepage": "https://fruitcake.nl" + }, + { + "name": "Barry vd. Heuvel", + "email": "barryvdh@gmail.com" + } + ], + "description": "Adds CORS (Cross-Origin Resource Sharing) headers support in your Laravel application", + "keywords": [ + "api", + "cors", + "crossdomain", + "laravel" + ], + "support": { + "issues": "https://github.com/fruitcake/laravel-cors/issues", + "source": "https://github.com/fruitcake/laravel-cors/tree/v2.2.0" + }, + "funding": [ + { + "url": "https://fruitcake.nl", + "type": "custom" + }, + { + "url": "https://github.com/barryvdh", + "type": "github" + } + ], + "abandoned": true, + "time": "2022-02-23T14:25:13+00:00" + }, + { + "name": "fruitcake/php-cors", + "version": "v1.3.0", + "source": { + "type": "git", + "url": "https://github.com/fruitcake/php-cors.git", + "reference": "3d158f36e7875e2f040f37bc0573956240a5a38b" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/fruitcake/php-cors/zipball/3d158f36e7875e2f040f37bc0573956240a5a38b", + "reference": "3d158f36e7875e2f040f37bc0573956240a5a38b", + "shasum": "" + }, + "require": { + "php": "^7.4|^8.0", + "symfony/http-foundation": "^4.4|^5.4|^6|^7" + }, + "require-dev": { + "phpstan/phpstan": "^1.4", + "phpunit/phpunit": "^9", + "squizlabs/php_codesniffer": "^3.5" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.2-dev" + } + }, + "autoload": { + "psr-4": { + "Fruitcake\\Cors\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fruitcake", + "homepage": "https://fruitcake.nl" + }, + { + "name": "Barryvdh", + "email": "barryvdh@gmail.com" + } + ], + "description": "Cross-origin resource sharing library for the Symfony HttpFoundation", + "homepage": "https://github.com/fruitcake/php-cors", + "keywords": [ + "cors", + "laravel", + "symfony" + ], + "support": { + "issues": "https://github.com/fruitcake/php-cors/issues", + "source": "https://github.com/fruitcake/php-cors/tree/v1.3.0" + }, + "funding": [ + { + "url": "https://fruitcake.nl", + "type": "custom" + }, + { + "url": "https://github.com/barryvdh", + "type": "github" + } + ], + "time": "2023-10-12T05:21:21+00:00" + }, + { + "name": "graham-campbell/result-type", + "version": "v1.1.2", + "source": { + "type": "git", + "url": "https://github.com/GrahamCampbell/Result-Type.git", + "reference": "fbd48bce38f73f8a4ec8583362e732e4095e5862" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/GrahamCampbell/Result-Type/zipball/fbd48bce38f73f8a4ec8583362e732e4095e5862", + "reference": "fbd48bce38f73f8a4ec8583362e732e4095e5862", + "shasum": "" + }, + "require": { + "php": "^7.2.5 || ^8.0", + "phpoption/phpoption": "^1.9.2" + }, + "require-dev": { + "phpunit/phpunit": "^8.5.34 || ^9.6.13 || ^10.4.2" + }, + "type": "library", + "autoload": { + "psr-4": { + "GrahamCampbell\\ResultType\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Graham Campbell", + "email": "hello@gjcampbell.co.uk", + "homepage": "https://github.com/GrahamCampbell" + } + ], + "description": "An Implementation Of The Result Type", + "keywords": [ + "Graham Campbell", + "GrahamCampbell", + "Result Type", + "Result-Type", + "result" + ], + "support": { + "issues": "https://github.com/GrahamCampbell/Result-Type/issues", + "source": "https://github.com/GrahamCampbell/Result-Type/tree/v1.1.2" + }, + "funding": [ + { + "url": "https://github.com/GrahamCampbell", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/graham-campbell/result-type", + "type": "tidelift" + } + ], + "time": "2023-11-12T22:16:48+00:00" + }, + { + "name": "guzzlehttp/guzzle", + "version": "7.8.1", + "source": { + "type": "git", + "url": "https://github.com/guzzle/guzzle.git", + "reference": "41042bc7ab002487b876a0683fc8dce04ddce104" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/guzzle/guzzle/zipball/41042bc7ab002487b876a0683fc8dce04ddce104", + "reference": "41042bc7ab002487b876a0683fc8dce04ddce104", + "shasum": "" + }, + "require": { + "ext-json": "*", + "guzzlehttp/promises": "^1.5.3 || ^2.0.1", + "guzzlehttp/psr7": "^1.9.1 || ^2.5.1", + "php": "^7.2.5 || ^8.0", + "psr/http-client": "^1.0", + "symfony/deprecation-contracts": "^2.2 || ^3.0" + }, + "provide": { + "psr/http-client-implementation": "1.0" + }, + "require-dev": { + "bamarni/composer-bin-plugin": "^1.8.2", + "ext-curl": "*", + "php-http/client-integration-tests": "dev-master#2c025848417c1135031fdf9c728ee53d0a7ceaee as 3.0.999", + "php-http/message-factory": "^1.1", + "phpunit/phpunit": "^8.5.36 || ^9.6.15", + "psr/log": "^1.1 || ^2.0 || ^3.0" + }, + "suggest": { + "ext-curl": "Required for CURL handler support", + "ext-intl": "Required for Internationalized Domain Name (IDN) support", + "psr/log": "Required for using the Log middleware" + }, + "type": "library", + "extra": { + "bamarni-bin": { + "bin-links": true, + "forward-command": false + } + }, + "autoload": { + "files": [ + "src/functions_include.php" + ], + "psr-4": { + "GuzzleHttp\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Graham Campbell", + "email": "hello@gjcampbell.co.uk", + "homepage": "https://github.com/GrahamCampbell" + }, + { + "name": "Michael Dowling", + "email": "mtdowling@gmail.com", + "homepage": "https://github.com/mtdowling" + }, + { + "name": "Jeremy Lindblom", + "email": "jeremeamia@gmail.com", + "homepage": "https://github.com/jeremeamia" + }, + { + "name": "George Mponos", + "email": "gmponos@gmail.com", + "homepage": "https://github.com/gmponos" + }, + { + "name": "Tobias Nyholm", + "email": "tobias.nyholm@gmail.com", + "homepage": "https://github.com/Nyholm" + }, + { + "name": "Márk Sági-Kazár", + "email": "mark.sagikazar@gmail.com", + "homepage": "https://github.com/sagikazarmark" + }, + { + "name": "Tobias Schultze", + "email": "webmaster@tubo-world.de", + "homepage": "https://github.com/Tobion" + } + ], + "description": "Guzzle is a PHP HTTP client library", + "keywords": [ + "client", + "curl", + "framework", + "http", + "http client", + "psr-18", + "psr-7", + "rest", + "web service" + ], + "support": { + "issues": "https://github.com/guzzle/guzzle/issues", + "source": "https://github.com/guzzle/guzzle/tree/7.8.1" + }, + "funding": [ + { + "url": "https://github.com/GrahamCampbell", + "type": "github" + }, + { + "url": "https://github.com/Nyholm", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/guzzlehttp/guzzle", + "type": "tidelift" + } + ], + "time": "2023-12-03T20:35:24+00:00" + }, + { + "name": "guzzlehttp/promises", + "version": "2.0.2", + "source": { + "type": "git", + "url": "https://github.com/guzzle/promises.git", + "reference": "bbff78d96034045e58e13dedd6ad91b5d1253223" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/guzzle/promises/zipball/bbff78d96034045e58e13dedd6ad91b5d1253223", + "reference": "bbff78d96034045e58e13dedd6ad91b5d1253223", + "shasum": "" + }, + "require": { + "php": "^7.2.5 || ^8.0" + }, + "require-dev": { + "bamarni/composer-bin-plugin": "^1.8.2", + "phpunit/phpunit": "^8.5.36 || ^9.6.15" + }, + "type": "library", + "extra": { + "bamarni-bin": { + "bin-links": true, + "forward-command": false + } + }, + "autoload": { + "psr-4": { + "GuzzleHttp\\Promise\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Graham Campbell", + "email": "hello@gjcampbell.co.uk", + "homepage": "https://github.com/GrahamCampbell" + }, + { + "name": "Michael Dowling", + "email": "mtdowling@gmail.com", + "homepage": "https://github.com/mtdowling" + }, + { + "name": "Tobias Nyholm", + "email": "tobias.nyholm@gmail.com", + "homepage": "https://github.com/Nyholm" + }, + { + "name": "Tobias Schultze", + "email": "webmaster@tubo-world.de", + "homepage": "https://github.com/Tobion" + } + ], + "description": "Guzzle promises library", + "keywords": [ + "promise" + ], + "support": { + "issues": "https://github.com/guzzle/promises/issues", + "source": "https://github.com/guzzle/promises/tree/2.0.2" + }, + "funding": [ + { + "url": "https://github.com/GrahamCampbell", + "type": "github" + }, + { + "url": "https://github.com/Nyholm", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/guzzlehttp/promises", + "type": "tidelift" + } + ], + "time": "2023-12-03T20:19:20+00:00" + }, + { + "name": "guzzlehttp/psr7", + "version": "2.6.2", + "source": { + "type": "git", + "url": "https://github.com/guzzle/psr7.git", + "reference": "45b30f99ac27b5ca93cb4831afe16285f57b8221" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/guzzle/psr7/zipball/45b30f99ac27b5ca93cb4831afe16285f57b8221", + "reference": "45b30f99ac27b5ca93cb4831afe16285f57b8221", + "shasum": "" + }, + "require": { + "php": "^7.2.5 || ^8.0", + "psr/http-factory": "^1.0", + "psr/http-message": "^1.1 || ^2.0", + "ralouphie/getallheaders": "^3.0" + }, + "provide": { + "psr/http-factory-implementation": "1.0", + "psr/http-message-implementation": "1.0" + }, + "require-dev": { + "bamarni/composer-bin-plugin": "^1.8.2", + "http-interop/http-factory-tests": "^0.9", + "phpunit/phpunit": "^8.5.36 || ^9.6.15" + }, + "suggest": { + "laminas/laminas-httphandlerrunner": "Emit PSR-7 responses" + }, + "type": "library", + "extra": { + "bamarni-bin": { + "bin-links": true, + "forward-command": false + } + }, + "autoload": { + "psr-4": { + "GuzzleHttp\\Psr7\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Graham Campbell", + "email": "hello@gjcampbell.co.uk", + "homepage": "https://github.com/GrahamCampbell" + }, + { + "name": "Michael Dowling", + "email": "mtdowling@gmail.com", + "homepage": "https://github.com/mtdowling" + }, + { + "name": "George Mponos", + "email": "gmponos@gmail.com", + "homepage": "https://github.com/gmponos" + }, + { + "name": "Tobias Nyholm", + "email": "tobias.nyholm@gmail.com", + "homepage": "https://github.com/Nyholm" + }, + { + "name": "Márk Sági-Kazár", + "email": "mark.sagikazar@gmail.com", + "homepage": "https://github.com/sagikazarmark" + }, + { + "name": "Tobias Schultze", + "email": "webmaster@tubo-world.de", + "homepage": "https://github.com/Tobion" + }, + { + "name": "Márk Sági-Kazár", + "email": "mark.sagikazar@gmail.com", + "homepage": "https://sagikazarmark.hu" + } + ], + "description": "PSR-7 message implementation that also provides common utility methods", + "keywords": [ + "http", + "message", + "psr-7", + "request", + "response", + "stream", + "uri", + "url" + ], + "support": { + "issues": "https://github.com/guzzle/psr7/issues", + "source": "https://github.com/guzzle/psr7/tree/2.6.2" + }, + "funding": [ + { + "url": "https://github.com/GrahamCampbell", + "type": "github" + }, + { + "url": "https://github.com/Nyholm", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/guzzlehttp/psr7", + "type": "tidelift" + } + ], + "time": "2023-12-03T20:05:35+00:00" + }, + { + "name": "guzzlehttp/uri-template", + "version": "v1.0.3", + "source": { + "type": "git", + "url": "https://github.com/guzzle/uri-template.git", + "reference": "ecea8feef63bd4fef1f037ecb288386999ecc11c" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/guzzle/uri-template/zipball/ecea8feef63bd4fef1f037ecb288386999ecc11c", + "reference": "ecea8feef63bd4fef1f037ecb288386999ecc11c", + "shasum": "" + }, + "require": { + "php": "^7.2.5 || ^8.0", + "symfony/polyfill-php80": "^1.24" + }, + "require-dev": { + "bamarni/composer-bin-plugin": "^1.8.2", + "phpunit/phpunit": "^8.5.36 || ^9.6.15", + "uri-template/tests": "1.0.0" + }, + "type": "library", + "extra": { + "bamarni-bin": { + "bin-links": true, + "forward-command": false + } + }, + "autoload": { + "psr-4": { + "GuzzleHttp\\UriTemplate\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Graham Campbell", + "email": "hello@gjcampbell.co.uk", + "homepage": "https://github.com/GrahamCampbell" + }, + { + "name": "Michael Dowling", + "email": "mtdowling@gmail.com", + "homepage": "https://github.com/mtdowling" + }, + { + "name": "George Mponos", + "email": "gmponos@gmail.com", + "homepage": "https://github.com/gmponos" + }, + { + "name": "Tobias Nyholm", + "email": "tobias.nyholm@gmail.com", + "homepage": "https://github.com/Nyholm" + } + ], + "description": "A polyfill class for uri_template of PHP", + "keywords": [ + "guzzlehttp", + "uri-template" + ], + "support": { + "issues": "https://github.com/guzzle/uri-template/issues", + "source": "https://github.com/guzzle/uri-template/tree/v1.0.3" + }, + "funding": [ + { + "url": "https://github.com/GrahamCampbell", + "type": "github" + }, + { + "url": "https://github.com/Nyholm", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/guzzlehttp/uri-template", + "type": "tidelift" + } + ], + "time": "2023-12-03T19:50:20+00:00" + }, + { + "name": "hidehalo/nanoid-php", + "version": "1.1.13", + "source": { + "type": "git", + "url": "https://github.com/hidehalo/nanoid-php.git", + "reference": "3fc7c949f4e655939cc30e7110d658af3dbb0e30" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/hidehalo/nanoid-php/zipball/3fc7c949f4e655939cc30e7110d658af3dbb0e30", + "reference": "3fc7c949f4e655939cc30e7110d658af3dbb0e30", + "shasum": "" + }, + "require": { + "paragonie/random_compat": ">=2.0", + "php": "~5.6|~7.0|~8.0" + }, + "require-dev": { + "phpunit/phpunit": ">=5.6", + "squizlabs/php_codesniffer": "^2.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0-dev" + } + }, + "autoload": { + "psr-4": { + "Hidehalo\\Nanoid\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "hidehalo", + "email": "tianchen_cc@yeah.net", + "homepage": "https://github.com/hidehalo", + "role": "Owner" + } + ], + "description": "A copy of nanoid in PHP", + "homepage": "https://github.com/hidehalo/nanoid-php", + "keywords": [ + "hidehalo", + "nanoid-php" + ], + "support": { + "issues": "https://github.com/hidehalo/nanoid-php/issues", + "source": "https://github.com/hidehalo/nanoid-php/tree/1.1.13" + }, + "time": "2022-08-04T12:07:12+00:00" + }, + { + "name": "jurosh/pdf-merge", + "version": "2.1.0", + "source": { + "type": "git", + "url": "https://github.com/jurosh/php-pdf-merge.git", + "reference": "89ba3446c9f38c573e3b8bf577d2f22993494130" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/jurosh/php-pdf-merge/zipball/89ba3446c9f38c573e3b8bf577d2f22993494130", + "reference": "89ba3446c9f38c573e3b8bf577d2f22993494130", + "shasum": "" + }, + "require": { + "php": ">=5.6.20", + "setasign/fpdf": "^1.8", + "setasign/fpdi": "^2.3" + }, + "type": "library", + "autoload": { + "classmap": [ + "src/Jurosh/PDFMerge/PDFMerger.php", + "src/Jurosh/PDFMerge/PDFObject.php" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Juraj Husar", + "email": "jurosh@jurosh.com", + "homepage": "http://jurosh.com" + } + ], + "description": "PHP PDF Merger", + "homepage": "https://github.com/jurosh/php-pdf-merge", + "keywords": [ + "merge", + "pdf" + ], + "support": { + "issues": "https://github.com/jurosh/php-pdf-merge/issues", + "source": "https://github.com/jurosh/php-pdf-merge/tree/remove" + }, + "time": "2021-03-28T19:57:14+00:00" + }, + { + "name": "laravel/framework", + "version": "v9.52.16", + "source": { + "type": "git", + "url": "https://github.com/laravel/framework.git", + "reference": "082345d76fc6a55b649572efe10b11b03e279d24" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/laravel/framework/zipball/082345d76fc6a55b649572efe10b11b03e279d24", + "reference": "082345d76fc6a55b649572efe10b11b03e279d24", + "shasum": "" + }, + "require": { + "brick/math": "^0.9.3|^0.10.2|^0.11", + "doctrine/inflector": "^2.0.5", + "dragonmantank/cron-expression": "^3.3.2", + "egulias/email-validator": "^3.2.1|^4.0", + "ext-ctype": "*", + "ext-filter": "*", + "ext-hash": "*", + "ext-mbstring": "*", + "ext-openssl": "*", + "ext-session": "*", + "ext-tokenizer": "*", + "fruitcake/php-cors": "^1.2", + "guzzlehttp/uri-template": "^1.0", + "laravel/serializable-closure": "^1.2.2", + "league/commonmark": "^2.2.1", + "league/flysystem": "^3.8.0", + "monolog/monolog": "^2.0", + "nesbot/carbon": "^2.62.1", + "nunomaduro/termwind": "^1.13", + "php": "^8.0.2", + "psr/container": "^1.1.1|^2.0.1", + "psr/log": "^1.0|^2.0|^3.0", + "psr/simple-cache": "^1.0|^2.0|^3.0", + "ramsey/uuid": "^4.7", + "symfony/console": "^6.0.9", + "symfony/error-handler": "^6.0", + "symfony/finder": "^6.0", + "symfony/http-foundation": "^6.0", + "symfony/http-kernel": "^6.0", + "symfony/mailer": "^6.0", + "symfony/mime": "^6.0", + "symfony/process": "^6.0", + "symfony/routing": "^6.0", + "symfony/uid": "^6.0", + "symfony/var-dumper": "^6.0", + "tijsverkoyen/css-to-inline-styles": "^2.2.5", + "vlucas/phpdotenv": "^5.4.1", + "voku/portable-ascii": "^2.0" + }, + "conflict": { + "tightenco/collect": "<5.5.33" + }, + "provide": { + "psr/container-implementation": "1.1|2.0", + "psr/simple-cache-implementation": "1.0|2.0|3.0" + }, + "replace": { + "illuminate/auth": "self.version", + "illuminate/broadcasting": "self.version", + "illuminate/bus": "self.version", + "illuminate/cache": "self.version", + "illuminate/collections": "self.version", + "illuminate/conditionable": "self.version", + "illuminate/config": "self.version", + "illuminate/console": "self.version", + "illuminate/container": "self.version", + "illuminate/contracts": "self.version", + "illuminate/cookie": "self.version", + "illuminate/database": "self.version", + "illuminate/encryption": "self.version", + "illuminate/events": "self.version", + "illuminate/filesystem": "self.version", + "illuminate/hashing": "self.version", + "illuminate/http": "self.version", + "illuminate/log": "self.version", + "illuminate/macroable": "self.version", + "illuminate/mail": "self.version", + "illuminate/notifications": "self.version", + "illuminate/pagination": "self.version", + "illuminate/pipeline": "self.version", + "illuminate/queue": "self.version", + "illuminate/redis": "self.version", + "illuminate/routing": "self.version", + "illuminate/session": "self.version", + "illuminate/support": "self.version", + "illuminate/testing": "self.version", + "illuminate/translation": "self.version", + "illuminate/validation": "self.version", + "illuminate/view": "self.version" + }, + "require-dev": { + "ably/ably-php": "^1.0", + "aws/aws-sdk-php": "^3.235.5", + "doctrine/dbal": "^2.13.3|^3.1.4", + "ext-gmp": "*", + "fakerphp/faker": "^1.21", + "guzzlehttp/guzzle": "^7.5", + "league/flysystem-aws-s3-v3": "^3.0", + "league/flysystem-ftp": "^3.0", + "league/flysystem-path-prefixing": "^3.3", + "league/flysystem-read-only": "^3.3", + "league/flysystem-sftp-v3": "^3.0", + "mockery/mockery": "^1.5.1", + "orchestra/testbench-core": "^7.24", + "pda/pheanstalk": "^4.0", + "phpstan/phpdoc-parser": "^1.15", + "phpstan/phpstan": "^1.4.7", + "phpunit/phpunit": "^9.5.8", + "predis/predis": "^1.1.9|^2.0.2", + "symfony/cache": "^6.0", + "symfony/http-client": "^6.0" + }, + "suggest": { + "ably/ably-php": "Required to use the Ably broadcast driver (^1.0).", + "aws/aws-sdk-php": "Required to use the SQS queue driver, DynamoDb failed job storage, and SES mail driver (^3.235.5).", + "brianium/paratest": "Required to run tests in parallel (^6.0).", + "doctrine/dbal": "Required to rename columns and drop SQLite columns (^2.13.3|^3.1.4).", + "ext-apcu": "Required to use the APC cache driver.", + "ext-fileinfo": "Required to use the Filesystem class.", + "ext-ftp": "Required to use the Flysystem FTP driver.", + "ext-gd": "Required to use Illuminate\\Http\\Testing\\FileFactory::image().", + "ext-memcached": "Required to use the memcache cache driver.", + "ext-pcntl": "Required to use all features of the queue worker and console signal trapping.", + "ext-pdo": "Required to use all database features.", + "ext-posix": "Required to use all features of the queue worker.", + "ext-redis": "Required to use the Redis cache and queue drivers (^4.0|^5.0).", + "fakerphp/faker": "Required to use the eloquent factory builder (^1.9.1).", + "filp/whoops": "Required for friendly error pages in development (^2.14.3).", + "guzzlehttp/guzzle": "Required to use the HTTP Client and the ping methods on schedules (^7.5).", + "laravel/tinker": "Required to use the tinker console command (^2.0).", + "league/flysystem-aws-s3-v3": "Required to use the Flysystem S3 driver (^3.0).", + "league/flysystem-ftp": "Required to use the Flysystem FTP driver (^3.0).", + "league/flysystem-path-prefixing": "Required to use the scoped driver (^3.3).", + "league/flysystem-read-only": "Required to use read-only disks (^3.3)", + "league/flysystem-sftp-v3": "Required to use the Flysystem SFTP driver (^3.0).", + "mockery/mockery": "Required to use mocking (^1.5.1).", + "nyholm/psr7": "Required to use PSR-7 bridging features (^1.2).", + "pda/pheanstalk": "Required to use the beanstalk queue driver (^4.0).", + "phpunit/phpunit": "Required to use assertions and run tests (^9.5.8).", + "predis/predis": "Required to use the predis connector (^1.1.9|^2.0.2).", + "psr/http-message": "Required to allow Storage::put to accept a StreamInterface (^1.0).", + "pusher/pusher-php-server": "Required to use the Pusher broadcast driver (^6.0|^7.0).", + "symfony/cache": "Required to PSR-6 cache bridge (^6.0).", + "symfony/filesystem": "Required to enable support for relative symbolic links (^6.0).", + "symfony/http-client": "Required to enable support for the Symfony API mail transports (^6.0).", + "symfony/mailgun-mailer": "Required to enable support for the Mailgun mail transport (^6.0).", + "symfony/postmark-mailer": "Required to enable support for the Postmark mail transport (^6.0).", + "symfony/psr-http-message-bridge": "Required to use PSR-7 bridging features (^2.0)." + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "9.x-dev" + } + }, + "autoload": { + "files": [ + "src/Illuminate/Collections/helpers.php", + "src/Illuminate/Events/functions.php", + "src/Illuminate/Foundation/helpers.php", + "src/Illuminate/Support/helpers.php" + ], + "psr-4": { + "Illuminate\\": "src/Illuminate/", + "Illuminate\\Support\\": [ + "src/Illuminate/Macroable/", + "src/Illuminate/Collections/", + "src/Illuminate/Conditionable/" + ] + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Taylor Otwell", + "email": "taylor@laravel.com" + } + ], + "description": "The Laravel Framework.", + "homepage": "https://laravel.com", + "keywords": [ + "framework", + "laravel" + ], + "support": { + "issues": "https://github.com/laravel/framework/issues", + "source": "https://github.com/laravel/framework" + }, + "time": "2023-10-03T13:02:30+00:00" + }, + { + "name": "laravel/serializable-closure", + "version": "v1.3.3", + "source": { + "type": "git", + "url": "https://github.com/laravel/serializable-closure.git", + "reference": "3dbf8a8e914634c48d389c1234552666b3d43754" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/laravel/serializable-closure/zipball/3dbf8a8e914634c48d389c1234552666b3d43754", + "reference": "3dbf8a8e914634c48d389c1234552666b3d43754", + "shasum": "" + }, + "require": { + "php": "^7.3|^8.0" + }, + "require-dev": { + "nesbot/carbon": "^2.61", + "pestphp/pest": "^1.21.3", + "phpstan/phpstan": "^1.8.2", + "symfony/var-dumper": "^5.4.11" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.x-dev" + } + }, + "autoload": { + "psr-4": { + "Laravel\\SerializableClosure\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Taylor Otwell", + "email": "taylor@laravel.com" + }, + { + "name": "Nuno Maduro", + "email": "nuno@laravel.com" + } + ], + "description": "Laravel Serializable Closure provides an easy and secure way to serialize closures in PHP.", + "keywords": [ + "closure", + "laravel", + "serializable" + ], + "support": { + "issues": "https://github.com/laravel/serializable-closure/issues", + "source": "https://github.com/laravel/serializable-closure" + }, + "time": "2023-11-08T14:08:06+00:00" + }, + { + "name": "laravel/tinker", + "version": "v2.9.0", + "source": { + "type": "git", + "url": "https://github.com/laravel/tinker.git", + "reference": "502e0fe3f0415d06d5db1f83a472f0f3b754bafe" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/laravel/tinker/zipball/502e0fe3f0415d06d5db1f83a472f0f3b754bafe", + "reference": "502e0fe3f0415d06d5db1f83a472f0f3b754bafe", + "shasum": "" + }, + "require": { + "illuminate/console": "^6.0|^7.0|^8.0|^9.0|^10.0|^11.0", + "illuminate/contracts": "^6.0|^7.0|^8.0|^9.0|^10.0|^11.0", + "illuminate/support": "^6.0|^7.0|^8.0|^9.0|^10.0|^11.0", + "php": "^7.2.5|^8.0", + "psy/psysh": "^0.11.1|^0.12.0", + "symfony/var-dumper": "^4.3.4|^5.0|^6.0|^7.0" + }, + "require-dev": { + "mockery/mockery": "~1.3.3|^1.4.2", + "phpstan/phpstan": "^1.10", + "phpunit/phpunit": "^8.5.8|^9.3.3" + }, + "suggest": { + "illuminate/database": "The Illuminate Database package (^6.0|^7.0|^8.0|^9.0|^10.0|^11.0)." + }, + "type": "library", + "extra": { + "laravel": { + "providers": [ + "Laravel\\Tinker\\TinkerServiceProvider" + ] + } + }, + "autoload": { + "psr-4": { + "Laravel\\Tinker\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Taylor Otwell", + "email": "taylor@laravel.com" + } + ], + "description": "Powerful REPL for the Laravel framework.", + "keywords": [ + "REPL", + "Tinker", + "laravel", + "psysh" + ], + "support": { + "issues": "https://github.com/laravel/tinker/issues", + "source": "https://github.com/laravel/tinker/tree/v2.9.0" + }, + "time": "2024-01-04T16:10:04+00:00" + }, + { + "name": "laravel/ui", + "version": "v4.5.2", + "source": { + "type": "git", + "url": "https://github.com/laravel/ui.git", + "reference": "c75396f63268c95b053c8e4814eb70e0875e9628" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/laravel/ui/zipball/c75396f63268c95b053c8e4814eb70e0875e9628", + "reference": "c75396f63268c95b053c8e4814eb70e0875e9628", + "shasum": "" + }, + "require": { + "illuminate/console": "^9.21|^10.0|^11.0", + "illuminate/filesystem": "^9.21|^10.0|^11.0", + "illuminate/support": "^9.21|^10.0|^11.0", + "illuminate/validation": "^9.21|^10.0|^11.0", + "php": "^8.0", + "symfony/console": "^6.0|^7.0" + }, + "require-dev": { + "orchestra/testbench": "^7.35|^8.15|^9.0", + "phpunit/phpunit": "^9.3|^10.4|^11.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.x-dev" + }, + "laravel": { + "providers": [ + "Laravel\\Ui\\UiServiceProvider" + ] + } + }, + "autoload": { + "psr-4": { + "Laravel\\Ui\\": "src/", + "Illuminate\\Foundation\\Auth\\": "auth-backend/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Taylor Otwell", + "email": "taylor@laravel.com" + } + ], + "description": "Laravel UI utilities and presets.", + "keywords": [ + "laravel", + "ui" + ], + "support": { + "source": "https://github.com/laravel/ui/tree/v4.5.2" + }, + "time": "2024-05-08T18:07:10+00:00" + }, + { + "name": "laravelcollective/html", + "version": "v6.4.1", + "source": { + "type": "git", + "url": "https://github.com/LaravelCollective/html.git", + "reference": "64ddfdcaeeb8d332bd98bef442bef81e39c3910b" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/LaravelCollective/html/zipball/64ddfdcaeeb8d332bd98bef442bef81e39c3910b", + "reference": "64ddfdcaeeb8d332bd98bef442bef81e39c3910b", + "shasum": "" + }, + "require": { + "illuminate/http": "^6.0|^7.0|^8.0|^9.0|^10.0", + "illuminate/routing": "^6.0|^7.0|^8.0|^9.0|^10.0", + "illuminate/session": "^6.0|^7.0|^8.0|^9.0|^10.0", + "illuminate/support": "^6.0|^7.0|^8.0|^9.0|^10.0", + "illuminate/view": "^6.0|^7.0|^8.0|^9.0|^10.0", + "php": ">=7.2.5" + }, + "require-dev": { + "illuminate/database": "^6.0|^7.0|^8.0|^9.0|^10.0", + "mockery/mockery": "~1.0", + "phpunit/phpunit": "~8.5|^9.5.10" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "6.x-dev" + }, + "laravel": { + "providers": [ + "Collective\\Html\\HtmlServiceProvider" + ], + "aliases": { + "Form": "Collective\\Html\\FormFacade", + "Html": "Collective\\Html\\HtmlFacade" + } + } + }, + "autoload": { + "files": [ + "src/helpers.php" + ], + "psr-4": { + "Collective\\Html\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Adam Engebretson", + "email": "adam@laravelcollective.com" + }, + { + "name": "Taylor Otwell", + "email": "taylorotwell@gmail.com" + } + ], + "description": "HTML and Form Builders for the Laravel Framework", + "homepage": "https://laravelcollective.com", + "support": { + "issues": "https://github.com/LaravelCollective/html/issues", + "source": "https://github.com/LaravelCollective/html" + }, + "abandoned": "spatie/laravel-html", + "time": "2023-04-25T02:46:11+00:00" + }, + { + "name": "league/commonmark", + "version": "2.4.2", + "source": { + "type": "git", + "url": "https://github.com/thephpleague/commonmark.git", + "reference": "91c24291965bd6d7c46c46a12ba7492f83b1cadf" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/thephpleague/commonmark/zipball/91c24291965bd6d7c46c46a12ba7492f83b1cadf", + "reference": "91c24291965bd6d7c46c46a12ba7492f83b1cadf", + "shasum": "" + }, + "require": { + "ext-mbstring": "*", + "league/config": "^1.1.1", + "php": "^7.4 || ^8.0", + "psr/event-dispatcher": "^1.0", + "symfony/deprecation-contracts": "^2.1 || ^3.0", + "symfony/polyfill-php80": "^1.16" + }, + "require-dev": { + "cebe/markdown": "^1.0", + "commonmark/cmark": "0.30.3", + "commonmark/commonmark.js": "0.30.0", + "composer/package-versions-deprecated": "^1.8", + "embed/embed": "^4.4", + "erusev/parsedown": "^1.0", + "ext-json": "*", + "github/gfm": "0.29.0", + "michelf/php-markdown": "^1.4 || ^2.0", + "nyholm/psr7": "^1.5", + "phpstan/phpstan": "^1.8.2", + "phpunit/phpunit": "^9.5.21 || ^10.5.9 || ^11.0.0", + "scrutinizer/ocular": "^1.8.1", + "symfony/finder": "^5.3 | ^6.0 || ^7.0", + "symfony/yaml": "^2.3 | ^3.0 | ^4.0 | ^5.0 | ^6.0 || ^7.0", + "unleashedtech/php-coding-standard": "^3.1.1", + "vimeo/psalm": "^4.24.0 || ^5.0.0" + }, + "suggest": { + "symfony/yaml": "v2.3+ required if using the Front Matter extension" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "2.5-dev" + } + }, + "autoload": { + "psr-4": { + "League\\CommonMark\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Colin O'Dell", + "email": "colinodell@gmail.com", + "homepage": "https://www.colinodell.com", + "role": "Lead Developer" + } + ], + "description": "Highly-extensible PHP Markdown parser which fully supports the CommonMark spec and GitHub-Flavored Markdown (GFM)", + "homepage": "https://commonmark.thephpleague.com", + "keywords": [ + "commonmark", + "flavored", + "gfm", + "github", + "github-flavored", + "markdown", + "md", + "parser" + ], + "support": { + "docs": "https://commonmark.thephpleague.com/", + "forum": "https://github.com/thephpleague/commonmark/discussions", + "issues": "https://github.com/thephpleague/commonmark/issues", + "rss": "https://github.com/thephpleague/commonmark/releases.atom", + "source": "https://github.com/thephpleague/commonmark" + }, + "funding": [ + { + "url": "https://www.colinodell.com/sponsor", + "type": "custom" + }, + { + "url": "https://www.paypal.me/colinpodell/10.00", + "type": "custom" + }, + { + "url": "https://github.com/colinodell", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/league/commonmark", + "type": "tidelift" + } + ], + "time": "2024-02-02T11:59:32+00:00" + }, + { + "name": "league/config", + "version": "v1.2.0", + "source": { + "type": "git", + "url": "https://github.com/thephpleague/config.git", + "reference": "754b3604fb2984c71f4af4a9cbe7b57f346ec1f3" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/thephpleague/config/zipball/754b3604fb2984c71f4af4a9cbe7b57f346ec1f3", + "reference": "754b3604fb2984c71f4af4a9cbe7b57f346ec1f3", + "shasum": "" + }, + "require": { + "dflydev/dot-access-data": "^3.0.1", + "nette/schema": "^1.2", + "php": "^7.4 || ^8.0" + }, + "require-dev": { + "phpstan/phpstan": "^1.8.2", + "phpunit/phpunit": "^9.5.5", + "scrutinizer/ocular": "^1.8.1", + "unleashedtech/php-coding-standard": "^3.1", + "vimeo/psalm": "^4.7.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "1.2-dev" + } + }, + "autoload": { + "psr-4": { + "League\\Config\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Colin O'Dell", + "email": "colinodell@gmail.com", + "homepage": "https://www.colinodell.com", + "role": "Lead Developer" + } + ], + "description": "Define configuration arrays with strict schemas and access values with dot notation", + "homepage": "https://config.thephpleague.com", + "keywords": [ + "array", + "config", + "configuration", + "dot", + "dot-access", + "nested", + "schema" + ], + "support": { + "docs": "https://config.thephpleague.com/", + "issues": "https://github.com/thephpleague/config/issues", + "rss": "https://github.com/thephpleague/config/releases.atom", + "source": "https://github.com/thephpleague/config" + }, + "funding": [ + { + "url": "https://www.colinodell.com/sponsor", + "type": "custom" + }, + { + "url": "https://www.paypal.me/colinpodell/10.00", + "type": "custom" + }, + { + "url": "https://github.com/colinodell", + "type": "github" + } + ], + "time": "2022-12-11T20:36:23+00:00" + }, + { + "name": "league/flysystem", + "version": "3.28.0", + "source": { + "type": "git", + "url": "https://github.com/thephpleague/flysystem.git", + "reference": "e611adab2b1ae2e3072fa72d62c62f52c2bf1f0c" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/thephpleague/flysystem/zipball/e611adab2b1ae2e3072fa72d62c62f52c2bf1f0c", + "reference": "e611adab2b1ae2e3072fa72d62c62f52c2bf1f0c", + "shasum": "" + }, + "require": { + "league/flysystem-local": "^3.0.0", + "league/mime-type-detection": "^1.0.0", + "php": "^8.0.2" + }, + "conflict": { + "async-aws/core": "<1.19.0", + "async-aws/s3": "<1.14.0", + "aws/aws-sdk-php": "3.209.31 || 3.210.0", + "guzzlehttp/guzzle": "<7.0", + "guzzlehttp/ringphp": "<1.1.1", + "phpseclib/phpseclib": "3.0.15", + "symfony/http-client": "<5.2" + }, + "require-dev": { + "async-aws/s3": "^1.5 || ^2.0", + "async-aws/simple-s3": "^1.1 || ^2.0", + "aws/aws-sdk-php": "^3.295.10", + "composer/semver": "^3.0", + "ext-fileinfo": "*", + "ext-ftp": "*", + "ext-mongodb": "^1.3", + "ext-zip": "*", + "friendsofphp/php-cs-fixer": "^3.5", + "google/cloud-storage": "^1.23", + "guzzlehttp/psr7": "^2.6", + "microsoft/azure-storage-blob": "^1.1", + "mongodb/mongodb": "^1.2", + "phpseclib/phpseclib": "^3.0.36", + "phpstan/phpstan": "^1.10", + "phpunit/phpunit": "^9.5.11|^10.0", + "sabre/dav": "^4.6.0" + }, + "type": "library", + "autoload": { + "psr-4": { + "League\\Flysystem\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Frank de Jonge", + "email": "info@frankdejonge.nl" + } + ], + "description": "File storage abstraction for PHP", + "keywords": [ + "WebDAV", + "aws", + "cloud", + "file", + "files", + "filesystem", + "filesystems", + "ftp", + "s3", + "sftp", + "storage" + ], + "support": { + "issues": "https://github.com/thephpleague/flysystem/issues", + "source": "https://github.com/thephpleague/flysystem/tree/3.28.0" + }, + "time": "2024-05-22T10:09:12+00:00" + }, + { + "name": "league/flysystem-local", + "version": "3.28.0", + "source": { + "type": "git", + "url": "https://github.com/thephpleague/flysystem-local.git", + "reference": "13f22ea8be526ea58c2ddff9e158ef7c296e4f40" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/thephpleague/flysystem-local/zipball/13f22ea8be526ea58c2ddff9e158ef7c296e4f40", + "reference": "13f22ea8be526ea58c2ddff9e158ef7c296e4f40", + "shasum": "" + }, + "require": { + "ext-fileinfo": "*", + "league/flysystem": "^3.0.0", + "league/mime-type-detection": "^1.0.0", + "php": "^8.0.2" + }, + "type": "library", + "autoload": { + "psr-4": { + "League\\Flysystem\\Local\\": "" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Frank de Jonge", + "email": "info@frankdejonge.nl" + } + ], + "description": "Local filesystem adapter for Flysystem.", + "keywords": [ + "Flysystem", + "file", + "files", + "filesystem", + "local" + ], + "support": { + "source": "https://github.com/thephpleague/flysystem-local/tree/3.28.0" + }, + "time": "2024-05-06T20:05:52+00:00" + }, + { + "name": "league/fractal", + "version": "0.20.1", + "source": { + "type": "git", + "url": "https://github.com/thephpleague/fractal.git", + "reference": "8b9d39b67624db9195c06f9c1ffd0355151eaf62" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/thephpleague/fractal/zipball/8b9d39b67624db9195c06f9c1ffd0355151eaf62", + "reference": "8b9d39b67624db9195c06f9c1ffd0355151eaf62", + "shasum": "" + }, + "require": { + "php": ">=7.4" + }, + "require-dev": { + "doctrine/orm": "^2.5", + "illuminate/contracts": "~5.0", + "mockery/mockery": "^1.3", + "pagerfanta/pagerfanta": "~1.0.0", + "phpstan/phpstan": "^1.4", + "phpunit/phpunit": "^9.5", + "squizlabs/php_codesniffer": "~3.4", + "vimeo/psalm": "^4.22", + "zendframework/zend-paginator": "~2.3" + }, + "suggest": { + "illuminate/pagination": "The Illuminate Pagination component.", + "pagerfanta/pagerfanta": "Pagerfanta Paginator", + "zendframework/zend-paginator": "Zend Framework Paginator" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "0.20.x-dev" + } + }, + "autoload": { + "psr-4": { + "League\\Fractal\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Phil Sturgeon", + "email": "me@philsturgeon.uk", + "homepage": "http://philsturgeon.uk/", + "role": "Developer" + } + ], + "description": "Handle the output of complex data structures ready for API output.", + "homepage": "http://fractal.thephpleague.com/", + "keywords": [ + "api", + "json", + "league", + "rest" + ], + "support": { + "issues": "https://github.com/thephpleague/fractal/issues", + "source": "https://github.com/thephpleague/fractal/tree/0.20.1" + }, + "time": "2022-04-11T12:47:17+00:00" + }, + { + "name": "league/mime-type-detection", + "version": "1.15.0", + "source": { + "type": "git", + "url": "https://github.com/thephpleague/mime-type-detection.git", + "reference": "ce0f4d1e8a6f4eb0ddff33f57c69c50fd09f4301" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/thephpleague/mime-type-detection/zipball/ce0f4d1e8a6f4eb0ddff33f57c69c50fd09f4301", + "reference": "ce0f4d1e8a6f4eb0ddff33f57c69c50fd09f4301", + "shasum": "" + }, + "require": { + "ext-fileinfo": "*", + "php": "^7.4 || ^8.0" + }, + "require-dev": { + "friendsofphp/php-cs-fixer": "^3.2", + "phpstan/phpstan": "^0.12.68", + "phpunit/phpunit": "^8.5.8 || ^9.3 || ^10.0" + }, + "type": "library", + "autoload": { + "psr-4": { + "League\\MimeTypeDetection\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Frank de Jonge", + "email": "info@frankdejonge.nl" + } + ], + "description": "Mime-type detection for Flysystem", + "support": { + "issues": "https://github.com/thephpleague/mime-type-detection/issues", + "source": "https://github.com/thephpleague/mime-type-detection/tree/1.15.0" + }, + "funding": [ + { + "url": "https://github.com/frankdejonge", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/league/flysystem", + "type": "tidelift" + } + ], + "time": "2024-01-28T23:22:08+00:00" + }, + { + "name": "monolog/monolog", + "version": "2.9.3", + "source": { + "type": "git", + "url": "https://github.com/Seldaek/monolog.git", + "reference": "a30bfe2e142720dfa990d0a7e573997f5d884215" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/Seldaek/monolog/zipball/a30bfe2e142720dfa990d0a7e573997f5d884215", + "reference": "a30bfe2e142720dfa990d0a7e573997f5d884215", + "shasum": "" + }, + "require": { + "php": ">=7.2", + "psr/log": "^1.0.1 || ^2.0 || ^3.0" + }, + "provide": { + "psr/log-implementation": "1.0.0 || 2.0.0 || 3.0.0" + }, + "require-dev": { + "aws/aws-sdk-php": "^2.4.9 || ^3.0", + "doctrine/couchdb": "~1.0@dev", + "elasticsearch/elasticsearch": "^7 || ^8", + "ext-json": "*", + "graylog2/gelf-php": "^1.4.2 || ^2@dev", + "guzzlehttp/guzzle": "^7.4", + "guzzlehttp/psr7": "^2.2", + "mongodb/mongodb": "^1.8", + "php-amqplib/php-amqplib": "~2.4 || ^3", + "phpspec/prophecy": "^1.15", + "phpstan/phpstan": "^1.10", + "phpunit/phpunit": "^8.5.38 || ^9.6.19", + "predis/predis": "^1.1 || ^2.0", + "rollbar/rollbar": "^1.3 || ^2 || ^3", + "ruflin/elastica": "^7", + "swiftmailer/swiftmailer": "^5.3|^6.0", + "symfony/mailer": "^5.4 || ^6", + "symfony/mime": "^5.4 || ^6" + }, + "suggest": { + "aws/aws-sdk-php": "Allow sending log messages to AWS services like DynamoDB", + "doctrine/couchdb": "Allow sending log messages to a CouchDB server", + "elasticsearch/elasticsearch": "Allow sending log messages to an Elasticsearch server via official client", + "ext-amqp": "Allow sending log messages to an AMQP server (1.0+ required)", + "ext-curl": "Required to send log messages using the IFTTTHandler, the LogglyHandler, the SendGridHandler, the SlackWebhookHandler or the TelegramBotHandler", + "ext-mbstring": "Allow to work properly with unicode symbols", + "ext-mongodb": "Allow sending log messages to a MongoDB server (via driver)", + "ext-openssl": "Required to send log messages using SSL", + "ext-sockets": "Allow sending log messages to a Syslog server (via UDP driver)", + "graylog2/gelf-php": "Allow sending log messages to a GrayLog2 server", + "mongodb/mongodb": "Allow sending log messages to a MongoDB server (via library)", + "php-amqplib/php-amqplib": "Allow sending log messages to an AMQP server using php-amqplib", + "rollbar/rollbar": "Allow sending log messages to Rollbar", + "ruflin/elastica": "Allow sending log messages to an Elastic Search server" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "2.x-dev" + } + }, + "autoload": { + "psr-4": { + "Monolog\\": "src/Monolog" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Jordi Boggiano", + "email": "j.boggiano@seld.be", + "homepage": "https://seld.be" + } + ], + "description": "Sends your logs to files, sockets, inboxes, databases and various web services", + "homepage": "https://github.com/Seldaek/monolog", + "keywords": [ + "log", + "logging", + "psr-3" + ], + "support": { + "issues": "https://github.com/Seldaek/monolog/issues", + "source": "https://github.com/Seldaek/monolog/tree/2.9.3" + }, + "funding": [ + { + "url": "https://github.com/Seldaek", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/monolog/monolog", + "type": "tidelift" + } + ], + "time": "2024-04-12T20:52:51+00:00" + }, + { + "name": "nesbot/carbon", + "version": "2.72.5", + "source": { + "type": "git", + "url": "https://github.com/briannesbitt/Carbon.git", + "reference": "afd46589c216118ecd48ff2b95d77596af1e57ed" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/briannesbitt/Carbon/zipball/afd46589c216118ecd48ff2b95d77596af1e57ed", + "reference": "afd46589c216118ecd48ff2b95d77596af1e57ed", + "shasum": "" + }, + "require": { + "carbonphp/carbon-doctrine-types": "*", + "ext-json": "*", + "php": "^7.1.8 || ^8.0", + "psr/clock": "^1.0", + "symfony/polyfill-mbstring": "^1.0", + "symfony/polyfill-php80": "^1.16", + "symfony/translation": "^3.4 || ^4.0 || ^5.0 || ^6.0" + }, + "provide": { + "psr/clock-implementation": "1.0" + }, + "require-dev": { + "doctrine/dbal": "^2.0 || ^3.1.4 || ^4.0", + "doctrine/orm": "^2.7 || ^3.0", + "friendsofphp/php-cs-fixer": "^3.0", + "kylekatarnls/multi-tester": "^2.0", + "ondrejmirtes/better-reflection": "*", + "phpmd/phpmd": "^2.9", + "phpstan/extension-installer": "^1.0", + "phpstan/phpstan": "^0.12.99 || ^1.7.14", + "phpunit/php-file-iterator": "^2.0.5 || ^3.0.6", + "phpunit/phpunit": "^7.5.20 || ^8.5.26 || ^9.5.20", + "squizlabs/php_codesniffer": "^3.4" + }, + "bin": [ + "bin/carbon" + ], + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "3.x-dev", + "dev-2.x": "2.x-dev" + }, + "laravel": { + "providers": [ + "Carbon\\Laravel\\ServiceProvider" + ] + }, + "phpstan": { + "includes": [ + "extension.neon" + ] + } + }, + "autoload": { + "psr-4": { + "Carbon\\": "src/Carbon/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Brian Nesbitt", + "email": "brian@nesbot.com", + "homepage": "https://markido.com" + }, + { + "name": "kylekatarnls", + "homepage": "https://github.com/kylekatarnls" + } + ], + "description": "An API extension for DateTime that supports 281 different languages.", + "homepage": "https://carbon.nesbot.com", + "keywords": [ + "date", + "datetime", + "time" + ], + "support": { + "docs": "https://carbon.nesbot.com/docs", + "issues": "https://github.com/briannesbitt/Carbon/issues", + "source": "https://github.com/briannesbitt/Carbon" + }, + "funding": [ + { + "url": "https://github.com/sponsors/kylekatarnls", + "type": "github" + }, + { + "url": "https://opencollective.com/Carbon#sponsor", + "type": "opencollective" + }, + { + "url": "https://tidelift.com/subscription/pkg/packagist-nesbot-carbon?utm_source=packagist-nesbot-carbon&utm_medium=referral&utm_campaign=readme", + "type": "tidelift" + } + ], + "time": "2024-06-03T19:18:41+00:00" + }, + { + "name": "nette/schema", + "version": "v1.3.0", + "source": { + "type": "git", + "url": "https://github.com/nette/schema.git", + "reference": "a6d3a6d1f545f01ef38e60f375d1cf1f4de98188" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/nette/schema/zipball/a6d3a6d1f545f01ef38e60f375d1cf1f4de98188", + "reference": "a6d3a6d1f545f01ef38e60f375d1cf1f4de98188", + "shasum": "" + }, + "require": { + "nette/utils": "^4.0", + "php": "8.1 - 8.3" + }, + "require-dev": { + "nette/tester": "^2.4", + "phpstan/phpstan-nette": "^1.0", + "tracy/tracy": "^2.8" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.3-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause", + "GPL-2.0-only", + "GPL-3.0-only" + ], + "authors": [ + { + "name": "David Grudl", + "homepage": "https://davidgrudl.com" + }, + { + "name": "Nette Community", + "homepage": "https://nette.org/contributors" + } + ], + "description": "📐 Nette Schema: validating data structures against a given Schema.", + "homepage": "https://nette.org", + "keywords": [ + "config", + "nette" + ], + "support": { + "issues": "https://github.com/nette/schema/issues", + "source": "https://github.com/nette/schema/tree/v1.3.0" + }, + "time": "2023-12-11T11:54:22+00:00" + }, + { + "name": "nette/utils", + "version": "v4.0.4", + "source": { + "type": "git", + "url": "https://github.com/nette/utils.git", + "reference": "d3ad0aa3b9f934602cb3e3902ebccf10be34d218" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/nette/utils/zipball/d3ad0aa3b9f934602cb3e3902ebccf10be34d218", + "reference": "d3ad0aa3b9f934602cb3e3902ebccf10be34d218", + "shasum": "" + }, + "require": { + "php": ">=8.0 <8.4" + }, + "conflict": { + "nette/finder": "<3", + "nette/schema": "<1.2.2" + }, + "require-dev": { + "jetbrains/phpstorm-attributes": "dev-master", + "nette/tester": "^2.5", + "phpstan/phpstan": "^1.0", + "tracy/tracy": "^2.9" + }, + "suggest": { + "ext-gd": "to use Image", + "ext-iconv": "to use Strings::webalize(), toAscii(), chr() and reverse()", + "ext-intl": "to use Strings::webalize(), toAscii(), normalize() and compare()", + "ext-json": "to use Nette\\Utils\\Json", + "ext-mbstring": "to use Strings::lower() etc...", + "ext-tokenizer": "to use Nette\\Utils\\Reflection::getUseStatements()" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause", + "GPL-2.0-only", + "GPL-3.0-only" + ], + "authors": [ + { + "name": "David Grudl", + "homepage": "https://davidgrudl.com" + }, + { + "name": "Nette Community", + "homepage": "https://nette.org/contributors" + } + ], + "description": "🛠 Nette Utils: lightweight utilities for string & array manipulation, image handling, safe JSON encoding/decoding, validation, slug or strong password generating etc.", + "homepage": "https://nette.org", + "keywords": [ + "array", + "core", + "datetime", + "images", + "json", + "nette", + "paginator", + "password", + "slugify", + "string", + "unicode", + "utf-8", + "utility", + "validation" + ], + "support": { + "issues": "https://github.com/nette/utils/issues", + "source": "https://github.com/nette/utils/tree/v4.0.4" + }, + "time": "2024-01-17T16:50:36+00:00" + }, + { + "name": "nikic/php-parser", + "version": "v5.1.0", + "source": { + "type": "git", + "url": "https://github.com/nikic/PHP-Parser.git", + "reference": "683130c2ff8c2739f4822ff7ac5c873ec529abd1" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/683130c2ff8c2739f4822ff7ac5c873ec529abd1", + "reference": "683130c2ff8c2739f4822ff7ac5c873ec529abd1", + "shasum": "" + }, + "require": { + "ext-ctype": "*", + "ext-json": "*", + "ext-tokenizer": "*", + "php": ">=7.4" + }, + "require-dev": { + "ircmaxell/php-yacc": "^0.0.7", + "phpunit/phpunit": "^9.0" + }, + "bin": [ + "bin/php-parse" + ], + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "5.0-dev" + } + }, + "autoload": { + "psr-4": { + "PhpParser\\": "lib/PhpParser" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Nikita Popov" + } + ], + "description": "A PHP parser written in PHP", + "keywords": [ + "parser", + "php" + ], + "support": { + "issues": "https://github.com/nikic/PHP-Parser/issues", + "source": "https://github.com/nikic/PHP-Parser/tree/v5.1.0" + }, + "time": "2024-07-01T20:03:41+00:00" + }, + { + "name": "nunomaduro/termwind", + "version": "v1.15.1", + "source": { + "type": "git", + "url": "https://github.com/nunomaduro/termwind.git", + "reference": "8ab0b32c8caa4a2e09700ea32925441385e4a5dc" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/nunomaduro/termwind/zipball/8ab0b32c8caa4a2e09700ea32925441385e4a5dc", + "reference": "8ab0b32c8caa4a2e09700ea32925441385e4a5dc", + "shasum": "" + }, + "require": { + "ext-mbstring": "*", + "php": "^8.0", + "symfony/console": "^5.3.0|^6.0.0" + }, + "require-dev": { + "ergebnis/phpstan-rules": "^1.0.", + "illuminate/console": "^8.0|^9.0", + "illuminate/support": "^8.0|^9.0", + "laravel/pint": "^1.0.0", + "pestphp/pest": "^1.21.0", + "pestphp/pest-plugin-mock": "^1.0", + "phpstan/phpstan": "^1.4.6", + "phpstan/phpstan-strict-rules": "^1.1.0", + "symfony/var-dumper": "^5.2.7|^6.0.0", + "thecodingmachine/phpstan-strict-rules": "^1.0.0" + }, + "type": "library", + "extra": { + "laravel": { + "providers": [ + "Termwind\\Laravel\\TermwindServiceProvider" + ] + } + }, + "autoload": { + "files": [ + "src/Functions.php" + ], + "psr-4": { + "Termwind\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nuno Maduro", + "email": "enunomaduro@gmail.com" + } + ], + "description": "Its like Tailwind CSS, but for the console.", + "keywords": [ + "cli", + "console", + "css", + "package", + "php", + "style" + ], + "support": { + "issues": "https://github.com/nunomaduro/termwind/issues", + "source": "https://github.com/nunomaduro/termwind/tree/v1.15.1" + }, + "funding": [ + { + "url": "https://www.paypal.com/paypalme/enunomaduro", + "type": "custom" + }, + { + "url": "https://github.com/nunomaduro", + "type": "github" + }, + { + "url": "https://github.com/xiCO2k", + "type": "github" + } + ], + "time": "2023-02-08T01:06:31+00:00" + }, + { + "name": "paragonie/random_compat", + "version": "v9.99.100", + "source": { + "type": "git", + "url": "https://github.com/paragonie/random_compat.git", + "reference": "996434e5492cb4c3edcb9168db6fbb1359ef965a" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/paragonie/random_compat/zipball/996434e5492cb4c3edcb9168db6fbb1359ef965a", + "reference": "996434e5492cb4c3edcb9168db6fbb1359ef965a", + "shasum": "" + }, + "require": { + "php": ">= 7" + }, + "require-dev": { + "phpunit/phpunit": "4.*|5.*", + "vimeo/psalm": "^1" + }, + "suggest": { + "ext-libsodium": "Provides a modern crypto API that can be used to generate random bytes." + }, + "type": "library", + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Paragon Initiative Enterprises", + "email": "security@paragonie.com", + "homepage": "https://paragonie.com" + } + ], + "description": "PHP 5.x polyfill for random_bytes() and random_int() from PHP 7", + "keywords": [ + "csprng", + "polyfill", + "pseudorandom", + "random" + ], + "support": { + "email": "info@paragonie.com", + "issues": "https://github.com/paragonie/random_compat/issues", + "source": "https://github.com/paragonie/random_compat" + }, + "time": "2020-10-15T08:29:30+00:00" + }, + { + "name": "phenx/php-font-lib", + "version": "0.5.6", + "source": { + "type": "git", + "url": "https://github.com/dompdf/php-font-lib.git", + "reference": "a1681e9793040740a405ac5b189275059e2a9863" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/dompdf/php-font-lib/zipball/a1681e9793040740a405ac5b189275059e2a9863", + "reference": "a1681e9793040740a405ac5b189275059e2a9863", + "shasum": "" + }, + "require": { + "ext-mbstring": "*" + }, + "require-dev": { + "symfony/phpunit-bridge": "^3 || ^4 || ^5 || ^6" + }, + "type": "library", + "autoload": { + "psr-4": { + "FontLib\\": "src/FontLib" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "LGPL-2.1-or-later" + ], + "authors": [ + { + "name": "Fabien Ménager", + "email": "fabien.menager@gmail.com" + } + ], + "description": "A library to read, parse, export and make subsets of different types of font files.", + "homepage": "https://github.com/PhenX/php-font-lib", + "support": { + "issues": "https://github.com/dompdf/php-font-lib/issues", + "source": "https://github.com/dompdf/php-font-lib/tree/0.5.6" + }, + "time": "2024-01-29T14:45:26+00:00" + }, + { + "name": "phenx/php-svg-lib", + "version": "0.4.1", + "source": { + "type": "git", + "url": "https://github.com/dompdf/php-svg-lib.git", + "reference": "4498b5df7b08e8469f0f8279651ea5de9626ed02" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/dompdf/php-svg-lib/zipball/4498b5df7b08e8469f0f8279651ea5de9626ed02", + "reference": "4498b5df7b08e8469f0f8279651ea5de9626ed02", + "shasum": "" + }, + "require": { + "ext-mbstring": "*", + "php": "^7.1 || ^7.2 || ^7.3 || ^7.4 || ^8.0", + "sabberworm/php-css-parser": "^8.4" + }, + "require-dev": { + "phpunit/phpunit": "^7.5 || ^8.5 || ^9.5" + }, + "type": "library", + "autoload": { + "psr-4": { + "Svg\\": "src/Svg" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "LGPL-3.0" + ], + "authors": [ + { + "name": "Fabien Ménager", + "email": "fabien.menager@gmail.com" + } + ], + "description": "A library to read, parse and export to PDF SVG files.", + "homepage": "https://github.com/PhenX/php-svg-lib", + "support": { + "issues": "https://github.com/dompdf/php-svg-lib/issues", + "source": "https://github.com/dompdf/php-svg-lib/tree/0.4.1" + }, + "time": "2022-03-07T12:52:04+00:00" + }, + { + "name": "phpoption/phpoption", + "version": "1.9.2", + "source": { + "type": "git", + "url": "https://github.com/schmittjoh/php-option.git", + "reference": "80735db690fe4fc5c76dfa7f9b770634285fa820" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/schmittjoh/php-option/zipball/80735db690fe4fc5c76dfa7f9b770634285fa820", + "reference": "80735db690fe4fc5c76dfa7f9b770634285fa820", + "shasum": "" + }, + "require": { + "php": "^7.2.5 || ^8.0" + }, + "require-dev": { + "bamarni/composer-bin-plugin": "^1.8.2", + "phpunit/phpunit": "^8.5.34 || ^9.6.13 || ^10.4.2" + }, + "type": "library", + "extra": { + "bamarni-bin": { + "bin-links": true, + "forward-command": true + }, + "branch-alias": { + "dev-master": "1.9-dev" + } + }, + "autoload": { + "psr-4": { + "PhpOption\\": "src/PhpOption/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "Apache-2.0" + ], + "authors": [ + { + "name": "Johannes M. Schmitt", + "email": "schmittjoh@gmail.com", + "homepage": "https://github.com/schmittjoh" + }, + { + "name": "Graham Campbell", + "email": "hello@gjcampbell.co.uk", + "homepage": "https://github.com/GrahamCampbell" + } + ], + "description": "Option Type for PHP", + "keywords": [ + "language", + "option", + "php", + "type" + ], + "support": { + "issues": "https://github.com/schmittjoh/php-option/issues", + "source": "https://github.com/schmittjoh/php-option/tree/1.9.2" + }, + "funding": [ + { + "url": "https://github.com/GrahamCampbell", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/phpoption/phpoption", + "type": "tidelift" + } + ], + "time": "2023-11-12T21:59:55+00:00" + }, + { + "name": "psr/clock", + "version": "1.0.0", + "source": { + "type": "git", + "url": "https://github.com/php-fig/clock.git", + "reference": "e41a24703d4560fd0acb709162f73b8adfc3aa0d" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/php-fig/clock/zipball/e41a24703d4560fd0acb709162f73b8adfc3aa0d", + "reference": "e41a24703d4560fd0acb709162f73b8adfc3aa0d", + "shasum": "" + }, + "require": { + "php": "^7.0 || ^8.0" + }, + "type": "library", + "autoload": { + "psr-4": { + "Psr\\Clock\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "PHP-FIG", + "homepage": "https://www.php-fig.org/" + } + ], + "description": "Common interface for reading the clock.", + "homepage": "https://github.com/php-fig/clock", + "keywords": [ + "clock", + "now", + "psr", + "psr-20", + "time" + ], + "support": { + "issues": "https://github.com/php-fig/clock/issues", + "source": "https://github.com/php-fig/clock/tree/1.0.0" + }, + "time": "2022-11-25T14:36:26+00:00" + }, + { + "name": "psr/container", + "version": "2.0.2", + "source": { + "type": "git", + "url": "https://github.com/php-fig/container.git", + "reference": "c71ecc56dfe541dbd90c5360474fbc405f8d5963" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/php-fig/container/zipball/c71ecc56dfe541dbd90c5360474fbc405f8d5963", + "reference": "c71ecc56dfe541dbd90c5360474fbc405f8d5963", + "shasum": "" + }, + "require": { + "php": ">=7.4.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.0.x-dev" + } + }, + "autoload": { + "psr-4": { + "Psr\\Container\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "PHP-FIG", + "homepage": "https://www.php-fig.org/" + } + ], + "description": "Common Container Interface (PHP FIG PSR-11)", + "homepage": "https://github.com/php-fig/container", + "keywords": [ + "PSR-11", + "container", + "container-interface", + "container-interop", + "psr" + ], + "support": { + "issues": "https://github.com/php-fig/container/issues", + "source": "https://github.com/php-fig/container/tree/2.0.2" + }, + "time": "2021-11-05T16:47:00+00:00" + }, + { + "name": "psr/event-dispatcher", + "version": "1.0.0", + "source": { + "type": "git", + "url": "https://github.com/php-fig/event-dispatcher.git", + "reference": "dbefd12671e8a14ec7f180cab83036ed26714bb0" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/php-fig/event-dispatcher/zipball/dbefd12671e8a14ec7f180cab83036ed26714bb0", + "reference": "dbefd12671e8a14ec7f180cab83036ed26714bb0", + "shasum": "" + }, + "require": { + "php": ">=7.2.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0.x-dev" + } + }, + "autoload": { + "psr-4": { + "Psr\\EventDispatcher\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "PHP-FIG", + "homepage": "http://www.php-fig.org/" + } + ], + "description": "Standard interfaces for event handling.", + "keywords": [ + "events", + "psr", + "psr-14" + ], + "support": { + "issues": "https://github.com/php-fig/event-dispatcher/issues", + "source": "https://github.com/php-fig/event-dispatcher/tree/1.0.0" + }, + "time": "2019-01-08T18:20:26+00:00" + }, + { + "name": "psr/http-client", + "version": "1.0.3", + "source": { + "type": "git", + "url": "https://github.com/php-fig/http-client.git", + "reference": "bb5906edc1c324c9a05aa0873d40117941e5fa90" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/php-fig/http-client/zipball/bb5906edc1c324c9a05aa0873d40117941e5fa90", + "reference": "bb5906edc1c324c9a05aa0873d40117941e5fa90", + "shasum": "" + }, + "require": { + "php": "^7.0 || ^8.0", + "psr/http-message": "^1.0 || ^2.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0.x-dev" + } + }, + "autoload": { + "psr-4": { + "Psr\\Http\\Client\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "PHP-FIG", + "homepage": "https://www.php-fig.org/" + } + ], + "description": "Common interface for HTTP clients", + "homepage": "https://github.com/php-fig/http-client", + "keywords": [ + "http", + "http-client", + "psr", + "psr-18" + ], + "support": { + "source": "https://github.com/php-fig/http-client" + }, + "time": "2023-09-23T14:17:50+00:00" + }, + { + "name": "psr/http-factory", + "version": "1.1.0", + "source": { + "type": "git", + "url": "https://github.com/php-fig/http-factory.git", + "reference": "2b4765fddfe3b508ac62f829e852b1501d3f6e8a" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/php-fig/http-factory/zipball/2b4765fddfe3b508ac62f829e852b1501d3f6e8a", + "reference": "2b4765fddfe3b508ac62f829e852b1501d3f6e8a", + "shasum": "" + }, + "require": { + "php": ">=7.1", + "psr/http-message": "^1.0 || ^2.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0.x-dev" + } + }, + "autoload": { + "psr-4": { + "Psr\\Http\\Message\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "PHP-FIG", + "homepage": "https://www.php-fig.org/" + } + ], + "description": "PSR-17: Common interfaces for PSR-7 HTTP message factories", + "keywords": [ + "factory", + "http", + "message", + "psr", + "psr-17", + "psr-7", + "request", + "response" + ], + "support": { + "source": "https://github.com/php-fig/http-factory" + }, + "time": "2024-04-15T12:06:14+00:00" + }, + { + "name": "psr/http-message", + "version": "2.0", + "source": { + "type": "git", + "url": "https://github.com/php-fig/http-message.git", + "reference": "402d35bcb92c70c026d1a6a9883f06b2ead23d71" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/php-fig/http-message/zipball/402d35bcb92c70c026d1a6a9883f06b2ead23d71", + "reference": "402d35bcb92c70c026d1a6a9883f06b2ead23d71", + "shasum": "" + }, + "require": { + "php": "^7.2 || ^8.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.0.x-dev" + } + }, + "autoload": { + "psr-4": { + "Psr\\Http\\Message\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "PHP-FIG", + "homepage": "https://www.php-fig.org/" + } + ], + "description": "Common interface for HTTP messages", + "homepage": "https://github.com/php-fig/http-message", + "keywords": [ + "http", + "http-message", + "psr", + "psr-7", + "request", + "response" + ], + "support": { + "source": "https://github.com/php-fig/http-message/tree/2.0" + }, + "time": "2023-04-04T09:54:51+00:00" + }, + { + "name": "psr/log", + "version": "3.0.0", + "source": { + "type": "git", + "url": "https://github.com/php-fig/log.git", + "reference": "fe5ea303b0887d5caefd3d431c3e61ad47037001" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/php-fig/log/zipball/fe5ea303b0887d5caefd3d431c3e61ad47037001", + "reference": "fe5ea303b0887d5caefd3d431c3e61ad47037001", + "shasum": "" + }, + "require": { + "php": ">=8.0.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "3.x-dev" + } + }, + "autoload": { + "psr-4": { + "Psr\\Log\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "PHP-FIG", + "homepage": "https://www.php-fig.org/" + } + ], + "description": "Common interface for logging libraries", + "homepage": "https://github.com/php-fig/log", + "keywords": [ + "log", + "psr", + "psr-3" + ], + "support": { + "source": "https://github.com/php-fig/log/tree/3.0.0" + }, + "time": "2021-07-14T16:46:02+00:00" + }, + { + "name": "psr/simple-cache", + "version": "3.0.0", + "source": { + "type": "git", + "url": "https://github.com/php-fig/simple-cache.git", + "reference": "764e0b3939f5ca87cb904f570ef9be2d78a07865" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/php-fig/simple-cache/zipball/764e0b3939f5ca87cb904f570ef9be2d78a07865", + "reference": "764e0b3939f5ca87cb904f570ef9be2d78a07865", + "shasum": "" + }, + "require": { + "php": ">=8.0.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "3.0.x-dev" + } + }, + "autoload": { + "psr-4": { + "Psr\\SimpleCache\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "PHP-FIG", + "homepage": "https://www.php-fig.org/" + } + ], + "description": "Common interfaces for simple caching", + "keywords": [ + "cache", + "caching", + "psr", + "psr-16", + "simple-cache" + ], + "support": { + "source": "https://github.com/php-fig/simple-cache/tree/3.0.0" + }, + "time": "2021-10-29T13:26:27+00:00" + }, + { + "name": "psy/psysh", + "version": "v0.12.4", + "source": { + "type": "git", + "url": "https://github.com/bobthecow/psysh.git", + "reference": "2fd717afa05341b4f8152547f142cd2f130f6818" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/bobthecow/psysh/zipball/2fd717afa05341b4f8152547f142cd2f130f6818", + "reference": "2fd717afa05341b4f8152547f142cd2f130f6818", + "shasum": "" + }, + "require": { + "ext-json": "*", + "ext-tokenizer": "*", + "nikic/php-parser": "^5.0 || ^4.0", + "php": "^8.0 || ^7.4", + "symfony/console": "^7.0 || ^6.0 || ^5.0 || ^4.0 || ^3.4", + "symfony/var-dumper": "^7.0 || ^6.0 || ^5.0 || ^4.0 || ^3.4" + }, + "conflict": { + "symfony/console": "4.4.37 || 5.3.14 || 5.3.15 || 5.4.3 || 5.4.4 || 6.0.3 || 6.0.4" + }, + "require-dev": { + "bamarni/composer-bin-plugin": "^1.2" + }, + "suggest": { + "ext-pcntl": "Enabling the PCNTL extension makes PsySH a lot happier :)", + "ext-pdo-sqlite": "The doc command requires SQLite to work.", + "ext-posix": "If you have PCNTL, you'll want the POSIX extension as well." + }, + "bin": [ + "bin/psysh" + ], + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "0.12.x-dev" + }, + "bamarni-bin": { + "bin-links": false, + "forward-command": false + } + }, + "autoload": { + "files": [ + "src/functions.php" + ], + "psr-4": { + "Psy\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Justin Hileman", + "email": "justin@justinhileman.info", + "homepage": "http://justinhileman.com" + } + ], + "description": "An interactive shell for modern PHP.", + "homepage": "http://psysh.org", + "keywords": [ + "REPL", + "console", + "interactive", + "shell" + ], + "support": { + "issues": "https://github.com/bobthecow/psysh/issues", + "source": "https://github.com/bobthecow/psysh/tree/v0.12.4" + }, + "time": "2024-06-10T01:18:23+00:00" + }, + { + "name": "ralouphie/getallheaders", + "version": "3.0.3", + "source": { + "type": "git", + "url": "https://github.com/ralouphie/getallheaders.git", + "reference": "120b605dfeb996808c31b6477290a714d356e822" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/ralouphie/getallheaders/zipball/120b605dfeb996808c31b6477290a714d356e822", + "reference": "120b605dfeb996808c31b6477290a714d356e822", + "shasum": "" + }, + "require": { + "php": ">=5.6" + }, + "require-dev": { + "php-coveralls/php-coveralls": "^2.1", + "phpunit/phpunit": "^5 || ^6.5" + }, + "type": "library", + "autoload": { + "files": [ + "src/getallheaders.php" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Ralph Khattar", + "email": "ralph.khattar@gmail.com" + } + ], + "description": "A polyfill for getallheaders.", + "support": { + "issues": "https://github.com/ralouphie/getallheaders/issues", + "source": "https://github.com/ralouphie/getallheaders/tree/develop" + }, + "time": "2019-03-08T08:55:37+00:00" + }, + { + "name": "ramsey/collection", + "version": "2.0.0", + "source": { + "type": "git", + "url": "https://github.com/ramsey/collection.git", + "reference": "a4b48764bfbb8f3a6a4d1aeb1a35bb5e9ecac4a5" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/ramsey/collection/zipball/a4b48764bfbb8f3a6a4d1aeb1a35bb5e9ecac4a5", + "reference": "a4b48764bfbb8f3a6a4d1aeb1a35bb5e9ecac4a5", + "shasum": "" + }, + "require": { + "php": "^8.1" + }, + "require-dev": { + "captainhook/plugin-composer": "^5.3", + "ergebnis/composer-normalize": "^2.28.3", + "fakerphp/faker": "^1.21", + "hamcrest/hamcrest-php": "^2.0", + "jangregor/phpstan-prophecy": "^1.0", + "mockery/mockery": "^1.5", + "php-parallel-lint/php-console-highlighter": "^1.0", + "php-parallel-lint/php-parallel-lint": "^1.3", + "phpcsstandards/phpcsutils": "^1.0.0-rc1", + "phpspec/prophecy-phpunit": "^2.0", + "phpstan/extension-installer": "^1.2", + "phpstan/phpstan": "^1.9", + "phpstan/phpstan-mockery": "^1.1", + "phpstan/phpstan-phpunit": "^1.3", + "phpunit/phpunit": "^9.5", + "psalm/plugin-mockery": "^1.1", + "psalm/plugin-phpunit": "^0.18.4", + "ramsey/coding-standard": "^2.0.3", + "ramsey/conventional-commits": "^1.3", + "vimeo/psalm": "^5.4" + }, + "type": "library", + "extra": { + "captainhook": { + "force-install": true + }, + "ramsey/conventional-commits": { + "configFile": "conventional-commits.json" + } + }, + "autoload": { + "psr-4": { + "Ramsey\\Collection\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Ben Ramsey", + "email": "ben@benramsey.com", + "homepage": "https://benramsey.com" + } + ], + "description": "A PHP library for representing and manipulating collections.", + "keywords": [ + "array", + "collection", + "hash", + "map", + "queue", + "set" + ], + "support": { + "issues": "https://github.com/ramsey/collection/issues", + "source": "https://github.com/ramsey/collection/tree/2.0.0" + }, + "funding": [ + { + "url": "https://github.com/ramsey", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/ramsey/collection", + "type": "tidelift" + } + ], + "time": "2022-12-31T21:50:55+00:00" + }, + { + "name": "ramsey/uuid", + "version": "4.7.6", + "source": { + "type": "git", + "url": "https://github.com/ramsey/uuid.git", + "reference": "91039bc1faa45ba123c4328958e620d382ec7088" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/ramsey/uuid/zipball/91039bc1faa45ba123c4328958e620d382ec7088", + "reference": "91039bc1faa45ba123c4328958e620d382ec7088", + "shasum": "" + }, + "require": { + "brick/math": "^0.8.8 || ^0.9 || ^0.10 || ^0.11 || ^0.12", + "ext-json": "*", + "php": "^8.0", + "ramsey/collection": "^1.2 || ^2.0" + }, + "replace": { + "rhumsaa/uuid": "self.version" + }, + "require-dev": { + "captainhook/captainhook": "^5.10", + "captainhook/plugin-composer": "^5.3", + "dealerdirect/phpcodesniffer-composer-installer": "^0.7.0", + "doctrine/annotations": "^1.8", + "ergebnis/composer-normalize": "^2.15", + "mockery/mockery": "^1.3", + "paragonie/random-lib": "^2", + "php-mock/php-mock": "^2.2", + "php-mock/php-mock-mockery": "^1.3", + "php-parallel-lint/php-parallel-lint": "^1.1", + "phpbench/phpbench": "^1.0", + "phpstan/extension-installer": "^1.1", + "phpstan/phpstan": "^1.8", + "phpstan/phpstan-mockery": "^1.1", + "phpstan/phpstan-phpunit": "^1.1", + "phpunit/phpunit": "^8.5 || ^9", + "ramsey/composer-repl": "^1.4", + "slevomat/coding-standard": "^8.4", + "squizlabs/php_codesniffer": "^3.5", + "vimeo/psalm": "^4.9" + }, + "suggest": { + "ext-bcmath": "Enables faster math with arbitrary-precision integers using BCMath.", + "ext-gmp": "Enables faster math with arbitrary-precision integers using GMP.", + "ext-uuid": "Enables the use of PeclUuidTimeGenerator and PeclUuidRandomGenerator.", + "paragonie/random-lib": "Provides RandomLib for use with the RandomLibAdapter", + "ramsey/uuid-doctrine": "Allows the use of Ramsey\\Uuid\\Uuid as Doctrine field type." + }, + "type": "library", + "extra": { + "captainhook": { + "force-install": true + } + }, + "autoload": { + "files": [ + "src/functions.php" + ], + "psr-4": { + "Ramsey\\Uuid\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "description": "A PHP library for generating and working with universally unique identifiers (UUIDs).", + "keywords": [ + "guid", + "identifier", + "uuid" + ], + "support": { + "issues": "https://github.com/ramsey/uuid/issues", + "source": "https://github.com/ramsey/uuid/tree/4.7.6" + }, + "funding": [ + { + "url": "https://github.com/ramsey", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/ramsey/uuid", + "type": "tidelift" + } + ], + "time": "2024-04-27T21:32:50+00:00" + }, + { + "name": "sabberworm/php-css-parser", + "version": "v8.6.0", + "source": { + "type": "git", + "url": "https://github.com/MyIntervals/PHP-CSS-Parser.git", + "reference": "d2fb94a9641be84d79c7548c6d39bbebba6e9a70" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/MyIntervals/PHP-CSS-Parser/zipball/d2fb94a9641be84d79c7548c6d39bbebba6e9a70", + "reference": "d2fb94a9641be84d79c7548c6d39bbebba6e9a70", + "shasum": "" + }, + "require": { + "ext-iconv": "*", + "php": ">=5.6.20" + }, + "require-dev": { + "phpunit/phpunit": "^5.7.27" + }, + "suggest": { + "ext-mbstring": "for parsing UTF-8 CSS" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "9.0.x-dev" + } + }, + "autoload": { + "psr-4": { + "Sabberworm\\CSS\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Raphael Schweikert" + }, + { + "name": "Oliver Klee", + "email": "github@oliverklee.de" + }, + { + "name": "Jake Hotson", + "email": "jake.github@qzdesign.co.uk" + } + ], + "description": "Parser for CSS Files written in PHP", + "homepage": "https://www.sabberworm.com/blog/2010/6/10/php-css-parser", + "keywords": [ + "css", + "parser", + "stylesheet" + ], + "support": { + "issues": "https://github.com/MyIntervals/PHP-CSS-Parser/issues", + "source": "https://github.com/MyIntervals/PHP-CSS-Parser/tree/v8.6.0" + }, + "time": "2024-07-01T07:33:21+00:00" + }, + { + "name": "setasign/fpdf", + "version": "1.8.6", + "source": { + "type": "git", + "url": "https://github.com/Setasign/FPDF.git", + "reference": "0838e0ee4925716fcbbc50ad9e1799b5edfae0a0" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/Setasign/FPDF/zipball/0838e0ee4925716fcbbc50ad9e1799b5edfae0a0", + "reference": "0838e0ee4925716fcbbc50ad9e1799b5edfae0a0", + "shasum": "" + }, + "require": { + "ext-gd": "*", + "ext-zlib": "*" + }, + "type": "library", + "autoload": { + "classmap": [ + "fpdf.php" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Olivier Plathey", + "email": "oliver@fpdf.org", + "homepage": "http://fpdf.org/" + } + ], + "description": "FPDF is a PHP class which allows to generate PDF files with pure PHP. F from FPDF stands for Free: you may use it for any kind of usage and modify it to suit your needs.", + "homepage": "http://www.fpdf.org", + "keywords": [ + "fpdf", + "pdf" + ], + "support": { + "source": "https://github.com/Setasign/FPDF/tree/1.8.6" + }, + "time": "2023-06-26T14:44:25+00:00" + }, + { + "name": "setasign/fpdi", + "version": "v2.6.0", + "source": { + "type": "git", + "url": "https://github.com/Setasign/FPDI.git", + "reference": "a6db878129ec6c7e141316ee71872923e7f1b7ad" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/Setasign/FPDI/zipball/a6db878129ec6c7e141316ee71872923e7f1b7ad", + "reference": "a6db878129ec6c7e141316ee71872923e7f1b7ad", + "shasum": "" + }, + "require": { + "ext-zlib": "*", + "php": "^5.6 || ^7.0 || ^8.0" + }, + "conflict": { + "setasign/tfpdf": "<1.31" + }, + "require-dev": { + "phpunit/phpunit": "~5.7", + "setasign/fpdf": "~1.8.6", + "setasign/tfpdf": "~1.33", + "squizlabs/php_codesniffer": "^3.5", + "tecnickcom/tcpdf": "~6.2" + }, + "suggest": { + "setasign/fpdf": "FPDI will extend this class but as it is also possible to use TCPDF or tFPDF as an alternative. There's no fixed dependency configured." + }, + "type": "library", + "autoload": { + "psr-4": { + "setasign\\Fpdi\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Jan Slabon", + "email": "jan.slabon@setasign.com", + "homepage": "https://www.setasign.com" + }, + { + "name": "Maximilian Kresse", + "email": "maximilian.kresse@setasign.com", + "homepage": "https://www.setasign.com" + } + ], + "description": "FPDI is a collection of PHP classes facilitating developers to read pages from existing PDF documents and use them as templates in FPDF. Because it is also possible to use FPDI with TCPDF, there are no fixed dependencies defined. Please see suggestions for packages which evaluates the dependencies automatically.", + "homepage": "https://www.setasign.com/fpdi", + "keywords": [ + "fpdf", + "fpdi", + "pdf" + ], + "support": { + "issues": "https://github.com/Setasign/FPDI/issues", + "source": "https://github.com/Setasign/FPDI/tree/v2.6.0" + }, + "funding": [ + { + "url": "https://tidelift.com/funding/github/packagist/setasign/fpdi", + "type": "tidelift" + } + ], + "time": "2023-12-11T16:03:32+00:00" + }, + { + "name": "symfony/console", + "version": "v6.4.9", + "source": { + "type": "git", + "url": "https://github.com/symfony/console.git", + "reference": "6edb5363ec0c78ad4d48c5128ebf4d083d89d3a9" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/console/zipball/6edb5363ec0c78ad4d48c5128ebf4d083d89d3a9", + "reference": "6edb5363ec0c78ad4d48c5128ebf4d083d89d3a9", + "shasum": "" + }, + "require": { + "php": ">=8.1", + "symfony/deprecation-contracts": "^2.5|^3", + "symfony/polyfill-mbstring": "~1.0", + "symfony/service-contracts": "^2.5|^3", + "symfony/string": "^5.4|^6.0|^7.0" + }, + "conflict": { + "symfony/dependency-injection": "<5.4", + "symfony/dotenv": "<5.4", + "symfony/event-dispatcher": "<5.4", + "symfony/lock": "<5.4", + "symfony/process": "<5.4" + }, + "provide": { + "psr/log-implementation": "1.0|2.0|3.0" + }, + "require-dev": { + "psr/log": "^1|^2|^3", + "symfony/config": "^5.4|^6.0|^7.0", + "symfony/dependency-injection": "^5.4|^6.0|^7.0", + "symfony/event-dispatcher": "^5.4|^6.0|^7.0", + "symfony/http-foundation": "^6.4|^7.0", + "symfony/http-kernel": "^6.4|^7.0", + "symfony/lock": "^5.4|^6.0|^7.0", + "symfony/messenger": "^5.4|^6.0|^7.0", + "symfony/process": "^5.4|^6.0|^7.0", + "symfony/stopwatch": "^5.4|^6.0|^7.0", + "symfony/var-dumper": "^5.4|^6.0|^7.0" + }, + "type": "library", + "autoload": { + "psr-4": { + "Symfony\\Component\\Console\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Eases the creation of beautiful and testable command line interfaces", + "homepage": "https://symfony.com", + "keywords": [ + "cli", + "command-line", + "console", + "terminal" + ], + "support": { + "source": "https://github.com/symfony/console/tree/v6.4.9" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2024-06-28T09:49:33+00:00" + }, + { + "name": "symfony/css-selector", + "version": "v7.1.1", + "source": { + "type": "git", + "url": "https://github.com/symfony/css-selector.git", + "reference": "1c7cee86c6f812896af54434f8ce29c8d94f9ff4" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/css-selector/zipball/1c7cee86c6f812896af54434f8ce29c8d94f9ff4", + "reference": "1c7cee86c6f812896af54434f8ce29c8d94f9ff4", + "shasum": "" + }, + "require": { + "php": ">=8.2" + }, + "type": "library", + "autoload": { + "psr-4": { + "Symfony\\Component\\CssSelector\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Jean-François Simon", + "email": "jeanfrancois.simon@sensiolabs.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Converts CSS selectors to XPath expressions", + "homepage": "https://symfony.com", + "support": { + "source": "https://github.com/symfony/css-selector/tree/v7.1.1" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2024-05-31T14:57:53+00:00" + }, + { + "name": "symfony/deprecation-contracts", + "version": "v3.5.0", + "source": { + "type": "git", + "url": "https://github.com/symfony/deprecation-contracts.git", + "reference": "0e0d29ce1f20deffb4ab1b016a7257c4f1e789a1" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/0e0d29ce1f20deffb4ab1b016a7257c4f1e789a1", + "reference": "0e0d29ce1f20deffb4ab1b016a7257c4f1e789a1", + "shasum": "" + }, + "require": { + "php": ">=8.1" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "3.5-dev" + }, + "thanks": { + "name": "symfony/contracts", + "url": "https://github.com/symfony/contracts" + } + }, + "autoload": { + "files": [ + "function.php" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "A generic function and convention to trigger deprecation notices", + "homepage": "https://symfony.com", + "support": { + "source": "https://github.com/symfony/deprecation-contracts/tree/v3.5.0" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2024-04-18T09:32:20+00:00" + }, + { + "name": "symfony/error-handler", + "version": "v6.4.9", + "source": { + "type": "git", + "url": "https://github.com/symfony/error-handler.git", + "reference": "c9b7cc075b3ab484239855622ca05cb0b99c13ec" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/error-handler/zipball/c9b7cc075b3ab484239855622ca05cb0b99c13ec", + "reference": "c9b7cc075b3ab484239855622ca05cb0b99c13ec", + "shasum": "" + }, + "require": { + "php": ">=8.1", + "psr/log": "^1|^2|^3", + "symfony/var-dumper": "^5.4|^6.0|^7.0" + }, + "conflict": { + "symfony/deprecation-contracts": "<2.5", + "symfony/http-kernel": "<6.4" + }, + "require-dev": { + "symfony/deprecation-contracts": "^2.5|^3", + "symfony/http-kernel": "^6.4|^7.0", + "symfony/serializer": "^5.4|^6.0|^7.0" + }, + "bin": [ + "Resources/bin/patch-type-declarations" + ], + "type": "library", + "autoload": { + "psr-4": { + "Symfony\\Component\\ErrorHandler\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Provides tools to manage errors and ease debugging PHP code", + "homepage": "https://symfony.com", + "support": { + "source": "https://github.com/symfony/error-handler/tree/v6.4.9" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2024-06-21T16:04:15+00:00" + }, + { + "name": "symfony/event-dispatcher", + "version": "v7.1.1", + "source": { + "type": "git", + "url": "https://github.com/symfony/event-dispatcher.git", + "reference": "9fa7f7a21beb22a39a8f3f28618b29e50d7a55a7" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/9fa7f7a21beb22a39a8f3f28618b29e50d7a55a7", + "reference": "9fa7f7a21beb22a39a8f3f28618b29e50d7a55a7", + "shasum": "" + }, + "require": { + "php": ">=8.2", + "symfony/event-dispatcher-contracts": "^2.5|^3" + }, + "conflict": { + "symfony/dependency-injection": "<6.4", + "symfony/service-contracts": "<2.5" + }, + "provide": { + "psr/event-dispatcher-implementation": "1.0", + "symfony/event-dispatcher-implementation": "2.0|3.0" + }, + "require-dev": { + "psr/log": "^1|^2|^3", + "symfony/config": "^6.4|^7.0", + "symfony/dependency-injection": "^6.4|^7.0", + "symfony/error-handler": "^6.4|^7.0", + "symfony/expression-language": "^6.4|^7.0", + "symfony/http-foundation": "^6.4|^7.0", + "symfony/service-contracts": "^2.5|^3", + "symfony/stopwatch": "^6.4|^7.0" + }, + "type": "library", + "autoload": { + "psr-4": { + "Symfony\\Component\\EventDispatcher\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Provides tools that allow your application components to communicate with each other by dispatching events and listening to them", + "homepage": "https://symfony.com", + "support": { + "source": "https://github.com/symfony/event-dispatcher/tree/v7.1.1" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2024-05-31T14:57:53+00:00" + }, + { + "name": "symfony/event-dispatcher-contracts", + "version": "v3.5.0", + "source": { + "type": "git", + "url": "https://github.com/symfony/event-dispatcher-contracts.git", + "reference": "8f93aec25d41b72493c6ddff14e916177c9efc50" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/event-dispatcher-contracts/zipball/8f93aec25d41b72493c6ddff14e916177c9efc50", + "reference": "8f93aec25d41b72493c6ddff14e916177c9efc50", + "shasum": "" + }, + "require": { + "php": ">=8.1", + "psr/event-dispatcher": "^1" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "3.5-dev" + }, + "thanks": { + "name": "symfony/contracts", + "url": "https://github.com/symfony/contracts" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Contracts\\EventDispatcher\\": "" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Generic abstractions related to dispatching event", + "homepage": "https://symfony.com", + "keywords": [ + "abstractions", + "contracts", + "decoupling", + "interfaces", + "interoperability", + "standards" + ], + "support": { + "source": "https://github.com/symfony/event-dispatcher-contracts/tree/v3.5.0" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2024-04-18T09:32:20+00:00" + }, + { + "name": "symfony/finder", + "version": "v6.4.8", + "source": { + "type": "git", + "url": "https://github.com/symfony/finder.git", + "reference": "3ef977a43883215d560a2cecb82ec8e62131471c" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/finder/zipball/3ef977a43883215d560a2cecb82ec8e62131471c", + "reference": "3ef977a43883215d560a2cecb82ec8e62131471c", + "shasum": "" + }, + "require": { + "php": ">=8.1" + }, + "require-dev": { + "symfony/filesystem": "^6.0|^7.0" + }, + "type": "library", + "autoload": { + "psr-4": { + "Symfony\\Component\\Finder\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Finds files and directories via an intuitive fluent interface", + "homepage": "https://symfony.com", + "support": { + "source": "https://github.com/symfony/finder/tree/v6.4.8" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2024-05-31T14:49:08+00:00" + }, + { + "name": "symfony/http-foundation", + "version": "v6.4.8", + "source": { + "type": "git", + "url": "https://github.com/symfony/http-foundation.git", + "reference": "27de8cc95e11db7a50b027e71caaab9024545947" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/http-foundation/zipball/27de8cc95e11db7a50b027e71caaab9024545947", + "reference": "27de8cc95e11db7a50b027e71caaab9024545947", + "shasum": "" + }, + "require": { + "php": ">=8.1", + "symfony/deprecation-contracts": "^2.5|^3", + "symfony/polyfill-mbstring": "~1.1", + "symfony/polyfill-php83": "^1.27" + }, + "conflict": { + "symfony/cache": "<6.3" + }, + "require-dev": { + "doctrine/dbal": "^2.13.1|^3|^4", + "predis/predis": "^1.1|^2.0", + "symfony/cache": "^6.3|^7.0", + "symfony/dependency-injection": "^5.4|^6.0|^7.0", + "symfony/expression-language": "^5.4|^6.0|^7.0", + "symfony/http-kernel": "^5.4.12|^6.0.12|^6.1.4|^7.0", + "symfony/mime": "^5.4|^6.0|^7.0", + "symfony/rate-limiter": "^5.4|^6.0|^7.0" + }, + "type": "library", + "autoload": { + "psr-4": { + "Symfony\\Component\\HttpFoundation\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Defines an object-oriented layer for the HTTP specification", + "homepage": "https://symfony.com", + "support": { + "source": "https://github.com/symfony/http-foundation/tree/v6.4.8" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2024-05-31T14:49:08+00:00" + }, + { + "name": "symfony/http-kernel", + "version": "v6.4.9", + "source": { + "type": "git", + "url": "https://github.com/symfony/http-kernel.git", + "reference": "cc4a9bec6e1bdd2405f40277a68a6ed1bb393005" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/http-kernel/zipball/cc4a9bec6e1bdd2405f40277a68a6ed1bb393005", + "reference": "cc4a9bec6e1bdd2405f40277a68a6ed1bb393005", + "shasum": "" + }, + "require": { + "php": ">=8.1", + "psr/log": "^1|^2|^3", + "symfony/deprecation-contracts": "^2.5|^3", + "symfony/error-handler": "^6.4|^7.0", + "symfony/event-dispatcher": "^5.4|^6.0|^7.0", + "symfony/http-foundation": "^6.4|^7.0", + "symfony/polyfill-ctype": "^1.8" + }, + "conflict": { + "symfony/browser-kit": "<5.4", + "symfony/cache": "<5.4", + "symfony/config": "<6.1", + "symfony/console": "<5.4", + "symfony/dependency-injection": "<6.4", + "symfony/doctrine-bridge": "<5.4", + "symfony/form": "<5.4", + "symfony/http-client": "<5.4", + "symfony/http-client-contracts": "<2.5", + "symfony/mailer": "<5.4", + "symfony/messenger": "<5.4", + "symfony/translation": "<5.4", + "symfony/translation-contracts": "<2.5", + "symfony/twig-bridge": "<5.4", + "symfony/validator": "<6.4", + "symfony/var-dumper": "<6.3", + "twig/twig": "<2.13" + }, + "provide": { + "psr/log-implementation": "1.0|2.0|3.0" + }, + "require-dev": { + "psr/cache": "^1.0|^2.0|^3.0", + "symfony/browser-kit": "^5.4|^6.0|^7.0", + "symfony/clock": "^6.2|^7.0", + "symfony/config": "^6.1|^7.0", + "symfony/console": "^5.4|^6.0|^7.0", + "symfony/css-selector": "^5.4|^6.0|^7.0", + "symfony/dependency-injection": "^6.4|^7.0", + "symfony/dom-crawler": "^5.4|^6.0|^7.0", + "symfony/expression-language": "^5.4|^6.0|^7.0", + "symfony/finder": "^5.4|^6.0|^7.0", + "symfony/http-client-contracts": "^2.5|^3", + "symfony/process": "^5.4|^6.0|^7.0", + "symfony/property-access": "^5.4.5|^6.0.5|^7.0", + "symfony/routing": "^5.4|^6.0|^7.0", + "symfony/serializer": "^6.4.4|^7.0.4", + "symfony/stopwatch": "^5.4|^6.0|^7.0", + "symfony/translation": "^5.4|^6.0|^7.0", + "symfony/translation-contracts": "^2.5|^3", + "symfony/uid": "^5.4|^6.0|^7.0", + "symfony/validator": "^6.4|^7.0", + "symfony/var-dumper": "^5.4|^6.4|^7.0", + "symfony/var-exporter": "^6.2|^7.0", + "twig/twig": "^2.13|^3.0.4" + }, + "type": "library", + "autoload": { + "psr-4": { + "Symfony\\Component\\HttpKernel\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Provides a structured process for converting a Request into a Response", + "homepage": "https://symfony.com", + "support": { + "source": "https://github.com/symfony/http-kernel/tree/v6.4.9" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2024-06-28T11:48:06+00:00" + }, + { + "name": "symfony/mailer", + "version": "v6.4.9", + "source": { + "type": "git", + "url": "https://github.com/symfony/mailer.git", + "reference": "e2d56f180f5b8c5e7c0fbea872bb1f529b6d6d45" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/mailer/zipball/e2d56f180f5b8c5e7c0fbea872bb1f529b6d6d45", + "reference": "e2d56f180f5b8c5e7c0fbea872bb1f529b6d6d45", + "shasum": "" + }, + "require": { + "egulias/email-validator": "^2.1.10|^3|^4", + "php": ">=8.1", + "psr/event-dispatcher": "^1", + "psr/log": "^1|^2|^3", + "symfony/event-dispatcher": "^5.4|^6.0|^7.0", + "symfony/mime": "^6.2|^7.0", + "symfony/service-contracts": "^2.5|^3" + }, + "conflict": { + "symfony/http-client-contracts": "<2.5", + "symfony/http-kernel": "<5.4", + "symfony/messenger": "<6.2", + "symfony/mime": "<6.2", + "symfony/twig-bridge": "<6.2.1" + }, + "require-dev": { + "symfony/console": "^5.4|^6.0|^7.0", + "symfony/http-client": "^5.4|^6.0|^7.0", + "symfony/messenger": "^6.2|^7.0", + "symfony/twig-bridge": "^6.2|^7.0" + }, + "type": "library", + "autoload": { + "psr-4": { + "Symfony\\Component\\Mailer\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Helps sending emails", + "homepage": "https://symfony.com", + "support": { + "source": "https://github.com/symfony/mailer/tree/v6.4.9" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2024-06-28T07:59:05+00:00" + }, + { + "name": "symfony/mime", + "version": "v6.4.9", + "source": { + "type": "git", + "url": "https://github.com/symfony/mime.git", + "reference": "7d048964877324debdcb4e0549becfa064a20d43" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/mime/zipball/7d048964877324debdcb4e0549becfa064a20d43", + "reference": "7d048964877324debdcb4e0549becfa064a20d43", + "shasum": "" + }, + "require": { + "php": ">=8.1", + "symfony/deprecation-contracts": "^2.5|^3", + "symfony/polyfill-intl-idn": "^1.10", + "symfony/polyfill-mbstring": "^1.0" + }, + "conflict": { + "egulias/email-validator": "~3.0.0", + "phpdocumentor/reflection-docblock": "<3.2.2", + "phpdocumentor/type-resolver": "<1.4.0", + "symfony/mailer": "<5.4", + "symfony/serializer": "<6.4.3|>7.0,<7.0.3" + }, + "require-dev": { + "egulias/email-validator": "^2.1.10|^3.1|^4", + "league/html-to-markdown": "^5.0", + "phpdocumentor/reflection-docblock": "^3.0|^4.0|^5.0", + "symfony/dependency-injection": "^5.4|^6.0|^7.0", + "symfony/process": "^5.4|^6.4|^7.0", + "symfony/property-access": "^5.4|^6.0|^7.0", + "symfony/property-info": "^5.4|^6.0|^7.0", + "symfony/serializer": "^6.4.3|^7.0.3" + }, + "type": "library", + "autoload": { + "psr-4": { + "Symfony\\Component\\Mime\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Allows manipulating MIME messages", + "homepage": "https://symfony.com", + "keywords": [ + "mime", + "mime-type" + ], + "support": { + "source": "https://github.com/symfony/mime/tree/v6.4.9" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2024-06-28T09:49:33+00:00" + }, + { + "name": "symfony/polyfill-ctype", + "version": "v1.30.0", + "source": { + "type": "git", + "url": "https://github.com/symfony/polyfill-ctype.git", + "reference": "0424dff1c58f028c451efff2045f5d92410bd540" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/0424dff1c58f028c451efff2045f5d92410bd540", + "reference": "0424dff1c58f028c451efff2045f5d92410bd540", + "shasum": "" + }, + "require": { + "php": ">=7.1" + }, + "provide": { + "ext-ctype": "*" + }, + "suggest": { + "ext-ctype": "For best performance" + }, + "type": "library", + "extra": { + "thanks": { + "name": "symfony/polyfill", + "url": "https://github.com/symfony/polyfill" + } + }, + "autoload": { + "files": [ + "bootstrap.php" + ], + "psr-4": { + "Symfony\\Polyfill\\Ctype\\": "" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Gert de Pagter", + "email": "BackEndTea@gmail.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony polyfill for ctype functions", + "homepage": "https://symfony.com", + "keywords": [ + "compatibility", + "ctype", + "polyfill", + "portable" + ], + "support": { + "source": "https://github.com/symfony/polyfill-ctype/tree/v1.30.0" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2024-05-31T15:07:36+00:00" + }, + { + "name": "symfony/polyfill-intl-grapheme", + "version": "v1.30.0", + "source": { + "type": "git", + "url": "https://github.com/symfony/polyfill-intl-grapheme.git", + "reference": "64647a7c30b2283f5d49b874d84a18fc22054b7a" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/polyfill-intl-grapheme/zipball/64647a7c30b2283f5d49b874d84a18fc22054b7a", + "reference": "64647a7c30b2283f5d49b874d84a18fc22054b7a", + "shasum": "" + }, + "require": { + "php": ">=7.1" + }, + "suggest": { + "ext-intl": "For best performance" + }, + "type": "library", + "extra": { + "thanks": { + "name": "symfony/polyfill", + "url": "https://github.com/symfony/polyfill" + } + }, + "autoload": { + "files": [ + "bootstrap.php" + ], + "psr-4": { + "Symfony\\Polyfill\\Intl\\Grapheme\\": "" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony polyfill for intl's grapheme_* functions", + "homepage": "https://symfony.com", + "keywords": [ + "compatibility", + "grapheme", + "intl", + "polyfill", + "portable", + "shim" + ], + "support": { + "source": "https://github.com/symfony/polyfill-intl-grapheme/tree/v1.30.0" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2024-05-31T15:07:36+00:00" + }, + { + "name": "symfony/polyfill-intl-idn", + "version": "v1.30.0", + "source": { + "type": "git", + "url": "https://github.com/symfony/polyfill-intl-idn.git", + "reference": "a6e83bdeb3c84391d1dfe16f42e40727ce524a5c" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/polyfill-intl-idn/zipball/a6e83bdeb3c84391d1dfe16f42e40727ce524a5c", + "reference": "a6e83bdeb3c84391d1dfe16f42e40727ce524a5c", + "shasum": "" + }, + "require": { + "php": ">=7.1", + "symfony/polyfill-intl-normalizer": "^1.10", + "symfony/polyfill-php72": "^1.10" + }, + "suggest": { + "ext-intl": "For best performance" + }, + "type": "library", + "extra": { + "thanks": { + "name": "symfony/polyfill", + "url": "https://github.com/symfony/polyfill" + } + }, + "autoload": { + "files": [ + "bootstrap.php" + ], + "psr-4": { + "Symfony\\Polyfill\\Intl\\Idn\\": "" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Laurent Bassin", + "email": "laurent@bassin.info" + }, + { + "name": "Trevor Rowbotham", + "email": "trevor.rowbotham@pm.me" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony polyfill for intl's idn_to_ascii and idn_to_utf8 functions", + "homepage": "https://symfony.com", + "keywords": [ + "compatibility", + "idn", + "intl", + "polyfill", + "portable", + "shim" + ], + "support": { + "source": "https://github.com/symfony/polyfill-intl-idn/tree/v1.30.0" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2024-05-31T15:07:36+00:00" + }, + { + "name": "symfony/polyfill-intl-normalizer", + "version": "v1.30.0", + "source": { + "type": "git", + "url": "https://github.com/symfony/polyfill-intl-normalizer.git", + "reference": "a95281b0be0d9ab48050ebd988b967875cdb9fdb" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/polyfill-intl-normalizer/zipball/a95281b0be0d9ab48050ebd988b967875cdb9fdb", + "reference": "a95281b0be0d9ab48050ebd988b967875cdb9fdb", + "shasum": "" + }, + "require": { + "php": ">=7.1" + }, + "suggest": { + "ext-intl": "For best performance" + }, + "type": "library", + "extra": { + "thanks": { + "name": "symfony/polyfill", + "url": "https://github.com/symfony/polyfill" + } + }, + "autoload": { + "files": [ + "bootstrap.php" + ], + "psr-4": { + "Symfony\\Polyfill\\Intl\\Normalizer\\": "" + }, + "classmap": [ + "Resources/stubs" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony polyfill for intl's Normalizer class and related functions", + "homepage": "https://symfony.com", + "keywords": [ + "compatibility", + "intl", + "normalizer", + "polyfill", + "portable", + "shim" + ], + "support": { + "source": "https://github.com/symfony/polyfill-intl-normalizer/tree/v1.30.0" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2024-05-31T15:07:36+00:00" + }, + { + "name": "symfony/polyfill-mbstring", + "version": "v1.30.0", + "source": { + "type": "git", + "url": "https://github.com/symfony/polyfill-mbstring.git", + "reference": "fd22ab50000ef01661e2a31d850ebaa297f8e03c" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/fd22ab50000ef01661e2a31d850ebaa297f8e03c", + "reference": "fd22ab50000ef01661e2a31d850ebaa297f8e03c", + "shasum": "" + }, + "require": { + "php": ">=7.1" + }, + "provide": { + "ext-mbstring": "*" + }, + "suggest": { + "ext-mbstring": "For best performance" + }, + "type": "library", + "extra": { + "thanks": { + "name": "symfony/polyfill", + "url": "https://github.com/symfony/polyfill" + } + }, + "autoload": { + "files": [ + "bootstrap.php" + ], + "psr-4": { + "Symfony\\Polyfill\\Mbstring\\": "" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony polyfill for the Mbstring extension", + "homepage": "https://symfony.com", + "keywords": [ + "compatibility", + "mbstring", + "polyfill", + "portable", + "shim" + ], + "support": { + "source": "https://github.com/symfony/polyfill-mbstring/tree/v1.30.0" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2024-06-19T12:30:46+00:00" + }, + { + "name": "symfony/polyfill-php72", + "version": "v1.30.0", + "source": { + "type": "git", + "url": "https://github.com/symfony/polyfill-php72.git", + "reference": "10112722600777e02d2745716b70c5db4ca70442" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/polyfill-php72/zipball/10112722600777e02d2745716b70c5db4ca70442", + "reference": "10112722600777e02d2745716b70c5db4ca70442", + "shasum": "" + }, + "require": { + "php": ">=7.1" + }, + "type": "library", + "extra": { + "thanks": { + "name": "symfony/polyfill", + "url": "https://github.com/symfony/polyfill" + } + }, + "autoload": { + "files": [ + "bootstrap.php" + ], + "psr-4": { + "Symfony\\Polyfill\\Php72\\": "" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony polyfill backporting some PHP 7.2+ features to lower PHP versions", + "homepage": "https://symfony.com", + "keywords": [ + "compatibility", + "polyfill", + "portable", + "shim" + ], + "support": { + "source": "https://github.com/symfony/polyfill-php72/tree/v1.30.0" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2024-06-19T12:30:46+00:00" + }, + { + "name": "symfony/polyfill-php80", + "version": "v1.30.0", + "source": { + "type": "git", + "url": "https://github.com/symfony/polyfill-php80.git", + "reference": "77fa7995ac1b21ab60769b7323d600a991a90433" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/polyfill-php80/zipball/77fa7995ac1b21ab60769b7323d600a991a90433", + "reference": "77fa7995ac1b21ab60769b7323d600a991a90433", + "shasum": "" + }, + "require": { + "php": ">=7.1" + }, + "type": "library", + "extra": { + "thanks": { + "name": "symfony/polyfill", + "url": "https://github.com/symfony/polyfill" + } + }, + "autoload": { + "files": [ + "bootstrap.php" + ], + "psr-4": { + "Symfony\\Polyfill\\Php80\\": "" + }, + "classmap": [ + "Resources/stubs" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Ion Bazan", + "email": "ion.bazan@gmail.com" + }, + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony polyfill backporting some PHP 8.0+ features to lower PHP versions", + "homepage": "https://symfony.com", + "keywords": [ + "compatibility", + "polyfill", + "portable", + "shim" + ], + "support": { + "source": "https://github.com/symfony/polyfill-php80/tree/v1.30.0" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2024-05-31T15:07:36+00:00" + }, + { + "name": "symfony/polyfill-php83", + "version": "v1.30.0", + "source": { + "type": "git", + "url": "https://github.com/symfony/polyfill-php83.git", + "reference": "dbdcdf1a4dcc2743591f1079d0c35ab1e2dcbbc9" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/polyfill-php83/zipball/dbdcdf1a4dcc2743591f1079d0c35ab1e2dcbbc9", + "reference": "dbdcdf1a4dcc2743591f1079d0c35ab1e2dcbbc9", + "shasum": "" + }, + "require": { + "php": ">=7.1" + }, + "type": "library", + "extra": { + "thanks": { + "name": "symfony/polyfill", + "url": "https://github.com/symfony/polyfill" + } + }, + "autoload": { + "files": [ + "bootstrap.php" + ], + "psr-4": { + "Symfony\\Polyfill\\Php83\\": "" + }, + "classmap": [ + "Resources/stubs" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony polyfill backporting some PHP 8.3+ features to lower PHP versions", + "homepage": "https://symfony.com", + "keywords": [ + "compatibility", + "polyfill", + "portable", + "shim" + ], + "support": { + "source": "https://github.com/symfony/polyfill-php83/tree/v1.30.0" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2024-06-19T12:35:24+00:00" + }, + { + "name": "symfony/polyfill-uuid", + "version": "v1.30.0", + "source": { + "type": "git", + "url": "https://github.com/symfony/polyfill-uuid.git", + "reference": "2ba1f33797470debcda07fe9dce20a0003df18e9" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/polyfill-uuid/zipball/2ba1f33797470debcda07fe9dce20a0003df18e9", + "reference": "2ba1f33797470debcda07fe9dce20a0003df18e9", + "shasum": "" + }, + "require": { + "php": ">=7.1" + }, + "provide": { + "ext-uuid": "*" + }, + "suggest": { + "ext-uuid": "For best performance" + }, + "type": "library", + "extra": { + "thanks": { + "name": "symfony/polyfill", + "url": "https://github.com/symfony/polyfill" + } + }, + "autoload": { + "files": [ + "bootstrap.php" + ], + "psr-4": { + "Symfony\\Polyfill\\Uuid\\": "" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Grégoire Pineau", + "email": "lyrixx@lyrixx.info" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony polyfill for uuid functions", + "homepage": "https://symfony.com", + "keywords": [ + "compatibility", + "polyfill", + "portable", + "uuid" + ], + "support": { + "source": "https://github.com/symfony/polyfill-uuid/tree/v1.30.0" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2024-05-31T15:07:36+00:00" + }, + { + "name": "symfony/process", + "version": "v6.4.8", + "source": { + "type": "git", + "url": "https://github.com/symfony/process.git", + "reference": "8d92dd79149f29e89ee0f480254db595f6a6a2c5" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/process/zipball/8d92dd79149f29e89ee0f480254db595f6a6a2c5", + "reference": "8d92dd79149f29e89ee0f480254db595f6a6a2c5", + "shasum": "" + }, + "require": { + "php": ">=8.1" + }, + "type": "library", + "autoload": { + "psr-4": { + "Symfony\\Component\\Process\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Executes commands in sub-processes", + "homepage": "https://symfony.com", + "support": { + "source": "https://github.com/symfony/process/tree/v6.4.8" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2024-05-31T14:49:08+00:00" + }, + { + "name": "symfony/routing", + "version": "v6.4.8", + "source": { + "type": "git", + "url": "https://github.com/symfony/routing.git", + "reference": "8a40d0f9b01f0fbb80885d3ce0ad6714fb603a58" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/routing/zipball/8a40d0f9b01f0fbb80885d3ce0ad6714fb603a58", + "reference": "8a40d0f9b01f0fbb80885d3ce0ad6714fb603a58", + "shasum": "" + }, + "require": { + "php": ">=8.1", + "symfony/deprecation-contracts": "^2.5|^3" + }, + "conflict": { + "doctrine/annotations": "<1.12", + "symfony/config": "<6.2", + "symfony/dependency-injection": "<5.4", + "symfony/yaml": "<5.4" + }, + "require-dev": { + "doctrine/annotations": "^1.12|^2", + "psr/log": "^1|^2|^3", + "symfony/config": "^6.2|^7.0", + "symfony/dependency-injection": "^5.4|^6.0|^7.0", + "symfony/expression-language": "^5.4|^6.0|^7.0", + "symfony/http-foundation": "^5.4|^6.0|^7.0", + "symfony/yaml": "^5.4|^6.0|^7.0" + }, + "type": "library", + "autoload": { + "psr-4": { + "Symfony\\Component\\Routing\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Maps an HTTP request to a set of configuration variables", + "homepage": "https://symfony.com", + "keywords": [ + "router", + "routing", + "uri", + "url" + ], + "support": { + "source": "https://github.com/symfony/routing/tree/v6.4.8" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2024-05-31T14:49:08+00:00" + }, + { + "name": "symfony/service-contracts", + "version": "v3.5.0", + "source": { + "type": "git", + "url": "https://github.com/symfony/service-contracts.git", + "reference": "bd1d9e59a81d8fa4acdcea3f617c581f7475a80f" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/service-contracts/zipball/bd1d9e59a81d8fa4acdcea3f617c581f7475a80f", + "reference": "bd1d9e59a81d8fa4acdcea3f617c581f7475a80f", + "shasum": "" + }, + "require": { + "php": ">=8.1", + "psr/container": "^1.1|^2.0", + "symfony/deprecation-contracts": "^2.5|^3" + }, + "conflict": { + "ext-psr": "<1.1|>=2" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "3.5-dev" + }, + "thanks": { + "name": "symfony/contracts", + "url": "https://github.com/symfony/contracts" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Contracts\\Service\\": "" + }, + "exclude-from-classmap": [ + "/Test/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Generic abstractions related to writing services", + "homepage": "https://symfony.com", + "keywords": [ + "abstractions", + "contracts", + "decoupling", + "interfaces", + "interoperability", + "standards" + ], + "support": { + "source": "https://github.com/symfony/service-contracts/tree/v3.5.0" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2024-04-18T09:32:20+00:00" + }, + { + "name": "symfony/string", + "version": "v7.1.2", + "source": { + "type": "git", + "url": "https://github.com/symfony/string.git", + "reference": "14221089ac66cf82e3cf3d1c1da65de305587ff8" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/string/zipball/14221089ac66cf82e3cf3d1c1da65de305587ff8", + "reference": "14221089ac66cf82e3cf3d1c1da65de305587ff8", + "shasum": "" + }, + "require": { + "php": ">=8.2", + "symfony/polyfill-ctype": "~1.8", + "symfony/polyfill-intl-grapheme": "~1.0", + "symfony/polyfill-intl-normalizer": "~1.0", + "symfony/polyfill-mbstring": "~1.0" + }, + "conflict": { + "symfony/translation-contracts": "<2.5" + }, + "require-dev": { + "symfony/emoji": "^7.1", + "symfony/error-handler": "^6.4|^7.0", + "symfony/http-client": "^6.4|^7.0", + "symfony/intl": "^6.4|^7.0", + "symfony/translation-contracts": "^2.5|^3.0", + "symfony/var-exporter": "^6.4|^7.0" + }, + "type": "library", + "autoload": { + "files": [ + "Resources/functions.php" + ], + "psr-4": { + "Symfony\\Component\\String\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Provides an object-oriented API to strings and deals with bytes, UTF-8 code points and grapheme clusters in a unified way", + "homepage": "https://symfony.com", + "keywords": [ + "grapheme", + "i18n", + "string", + "unicode", + "utf-8", + "utf8" + ], + "support": { + "source": "https://github.com/symfony/string/tree/v7.1.2" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2024-06-28T09:27:18+00:00" + }, + { + "name": "symfony/translation", + "version": "v6.4.8", + "source": { + "type": "git", + "url": "https://github.com/symfony/translation.git", + "reference": "a002933b13989fc4bd0b58e04bf7eec5210e438a" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/translation/zipball/a002933b13989fc4bd0b58e04bf7eec5210e438a", + "reference": "a002933b13989fc4bd0b58e04bf7eec5210e438a", + "shasum": "" + }, + "require": { + "php": ">=8.1", + "symfony/deprecation-contracts": "^2.5|^3", + "symfony/polyfill-mbstring": "~1.0", + "symfony/translation-contracts": "^2.5|^3.0" + }, + "conflict": { + "symfony/config": "<5.4", + "symfony/console": "<5.4", + "symfony/dependency-injection": "<5.4", + "symfony/http-client-contracts": "<2.5", + "symfony/http-kernel": "<5.4", + "symfony/service-contracts": "<2.5", + "symfony/twig-bundle": "<5.4", + "symfony/yaml": "<5.4" + }, + "provide": { + "symfony/translation-implementation": "2.3|3.0" + }, + "require-dev": { + "nikic/php-parser": "^4.18|^5.0", + "psr/log": "^1|^2|^3", + "symfony/config": "^5.4|^6.0|^7.0", + "symfony/console": "^5.4|^6.0|^7.0", + "symfony/dependency-injection": "^5.4|^6.0|^7.0", + "symfony/finder": "^5.4|^6.0|^7.0", + "symfony/http-client-contracts": "^2.5|^3.0", + "symfony/http-kernel": "^5.4|^6.0|^7.0", + "symfony/intl": "^5.4|^6.0|^7.0", + "symfony/polyfill-intl-icu": "^1.21", + "symfony/routing": "^5.4|^6.0|^7.0", + "symfony/service-contracts": "^2.5|^3", + "symfony/yaml": "^5.4|^6.0|^7.0" + }, + "type": "library", + "autoload": { + "files": [ + "Resources/functions.php" + ], + "psr-4": { + "Symfony\\Component\\Translation\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Provides tools to internationalize your application", + "homepage": "https://symfony.com", + "support": { + "source": "https://github.com/symfony/translation/tree/v6.4.8" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2024-05-31T14:49:08+00:00" + }, + { + "name": "symfony/translation-contracts", + "version": "v3.5.0", + "source": { + "type": "git", + "url": "https://github.com/symfony/translation-contracts.git", + "reference": "b9d2189887bb6b2e0367a9fc7136c5239ab9b05a" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/translation-contracts/zipball/b9d2189887bb6b2e0367a9fc7136c5239ab9b05a", + "reference": "b9d2189887bb6b2e0367a9fc7136c5239ab9b05a", + "shasum": "" + }, + "require": { + "php": ">=8.1" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "3.5-dev" + }, + "thanks": { + "name": "symfony/contracts", + "url": "https://github.com/symfony/contracts" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Contracts\\Translation\\": "" + }, + "exclude-from-classmap": [ + "/Test/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Generic abstractions related to translation", + "homepage": "https://symfony.com", + "keywords": [ + "abstractions", + "contracts", + "decoupling", + "interfaces", + "interoperability", + "standards" + ], + "support": { + "source": "https://github.com/symfony/translation-contracts/tree/v3.5.0" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2024-04-18T09:32:20+00:00" + }, + { + "name": "symfony/uid", + "version": "v6.4.8", + "source": { + "type": "git", + "url": "https://github.com/symfony/uid.git", + "reference": "35904eca37a84bb764c560cbfcac9f0ac2bcdbdf" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/uid/zipball/35904eca37a84bb764c560cbfcac9f0ac2bcdbdf", + "reference": "35904eca37a84bb764c560cbfcac9f0ac2bcdbdf", + "shasum": "" + }, + "require": { + "php": ">=8.1", + "symfony/polyfill-uuid": "^1.15" + }, + "require-dev": { + "symfony/console": "^5.4|^6.0|^7.0" + }, + "type": "library", + "autoload": { + "psr-4": { + "Symfony\\Component\\Uid\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Grégoire Pineau", + "email": "lyrixx@lyrixx.info" + }, + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Provides an object-oriented API to generate and represent UIDs", + "homepage": "https://symfony.com", + "keywords": [ + "UID", + "ulid", + "uuid" + ], + "support": { + "source": "https://github.com/symfony/uid/tree/v6.4.8" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2024-05-31T14:49:08+00:00" + }, + { + "name": "symfony/var-dumper", + "version": "v6.4.9", + "source": { + "type": "git", + "url": "https://github.com/symfony/var-dumper.git", + "reference": "c31566e4ca944271cc8d8ac6887cbf31b8c6a172" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/var-dumper/zipball/c31566e4ca944271cc8d8ac6887cbf31b8c6a172", + "reference": "c31566e4ca944271cc8d8ac6887cbf31b8c6a172", + "shasum": "" + }, + "require": { + "php": ">=8.1", + "symfony/deprecation-contracts": "^2.5|^3", + "symfony/polyfill-mbstring": "~1.0" + }, + "conflict": { + "symfony/console": "<5.4" + }, + "require-dev": { + "ext-iconv": "*", + "symfony/console": "^5.4|^6.0|^7.0", + "symfony/error-handler": "^6.3|^7.0", + "symfony/http-kernel": "^5.4|^6.0|^7.0", + "symfony/process": "^5.4|^6.0|^7.0", + "symfony/uid": "^5.4|^6.0|^7.0", + "twig/twig": "^2.13|^3.0.4" + }, + "bin": [ + "Resources/bin/var-dump-server" + ], + "type": "library", + "autoload": { + "files": [ + "Resources/functions/dump.php" + ], + "psr-4": { + "Symfony\\Component\\VarDumper\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Provides mechanisms for walking through any arbitrary PHP variable", + "homepage": "https://symfony.com", + "keywords": [ + "debug", + "dump" + ], + "support": { + "source": "https://github.com/symfony/var-dumper/tree/v6.4.9" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2024-06-27T13:23:14+00:00" + }, + { + "name": "tijsverkoyen/css-to-inline-styles", + "version": "v2.2.7", + "source": { + "type": "git", + "url": "https://github.com/tijsverkoyen/CssToInlineStyles.git", + "reference": "83ee6f38df0a63106a9e4536e3060458b74ccedb" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/tijsverkoyen/CssToInlineStyles/zipball/83ee6f38df0a63106a9e4536e3060458b74ccedb", + "reference": "83ee6f38df0a63106a9e4536e3060458b74ccedb", + "shasum": "" + }, + "require": { + "ext-dom": "*", + "ext-libxml": "*", + "php": "^5.5 || ^7.0 || ^8.0", + "symfony/css-selector": "^2.7 || ^3.0 || ^4.0 || ^5.0 || ^6.0 || ^7.0" + }, + "require-dev": { + "phpunit/phpunit": "^4.8.35 || ^5.7 || ^6.0 || ^7.5 || ^8.5.21 || ^9.5.10" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.2.x-dev" + } + }, + "autoload": { + "psr-4": { + "TijsVerkoyen\\CssToInlineStyles\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Tijs Verkoyen", + "email": "css_to_inline_styles@verkoyen.eu", + "role": "Developer" + } + ], + "description": "CssToInlineStyles is a class that enables you to convert HTML-pages/files into HTML-pages/files with inline styles. This is very useful when you're sending emails.", + "homepage": "https://github.com/tijsverkoyen/CssToInlineStyles", + "support": { + "issues": "https://github.com/tijsverkoyen/CssToInlineStyles/issues", + "source": "https://github.com/tijsverkoyen/CssToInlineStyles/tree/v2.2.7" + }, + "time": "2023-12-08T13:03:43+00:00" + }, + { + "name": "vlucas/phpdotenv", + "version": "v5.6.0", + "source": { + "type": "git", + "url": "https://github.com/vlucas/phpdotenv.git", + "reference": "2cf9fb6054c2bb1d59d1f3817706ecdb9d2934c4" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/vlucas/phpdotenv/zipball/2cf9fb6054c2bb1d59d1f3817706ecdb9d2934c4", + "reference": "2cf9fb6054c2bb1d59d1f3817706ecdb9d2934c4", + "shasum": "" + }, + "require": { + "ext-pcre": "*", + "graham-campbell/result-type": "^1.1.2", + "php": "^7.2.5 || ^8.0", + "phpoption/phpoption": "^1.9.2", + "symfony/polyfill-ctype": "^1.24", + "symfony/polyfill-mbstring": "^1.24", + "symfony/polyfill-php80": "^1.24" + }, + "require-dev": { + "bamarni/composer-bin-plugin": "^1.8.2", + "ext-filter": "*", + "phpunit/phpunit": "^8.5.34 || ^9.6.13 || ^10.4.2" + }, + "suggest": { + "ext-filter": "Required to use the boolean validator." + }, + "type": "library", + "extra": { + "bamarni-bin": { + "bin-links": true, + "forward-command": true + }, + "branch-alias": { + "dev-master": "5.6-dev" + } + }, + "autoload": { + "psr-4": { + "Dotenv\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Graham Campbell", + "email": "hello@gjcampbell.co.uk", + "homepage": "https://github.com/GrahamCampbell" + }, + { + "name": "Vance Lucas", + "email": "vance@vancelucas.com", + "homepage": "https://github.com/vlucas" + } + ], + "description": "Loads environment variables from `.env` to `getenv()`, `$_ENV` and `$_SERVER` automagically.", + "keywords": [ + "dotenv", + "env", + "environment" + ], + "support": { + "issues": "https://github.com/vlucas/phpdotenv/issues", + "source": "https://github.com/vlucas/phpdotenv/tree/v5.6.0" + }, + "funding": [ + { + "url": "https://github.com/GrahamCampbell", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/vlucas/phpdotenv", + "type": "tidelift" + } + ], + "time": "2023-11-12T22:43:29+00:00" + }, + { + "name": "voku/portable-ascii", + "version": "2.0.1", + "source": { + "type": "git", + "url": "https://github.com/voku/portable-ascii.git", + "reference": "b56450eed252f6801410d810c8e1727224ae0743" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/voku/portable-ascii/zipball/b56450eed252f6801410d810c8e1727224ae0743", + "reference": "b56450eed252f6801410d810c8e1727224ae0743", + "shasum": "" + }, + "require": { + "php": ">=7.0.0" + }, + "require-dev": { + "phpunit/phpunit": "~6.0 || ~7.0 || ~9.0" + }, + "suggest": { + "ext-intl": "Use Intl for transliterator_transliterate() support" + }, + "type": "library", + "autoload": { + "psr-4": { + "voku\\": "src/voku/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Lars Moelleken", + "homepage": "http://www.moelleken.org/" + } + ], + "description": "Portable ASCII library - performance optimized (ascii) string functions for php.", + "homepage": "https://github.com/voku/portable-ascii", + "keywords": [ + "ascii", + "clean", + "php" + ], + "support": { + "issues": "https://github.com/voku/portable-ascii/issues", + "source": "https://github.com/voku/portable-ascii/tree/2.0.1" + }, + "funding": [ + { + "url": "https://www.paypal.me/moelleken", + "type": "custom" + }, + { + "url": "https://github.com/voku", + "type": "github" + }, + { + "url": "https://opencollective.com/portable-ascii", + "type": "open_collective" + }, + { + "url": "https://www.patreon.com/voku", + "type": "patreon" + }, + { + "url": "https://tidelift.com/funding/github/packagist/voku/portable-ascii", + "type": "tidelift" + } + ], + "time": "2022-03-08T17:03:00+00:00" + }, + { + "name": "webmozart/assert", + "version": "1.11.0", + "source": { + "type": "git", + "url": "https://github.com/webmozarts/assert.git", + "reference": "11cb2199493b2f8a3b53e7f19068fc6aac760991" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/webmozarts/assert/zipball/11cb2199493b2f8a3b53e7f19068fc6aac760991", + "reference": "11cb2199493b2f8a3b53e7f19068fc6aac760991", + "shasum": "" + }, + "require": { + "ext-ctype": "*", + "php": "^7.2 || ^8.0" + }, + "conflict": { + "phpstan/phpstan": "<0.12.20", + "vimeo/psalm": "<4.6.1 || 4.6.2" + }, + "require-dev": { + "phpunit/phpunit": "^8.5.13" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.10-dev" + } + }, + "autoload": { + "psr-4": { + "Webmozart\\Assert\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Bernhard Schussek", + "email": "bschussek@gmail.com" + } + ], + "description": "Assertions to validate method input/output with nice error messages.", + "keywords": [ + "assert", + "check", + "validate" + ], + "support": { + "issues": "https://github.com/webmozarts/assert/issues", + "source": "https://github.com/webmozarts/assert/tree/1.11.0" + }, + "time": "2022-06-03T18:03:27+00:00" + }, + { + "name": "yajra/laravel-datatables", + "version": "v9.0.0", + "source": { + "type": "git", + "url": "https://github.com/yajra/datatables.git", + "reference": "f16d4c701418d4f60a81e5452933b15b312dde90" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/yajra/datatables/zipball/f16d4c701418d4f60a81e5452933b15b312dde90", + "reference": "f16d4c701418d4f60a81e5452933b15b312dde90", + "shasum": "" + }, + "require": { + "php": "^8.0.2", + "yajra/laravel-datatables-buttons": "9.*", + "yajra/laravel-datatables-editor": "1.*", + "yajra/laravel-datatables-fractal": "9.*", + "yajra/laravel-datatables-html": "9.*", + "yajra/laravel-datatables-oracle": "10.*" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "9.0-dev" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Arjay Angeles", + "email": "aqangeles@gmail.com" + } + ], + "description": "Laravel DataTables Complete Package.", + "keywords": [ + "datatables", + "jquery", + "laravel" + ], + "support": { + "issues": "https://github.com/yajra/datatables/issues", + "source": "https://github.com/yajra/datatables/tree/v9.0.0" + }, + "time": "2022-05-07T16:41:24+00:00" + }, + { + "name": "yajra/laravel-datatables-buttons", + "version": "v9.1.4", + "source": { + "type": "git", + "url": "https://github.com/yajra/laravel-datatables-buttons.git", + "reference": "afc40285b09b0960180b17b96c5429b4be772143" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/yajra/laravel-datatables-buttons/zipball/afc40285b09b0960180b17b96c5429b4be772143", + "reference": "afc40285b09b0960180b17b96c5429b4be772143", + "shasum": "" + }, + "require": { + "illuminate/console": "*", + "php": "^8.0.2", + "yajra/laravel-datatables-html": "9.*", + "yajra/laravel-datatables-oracle": "10.*" + }, + "require-dev": { + "barryvdh/laravel-snappy": "^1.0", + "maatwebsite/excel": "^3.1.40", + "nunomaduro/larastan": "2.1.*", + "orchestra/testbench": "^7.3", + "rap2hpoutre/fast-excel": "^3.2" + }, + "suggest": { + "barryvdh/laravel-snappy": "Allows exporting of dataTable to PDF using the print view.", + "dompdf/dompdf": "Allows exporting of dataTable to PDF using the DomPDF.", + "maatwebsite/excel": "Exporting of dataTables (excel, csv and PDF) using maatwebsite package.", + "rap2hpoutre/fast-excel": "Faster exporting of dataTables using fast-excel package." + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "9.0-dev" + }, + "laravel": { + "providers": [ + "Yajra\\DataTables\\ButtonsServiceProvider" + ] + } + }, + "autoload": { + "psr-4": { + "Yajra\\DataTables\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Arjay Angeles", + "email": "aqangeles@gmail.com" + } + ], + "description": "Laravel DataTables Buttons Plugin.", + "keywords": [ + "buttons", + "datatables", + "jquery", + "laravel" + ], + "support": { + "issues": "https://github.com/yajra/laravel-datatables-buttons/issues", + "source": "https://github.com/yajra/laravel-datatables-buttons/tree/v9.1.4" + }, + "funding": [ + { + "url": "https://www.paypal.me/yajra", + "type": "custom" + }, + { + "url": "https://github.com/yajra", + "type": "github" + }, + { + "url": "https://www.patreon.com/yajra", + "type": "patreon" + } + ], + "time": "2023-02-20T06:11:01+00:00" + }, + { + "name": "yajra/laravel-datatables-editor", + "version": "v1.25.4", + "source": { + "type": "git", + "url": "https://github.com/yajra/laravel-datatables-editor.git", + "reference": "23962356700d6b31f49bb119665b13e87303e13f" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/yajra/laravel-datatables-editor/zipball/23962356700d6b31f49bb119665b13e87303e13f", + "reference": "23962356700d6b31f49bb119665b13e87303e13f", + "shasum": "" + }, + "require": { + "illuminate/console": "*", + "illuminate/database": "*", + "illuminate/http": "*", + "illuminate/validation": "*", + "php": ">=7.0" + }, + "require-dev": { + "orchestra/testbench": "~3.5" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0-dev" + }, + "laravel": { + "providers": [ + "Yajra\\DataTables\\EditorServiceProvider" + ] + } + }, + "autoload": { + "psr-4": { + "Yajra\\DataTables\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Arjay Angeles", + "email": "aqangeles@gmail.com" + } + ], + "description": "Laravel DataTables Editor plugin for Laravel 5.5+.", + "keywords": [ + "JS", + "datatables", + "editor", + "html", + "jquery", + "laravel" + ], + "support": { + "issues": "https://github.com/yajra/laravel-datatables-editor/issues", + "source": "https://github.com/yajra/laravel-datatables-editor/tree/v1.25.4" + }, + "funding": [ + { + "url": "https://www.paypal.me/yajra", + "type": "custom" + }, + { + "url": "https://github.com/yajra", + "type": "github" + }, + { + "url": "https://www.patreon.com/yajra", + "type": "patreon" + } + ], + "time": "2023-02-21T06:57:59+00:00" + }, + { + "name": "yajra/laravel-datatables-fractal", + "version": "v9.1.0", + "source": { + "type": "git", + "url": "https://github.com/yajra/laravel-datatables-fractal.git", + "reference": "4b313041247108650c9ce5deb678defb7e00e794" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/yajra/laravel-datatables-fractal/zipball/4b313041247108650c9ce5deb678defb7e00e794", + "reference": "4b313041247108650c9ce5deb678defb7e00e794", + "shasum": "" + }, + "require": { + "league/fractal": "^0.20.1", + "php": ">=8.0.2", + "yajra/laravel-datatables-oracle": "^10.0" + }, + "require-dev": { + "nunomaduro/larastan": "^2.1", + "orchestra/testbench": "^7.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "9.0-dev" + }, + "laravel": { + "providers": [ + "Yajra\\DataTables\\FractalServiceProvider" + ] + } + }, + "autoload": { + "psr-4": { + "Yajra\\DataTables\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Arjay Angeles", + "email": "aqangeles@gmail.com" + } + ], + "description": "Laravel DataTables Fractal Plugin.", + "keywords": [ + "api", + "datatables", + "fractal", + "laravel" + ], + "support": { + "issues": "https://github.com/yajra/laravel-datatables-fractal/issues", + "source": "https://github.com/yajra/laravel-datatables-fractal/tree/v9.1.0" + }, + "time": "2022-06-20T01:43:31+00:00" + }, + { + "name": "yajra/laravel-datatables-html", + "version": "v9.4.0", + "source": { + "type": "git", + "url": "https://github.com/yajra/laravel-datatables-html.git", + "reference": "cec3e77746ff68f6f51e22250061b59d4ec1311c" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/yajra/laravel-datatables-html/zipball/cec3e77746ff68f6f51e22250061b59d4ec1311c", + "reference": "cec3e77746ff68f6f51e22250061b59d4ec1311c", + "shasum": "" + }, + "require": { + "ext-json": "*", + "laravelcollective/html": "^6.3.0", + "php": "^8.0.2", + "yajra/laravel-datatables-oracle": "^10.0" + }, + "require-dev": { + "nunomaduro/larastan": "^2.1", + "orchestra/testbench": "^7.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "9.0-dev" + }, + "laravel": { + "providers": [ + "Yajra\\DataTables\\HtmlServiceProvider" + ] + } + }, + "autoload": { + "psr-4": { + "Yajra\\DataTables\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Arjay Angeles", + "email": "aqangeles@gmail.com" + } + ], + "description": "Laravel DataTables HTML builder plugin for Laravel 5.4+.", + "keywords": [ + "JS", + "datatables", + "html", + "jquery", + "laravel" + ], + "support": { + "issues": "https://github.com/yajra/laravel-datatables-html/issues", + "source": "https://github.com/yajra/laravel-datatables-html/tree/v9.4.0" + }, + "funding": [ + { + "url": "https://www.paypal.me/yajra", + "type": "custom" + }, + { + "url": "https://github.com/yajra", + "type": "github" + }, + { + "url": "https://www.patreon.com/yajra", + "type": "patreon" + } + ], + "time": "2023-02-20T07:44:43+00:00" + }, + { + "name": "yajra/laravel-datatables-oracle", + "version": "v10.11.4", + "source": { + "type": "git", + "url": "https://github.com/yajra/laravel-datatables.git", + "reference": "a11dc9cf5ec7f7dc68ad0d5959c5e7aec0af29a5" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/yajra/laravel-datatables/zipball/a11dc9cf5ec7f7dc68ad0d5959c5e7aec0af29a5", + "reference": "a11dc9cf5ec7f7dc68ad0d5959c5e7aec0af29a5", + "shasum": "" + }, + "require": { + "illuminate/database": "^9|^10", + "illuminate/filesystem": "^9|^10", + "illuminate/http": "^9|^10", + "illuminate/support": "^9|^10", + "illuminate/view": "^9|^10", + "php": "^8.0.2" + }, + "require-dev": { + "algolia/algoliasearch-client-php": "^3.4", + "larastan/larastan": "^2.4", + "laravel/scout": "^10.5", + "meilisearch/meilisearch-php": "^1.4", + "orchestra/testbench": "^8", + "yajra/laravel-datatables-html": "^9.3.4|^10" + }, + "suggest": { + "yajra/laravel-datatables-buttons": "Plugin for server-side exporting of dataTables.", + "yajra/laravel-datatables-editor": "Plugin to use DataTables Editor (requires a license).", + "yajra/laravel-datatables-export": "Plugin for server-side exporting using livewire and queue worker.", + "yajra/laravel-datatables-fractal": "Plugin for server-side response using Fractal.", + "yajra/laravel-datatables-html": "Plugin for server-side HTML builder of dataTables." + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "10.x-dev" + }, + "laravel": { + "providers": [ + "Yajra\\DataTables\\DataTablesServiceProvider" + ], + "aliases": { + "DataTables": "Yajra\\DataTables\\Facades\\DataTables" + } + } + }, + "autoload": { + "files": [ + "src/helper.php" + ], + "psr-4": { + "Yajra\\DataTables\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Arjay Angeles", + "email": "aqangeles@gmail.com" + } + ], + "description": "jQuery DataTables API for Laravel 4|5|6|7|8|9|10", + "keywords": [ + "datatables", + "jquery", + "laravel" + ], + "support": { + "issues": "https://github.com/yajra/laravel-datatables/issues", + "source": "https://github.com/yajra/laravel-datatables/tree/v10.11.4" + }, + "funding": [ + { + "url": "https://github.com/sponsors/yajra", + "type": "github" + } + ], + "time": "2024-02-28T05:00:23+00:00" + } + ], + "packages-dev": [ + { + "name": "doctrine/instantiator", + "version": "2.0.0", + "source": { + "type": "git", + "url": "https://github.com/doctrine/instantiator.git", + "reference": "c6222283fa3f4ac679f8b9ced9a4e23f163e80d0" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/doctrine/instantiator/zipball/c6222283fa3f4ac679f8b9ced9a4e23f163e80d0", + "reference": "c6222283fa3f4ac679f8b9ced9a4e23f163e80d0", + "shasum": "" + }, + "require": { + "php": "^8.1" + }, + "require-dev": { + "doctrine/coding-standard": "^11", + "ext-pdo": "*", + "ext-phar": "*", + "phpbench/phpbench": "^1.2", + "phpstan/phpstan": "^1.9.4", + "phpstan/phpstan-phpunit": "^1.3", + "phpunit/phpunit": "^9.5.27", + "vimeo/psalm": "^5.4" + }, + "type": "library", + "autoload": { + "psr-4": { + "Doctrine\\Instantiator\\": "src/Doctrine/Instantiator/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Marco Pivetta", + "email": "ocramius@gmail.com", + "homepage": "https://ocramius.github.io/" + } + ], + "description": "A small, lightweight utility to instantiate objects in PHP without invoking their constructors", + "homepage": "https://www.doctrine-project.org/projects/instantiator.html", + "keywords": [ + "constructor", + "instantiate" + ], + "support": { + "issues": "https://github.com/doctrine/instantiator/issues", + "source": "https://github.com/doctrine/instantiator/tree/2.0.0" + }, + "funding": [ + { + "url": "https://www.doctrine-project.org/sponsorship.html", + "type": "custom" + }, + { + "url": "https://www.patreon.com/phpdoctrine", + "type": "patreon" + }, + { + "url": "https://tidelift.com/funding/github/packagist/doctrine%2Finstantiator", + "type": "tidelift" + } + ], + "time": "2022-12-30T00:23:10+00:00" + }, + { + "name": "fakerphp/faker", + "version": "v1.23.1", + "source": { + "type": "git", + "url": "https://github.com/FakerPHP/Faker.git", + "reference": "bfb4fe148adbf78eff521199619b93a52ae3554b" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/FakerPHP/Faker/zipball/bfb4fe148adbf78eff521199619b93a52ae3554b", + "reference": "bfb4fe148adbf78eff521199619b93a52ae3554b", + "shasum": "" + }, + "require": { + "php": "^7.4 || ^8.0", + "psr/container": "^1.0 || ^2.0", + "symfony/deprecation-contracts": "^2.2 || ^3.0" + }, + "conflict": { + "fzaninotto/faker": "*" + }, + "require-dev": { + "bamarni/composer-bin-plugin": "^1.4.1", + "doctrine/persistence": "^1.3 || ^2.0", + "ext-intl": "*", + "phpunit/phpunit": "^9.5.26", + "symfony/phpunit-bridge": "^5.4.16" + }, + "suggest": { + "doctrine/orm": "Required to use Faker\\ORM\\Doctrine", + "ext-curl": "Required by Faker\\Provider\\Image to download images.", + "ext-dom": "Required by Faker\\Provider\\HtmlLorem for generating random HTML.", + "ext-iconv": "Required by Faker\\Provider\\ru_RU\\Text::realText() for generating real Russian text.", + "ext-mbstring": "Required for multibyte Unicode string functionality." + }, + "type": "library", + "autoload": { + "psr-4": { + "Faker\\": "src/Faker/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "François Zaninotto" + } + ], + "description": "Faker is a PHP library that generates fake data for you.", + "keywords": [ + "data", + "faker", + "fixtures" + ], + "support": { + "issues": "https://github.com/FakerPHP/Faker/issues", + "source": "https://github.com/FakerPHP/Faker/tree/v1.23.1" + }, + "time": "2024-01-02T13:46:09+00:00" + }, + { + "name": "filp/whoops", + "version": "2.15.4", + "source": { + "type": "git", + "url": "https://github.com/filp/whoops.git", + "reference": "a139776fa3f5985a50b509f2a02ff0f709d2a546" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/filp/whoops/zipball/a139776fa3f5985a50b509f2a02ff0f709d2a546", + "reference": "a139776fa3f5985a50b509f2a02ff0f709d2a546", + "shasum": "" + }, + "require": { + "php": "^5.5.9 || ^7.0 || ^8.0", + "psr/log": "^1.0.1 || ^2.0 || ^3.0" + }, + "require-dev": { + "mockery/mockery": "^0.9 || ^1.0", + "phpunit/phpunit": "^4.8.36 || ^5.7.27 || ^6.5.14 || ^7.5.20 || ^8.5.8 || ^9.3.3", + "symfony/var-dumper": "^2.6 || ^3.0 || ^4.0 || ^5.0" + }, + "suggest": { + "symfony/var-dumper": "Pretty print complex values better with var-dumper available", + "whoops/soap": "Formats errors as SOAP responses" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.7-dev" + } + }, + "autoload": { + "psr-4": { + "Whoops\\": "src/Whoops/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Filipe Dobreira", + "homepage": "https://github.com/filp", + "role": "Developer" + } + ], + "description": "php error handling for cool kids", + "homepage": "https://filp.github.io/whoops/", + "keywords": [ + "error", + "exception", + "handling", + "library", + "throwable", + "whoops" + ], + "support": { + "issues": "https://github.com/filp/whoops/issues", + "source": "https://github.com/filp/whoops/tree/2.15.4" + }, + "funding": [ + { + "url": "https://github.com/denis-sokolov", + "type": "github" + } + ], + "time": "2023-11-03T12:00:00+00:00" + }, + { + "name": "hamcrest/hamcrest-php", + "version": "v2.0.1", + "source": { + "type": "git", + "url": "https://github.com/hamcrest/hamcrest-php.git", + "reference": "8c3d0a3f6af734494ad8f6fbbee0ba92422859f3" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/hamcrest/hamcrest-php/zipball/8c3d0a3f6af734494ad8f6fbbee0ba92422859f3", + "reference": "8c3d0a3f6af734494ad8f6fbbee0ba92422859f3", + "shasum": "" + }, + "require": { + "php": "^5.3|^7.0|^8.0" + }, + "replace": { + "cordoval/hamcrest-php": "*", + "davedevelopment/hamcrest-php": "*", + "kodova/hamcrest-php": "*" + }, + "require-dev": { + "phpunit/php-file-iterator": "^1.4 || ^2.0", + "phpunit/phpunit": "^4.8.36 || ^5.7 || ^6.5 || ^7.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.1-dev" + } + }, + "autoload": { + "classmap": [ + "hamcrest" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "description": "This is the PHP port of Hamcrest Matchers", + "keywords": [ + "test" + ], + "support": { + "issues": "https://github.com/hamcrest/hamcrest-php/issues", + "source": "https://github.com/hamcrest/hamcrest-php/tree/v2.0.1" + }, + "time": "2020-07-09T08:09:16+00:00" + }, + { + "name": "mockery/mockery", + "version": "1.6.12", + "source": { + "type": "git", + "url": "https://github.com/mockery/mockery.git", + "reference": "1f4efdd7d3beafe9807b08156dfcb176d18f1699" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/mockery/mockery/zipball/1f4efdd7d3beafe9807b08156dfcb176d18f1699", + "reference": "1f4efdd7d3beafe9807b08156dfcb176d18f1699", + "shasum": "" + }, + "require": { + "hamcrest/hamcrest-php": "^2.0.1", + "lib-pcre": ">=7.0", + "php": ">=7.3" + }, + "conflict": { + "phpunit/phpunit": "<8.0" + }, + "require-dev": { + "phpunit/phpunit": "^8.5 || ^9.6.17", + "symplify/easy-coding-standard": "^12.1.14" + }, + "type": "library", + "autoload": { + "files": [ + "library/helpers.php", + "library/Mockery.php" + ], + "psr-4": { + "Mockery\\": "library/Mockery" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Pádraic Brady", + "email": "padraic.brady@gmail.com", + "homepage": "https://github.com/padraic", + "role": "Author" + }, + { + "name": "Dave Marshall", + "email": "dave.marshall@atstsolutions.co.uk", + "homepage": "https://davedevelopment.co.uk", + "role": "Developer" + }, + { + "name": "Nathanael Esayeas", + "email": "nathanael.esayeas@protonmail.com", + "homepage": "https://github.com/ghostwriter", + "role": "Lead Developer" + } + ], + "description": "Mockery is a simple yet flexible PHP mock object framework", + "homepage": "https://github.com/mockery/mockery", + "keywords": [ + "BDD", + "TDD", + "library", + "mock", + "mock objects", + "mockery", + "stub", + "test", + "test double", + "testing" + ], + "support": { + "docs": "https://docs.mockery.io/", + "issues": "https://github.com/mockery/mockery/issues", + "rss": "https://github.com/mockery/mockery/releases.atom", + "security": "https://github.com/mockery/mockery/security/advisories", + "source": "https://github.com/mockery/mockery" + }, + "time": "2024-05-16T03:13:13+00:00" + }, + { + "name": "myclabs/deep-copy", + "version": "1.12.0", + "source": { + "type": "git", + "url": "https://github.com/myclabs/DeepCopy.git", + "reference": "3a6b9a42cd8f8771bd4295d13e1423fa7f3d942c" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/3a6b9a42cd8f8771bd4295d13e1423fa7f3d942c", + "reference": "3a6b9a42cd8f8771bd4295d13e1423fa7f3d942c", + "shasum": "" + }, + "require": { + "php": "^7.1 || ^8.0" + }, + "conflict": { + "doctrine/collections": "<1.6.8", + "doctrine/common": "<2.13.3 || >=3 <3.2.2" + }, + "require-dev": { + "doctrine/collections": "^1.6.8", + "doctrine/common": "^2.13.3 || ^3.2.2", + "phpspec/prophecy": "^1.10", + "phpunit/phpunit": "^7.5.20 || ^8.5.23 || ^9.5.13" + }, + "type": "library", + "autoload": { + "files": [ + "src/DeepCopy/deep_copy.php" + ], + "psr-4": { + "DeepCopy\\": "src/DeepCopy/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "description": "Create deep copies (clones) of your objects", + "keywords": [ + "clone", + "copy", + "duplicate", + "object", + "object graph" + ], + "support": { + "issues": "https://github.com/myclabs/DeepCopy/issues", + "source": "https://github.com/myclabs/DeepCopy/tree/1.12.0" + }, + "funding": [ + { + "url": "https://tidelift.com/funding/github/packagist/myclabs/deep-copy", + "type": "tidelift" + } + ], + "time": "2024-06-12T14:39:25+00:00" + }, + { + "name": "nunomaduro/collision", + "version": "v6.4.0", + "source": { + "type": "git", + "url": "https://github.com/nunomaduro/collision.git", + "reference": "f05978827b9343cba381ca05b8c7deee346b6015" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/nunomaduro/collision/zipball/f05978827b9343cba381ca05b8c7deee346b6015", + "reference": "f05978827b9343cba381ca05b8c7deee346b6015", + "shasum": "" + }, + "require": { + "filp/whoops": "^2.14.5", + "php": "^8.0.0", + "symfony/console": "^6.0.2" + }, + "require-dev": { + "brianium/paratest": "^6.4.1", + "laravel/framework": "^9.26.1", + "laravel/pint": "^1.1.1", + "nunomaduro/larastan": "^1.0.3", + "nunomaduro/mock-final-classes": "^1.1.0", + "orchestra/testbench": "^7.7", + "phpunit/phpunit": "^9.5.23", + "spatie/ignition": "^1.4.1" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-develop": "6.x-dev" + }, + "laravel": { + "providers": [ + "NunoMaduro\\Collision\\Adapters\\Laravel\\CollisionServiceProvider" + ] + } + }, + "autoload": { + "psr-4": { + "NunoMaduro\\Collision\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nuno Maduro", + "email": "enunomaduro@gmail.com" + } + ], + "description": "Cli error handling for console/command-line PHP applications.", + "keywords": [ + "artisan", + "cli", + "command-line", + "console", + "error", + "handling", + "laravel", + "laravel-zero", + "php", + "symfony" + ], + "support": { + "issues": "https://github.com/nunomaduro/collision/issues", + "source": "https://github.com/nunomaduro/collision" + }, + "funding": [ + { + "url": "https://www.paypal.com/paypalme/enunomaduro", + "type": "custom" + }, + { + "url": "https://github.com/nunomaduro", + "type": "github" + }, + { + "url": "https://www.patreon.com/nunomaduro", + "type": "patreon" + } + ], + "time": "2023-01-03T12:54:54+00:00" + }, + { + "name": "phar-io/manifest", + "version": "2.0.4", + "source": { + "type": "git", + "url": "https://github.com/phar-io/manifest.git", + "reference": "54750ef60c58e43759730615a392c31c80e23176" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/phar-io/manifest/zipball/54750ef60c58e43759730615a392c31c80e23176", + "reference": "54750ef60c58e43759730615a392c31c80e23176", + "shasum": "" + }, + "require": { + "ext-dom": "*", + "ext-libxml": "*", + "ext-phar": "*", + "ext-xmlwriter": "*", + "phar-io/version": "^3.0.1", + "php": "^7.2 || ^8.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.0.x-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Arne Blankerts", + "email": "arne@blankerts.de", + "role": "Developer" + }, + { + "name": "Sebastian Heuer", + "email": "sebastian@phpeople.de", + "role": "Developer" + }, + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "Developer" + } + ], + "description": "Component for reading phar.io manifest information from a PHP Archive (PHAR)", + "support": { + "issues": "https://github.com/phar-io/manifest/issues", + "source": "https://github.com/phar-io/manifest/tree/2.0.4" + }, + "funding": [ + { + "url": "https://github.com/theseer", + "type": "github" + } + ], + "time": "2024-03-03T12:33:53+00:00" + }, + { + "name": "phar-io/version", + "version": "3.2.1", + "source": { + "type": "git", + "url": "https://github.com/phar-io/version.git", + "reference": "4f7fd7836c6f332bb2933569e566a0d6c4cbed74" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/phar-io/version/zipball/4f7fd7836c6f332bb2933569e566a0d6c4cbed74", + "reference": "4f7fd7836c6f332bb2933569e566a0d6c4cbed74", + "shasum": "" + }, + "require": { + "php": "^7.2 || ^8.0" + }, + "type": "library", + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Arne Blankerts", + "email": "arne@blankerts.de", + "role": "Developer" + }, + { + "name": "Sebastian Heuer", + "email": "sebastian@phpeople.de", + "role": "Developer" + }, + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "Developer" + } + ], + "description": "Library for handling version information and constraints", + "support": { + "issues": "https://github.com/phar-io/version/issues", + "source": "https://github.com/phar-io/version/tree/3.2.1" + }, + "time": "2022-02-21T01:04:05+00:00" + }, + { + "name": "phpunit/php-code-coverage", + "version": "9.2.31", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/php-code-coverage.git", + "reference": "48c34b5d8d983006bd2adc2d0de92963b9155965" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/48c34b5d8d983006bd2adc2d0de92963b9155965", + "reference": "48c34b5d8d983006bd2adc2d0de92963b9155965", + "shasum": "" + }, + "require": { + "ext-dom": "*", + "ext-libxml": "*", + "ext-xmlwriter": "*", + "nikic/php-parser": "^4.18 || ^5.0", + "php": ">=7.3", + "phpunit/php-file-iterator": "^3.0.3", + "phpunit/php-text-template": "^2.0.2", + "sebastian/code-unit-reverse-lookup": "^2.0.2", + "sebastian/complexity": "^2.0", + "sebastian/environment": "^5.1.2", + "sebastian/lines-of-code": "^1.0.3", + "sebastian/version": "^3.0.1", + "theseer/tokenizer": "^1.2.0" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "suggest": { + "ext-pcov": "PHP extension that provides line coverage", + "ext-xdebug": "PHP extension that provides line coverage as well as branch and path coverage" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "9.2-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Library that provides collection, processing, and rendering functionality for PHP code coverage information.", + "homepage": "https://github.com/sebastianbergmann/php-code-coverage", + "keywords": [ + "coverage", + "testing", + "xunit" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/php-code-coverage/issues", + "security": "https://github.com/sebastianbergmann/php-code-coverage/security/policy", + "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/9.2.31" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2024-03-02T06:37:42+00:00" + }, + { + "name": "phpunit/php-file-iterator", + "version": "3.0.6", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/php-file-iterator.git", + "reference": "cf1c2e7c203ac650e352f4cc675a7021e7d1b3cf" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/cf1c2e7c203ac650e352f4cc675a7021e7d1b3cf", + "reference": "cf1c2e7c203ac650e352f4cc675a7021e7d1b3cf", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "3.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "FilterIterator implementation that filters files based on a list of suffixes.", + "homepage": "https://github.com/sebastianbergmann/php-file-iterator/", + "keywords": [ + "filesystem", + "iterator" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/php-file-iterator/issues", + "source": "https://github.com/sebastianbergmann/php-file-iterator/tree/3.0.6" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2021-12-02T12:48:52+00:00" + }, + { + "name": "phpunit/php-invoker", + "version": "3.1.1", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/php-invoker.git", + "reference": "5a10147d0aaf65b58940a0b72f71c9ac0423cc67" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/php-invoker/zipball/5a10147d0aaf65b58940a0b72f71c9ac0423cc67", + "reference": "5a10147d0aaf65b58940a0b72f71c9ac0423cc67", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "ext-pcntl": "*", + "phpunit/phpunit": "^9.3" + }, + "suggest": { + "ext-pcntl": "*" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "3.1-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Invoke callables with a timeout", + "homepage": "https://github.com/sebastianbergmann/php-invoker/", + "keywords": [ + "process" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/php-invoker/issues", + "source": "https://github.com/sebastianbergmann/php-invoker/tree/3.1.1" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-09-28T05:58:55+00:00" + }, + { + "name": "phpunit/php-text-template", + "version": "2.0.4", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/php-text-template.git", + "reference": "5da5f67fc95621df9ff4c4e5a84d6a8a2acf7c28" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/php-text-template/zipball/5da5f67fc95621df9ff4c4e5a84d6a8a2acf7c28", + "reference": "5da5f67fc95621df9ff4c4e5a84d6a8a2acf7c28", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Simple template engine.", + "homepage": "https://github.com/sebastianbergmann/php-text-template/", + "keywords": [ + "template" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/php-text-template/issues", + "source": "https://github.com/sebastianbergmann/php-text-template/tree/2.0.4" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-10-26T05:33:50+00:00" + }, + { + "name": "phpunit/php-timer", + "version": "5.0.3", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/php-timer.git", + "reference": "5a63ce20ed1b5bf577850e2c4e87f4aa902afbd2" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/php-timer/zipball/5a63ce20ed1b5bf577850e2c4e87f4aa902afbd2", + "reference": "5a63ce20ed1b5bf577850e2c4e87f4aa902afbd2", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "5.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Utility class for timing", + "homepage": "https://github.com/sebastianbergmann/php-timer/", + "keywords": [ + "timer" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/php-timer/issues", + "source": "https://github.com/sebastianbergmann/php-timer/tree/5.0.3" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-10-26T13:16:10+00:00" + }, + { + "name": "phpunit/phpunit", + "version": "9.6.19", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/phpunit.git", + "reference": "a1a54a473501ef4cdeaae4e06891674114d79db8" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/a1a54a473501ef4cdeaae4e06891674114d79db8", + "reference": "a1a54a473501ef4cdeaae4e06891674114d79db8", + "shasum": "" + }, + "require": { + "doctrine/instantiator": "^1.3.1 || ^2", + "ext-dom": "*", + "ext-json": "*", + "ext-libxml": "*", + "ext-mbstring": "*", + "ext-xml": "*", + "ext-xmlwriter": "*", + "myclabs/deep-copy": "^1.10.1", + "phar-io/manifest": "^2.0.3", + "phar-io/version": "^3.0.2", + "php": ">=7.3", + "phpunit/php-code-coverage": "^9.2.28", + "phpunit/php-file-iterator": "^3.0.5", + "phpunit/php-invoker": "^3.1.1", + "phpunit/php-text-template": "^2.0.3", + "phpunit/php-timer": "^5.0.2", + "sebastian/cli-parser": "^1.0.1", + "sebastian/code-unit": "^1.0.6", + "sebastian/comparator": "^4.0.8", + "sebastian/diff": "^4.0.3", + "sebastian/environment": "^5.1.3", + "sebastian/exporter": "^4.0.5", + "sebastian/global-state": "^5.0.1", + "sebastian/object-enumerator": "^4.0.3", + "sebastian/resource-operations": "^3.0.3", + "sebastian/type": "^3.2", + "sebastian/version": "^3.0.2" + }, + "suggest": { + "ext-soap": "To be able to generate mocks based on WSDL files", + "ext-xdebug": "PHP extension that provides line coverage as well as branch and path coverage" + }, + "bin": [ + "phpunit" + ], + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "9.6-dev" + } + }, + "autoload": { + "files": [ + "src/Framework/Assert/Functions.php" + ], + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "The PHP Unit Testing framework.", + "homepage": "https://phpunit.de/", + "keywords": [ + "phpunit", + "testing", + "xunit" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/phpunit/issues", + "security": "https://github.com/sebastianbergmann/phpunit/security/policy", + "source": "https://github.com/sebastianbergmann/phpunit/tree/9.6.19" + }, + "funding": [ + { + "url": "https://phpunit.de/sponsors.html", + "type": "custom" + }, + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/phpunit/phpunit", + "type": "tidelift" + } + ], + "time": "2024-04-05T04:35:58+00:00" + }, + { + "name": "sebastian/cli-parser", + "version": "1.0.2", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/cli-parser.git", + "reference": "2b56bea83a09de3ac06bb18b92f068e60cc6f50b" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/cli-parser/zipball/2b56bea83a09de3ac06bb18b92f068e60cc6f50b", + "reference": "2b56bea83a09de3ac06bb18b92f068e60cc6f50b", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Library for parsing CLI options", + "homepage": "https://github.com/sebastianbergmann/cli-parser", + "support": { + "issues": "https://github.com/sebastianbergmann/cli-parser/issues", + "source": "https://github.com/sebastianbergmann/cli-parser/tree/1.0.2" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2024-03-02T06:27:43+00:00" + }, + { + "name": "sebastian/code-unit", + "version": "1.0.8", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/code-unit.git", + "reference": "1fc9f64c0927627ef78ba436c9b17d967e68e120" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/code-unit/zipball/1fc9f64c0927627ef78ba436c9b17d967e68e120", + "reference": "1fc9f64c0927627ef78ba436c9b17d967e68e120", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Collection of value objects that represent the PHP code units", + "homepage": "https://github.com/sebastianbergmann/code-unit", + "support": { + "issues": "https://github.com/sebastianbergmann/code-unit/issues", + "source": "https://github.com/sebastianbergmann/code-unit/tree/1.0.8" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-10-26T13:08:54+00:00" + }, + { + "name": "sebastian/code-unit-reverse-lookup", + "version": "2.0.3", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/code-unit-reverse-lookup.git", + "reference": "ac91f01ccec49fb77bdc6fd1e548bc70f7faa3e5" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/code-unit-reverse-lookup/zipball/ac91f01ccec49fb77bdc6fd1e548bc70f7faa3e5", + "reference": "ac91f01ccec49fb77bdc6fd1e548bc70f7faa3e5", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" + } + ], + "description": "Looks up which function or method a line of code belongs to", + "homepage": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/", + "support": { + "issues": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/issues", + "source": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/tree/2.0.3" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-09-28T05:30:19+00:00" + }, + { + "name": "sebastian/comparator", + "version": "4.0.8", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/comparator.git", + "reference": "fa0f136dd2334583309d32b62544682ee972b51a" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/fa0f136dd2334583309d32b62544682ee972b51a", + "reference": "fa0f136dd2334583309d32b62544682ee972b51a", + "shasum": "" + }, + "require": { + "php": ">=7.3", + "sebastian/diff": "^4.0", + "sebastian/exporter": "^4.0" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" + }, + { + "name": "Jeff Welch", + "email": "whatthejeff@gmail.com" + }, + { + "name": "Volker Dusch", + "email": "github@wallbash.com" + }, + { + "name": "Bernhard Schussek", + "email": "bschussek@2bepublished.at" + } + ], + "description": "Provides the functionality to compare PHP values for equality", + "homepage": "https://github.com/sebastianbergmann/comparator", + "keywords": [ + "comparator", + "compare", + "equality" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/comparator/issues", + "source": "https://github.com/sebastianbergmann/comparator/tree/4.0.8" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2022-09-14T12:41:17+00:00" + }, + { + "name": "sebastian/complexity", + "version": "2.0.3", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/complexity.git", + "reference": "25f207c40d62b8b7aa32f5ab026c53561964053a" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/complexity/zipball/25f207c40d62b8b7aa32f5ab026c53561964053a", + "reference": "25f207c40d62b8b7aa32f5ab026c53561964053a", + "shasum": "" + }, + "require": { + "nikic/php-parser": "^4.18 || ^5.0", + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Library for calculating the complexity of PHP code units", + "homepage": "https://github.com/sebastianbergmann/complexity", + "support": { + "issues": "https://github.com/sebastianbergmann/complexity/issues", + "source": "https://github.com/sebastianbergmann/complexity/tree/2.0.3" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2023-12-22T06:19:30+00:00" + }, + { + "name": "sebastian/diff", + "version": "4.0.6", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/diff.git", + "reference": "ba01945089c3a293b01ba9badc29ad55b106b0bc" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/ba01945089c3a293b01ba9badc29ad55b106b0bc", + "reference": "ba01945089c3a293b01ba9badc29ad55b106b0bc", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3", + "symfony/process": "^4.2 || ^5" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" + }, + { + "name": "Kore Nordmann", + "email": "mail@kore-nordmann.de" + } + ], + "description": "Diff implementation", + "homepage": "https://github.com/sebastianbergmann/diff", + "keywords": [ + "diff", + "udiff", + "unidiff", + "unified diff" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/diff/issues", + "source": "https://github.com/sebastianbergmann/diff/tree/4.0.6" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2024-03-02T06:30:58+00:00" + }, + { + "name": "sebastian/environment", + "version": "5.1.5", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/environment.git", + "reference": "830c43a844f1f8d5b7a1f6d6076b784454d8b7ed" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/830c43a844f1f8d5b7a1f6d6076b784454d8b7ed", + "reference": "830c43a844f1f8d5b7a1f6d6076b784454d8b7ed", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "suggest": { + "ext-posix": "*" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "5.1-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" + } + ], + "description": "Provides functionality to handle HHVM/PHP environments", + "homepage": "http://www.github.com/sebastianbergmann/environment", + "keywords": [ + "Xdebug", + "environment", + "hhvm" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/environment/issues", + "source": "https://github.com/sebastianbergmann/environment/tree/5.1.5" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2023-02-03T06:03:51+00:00" + }, + { + "name": "sebastian/exporter", + "version": "4.0.6", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/exporter.git", + "reference": "78c00df8f170e02473b682df15bfcdacc3d32d72" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/78c00df8f170e02473b682df15bfcdacc3d32d72", + "reference": "78c00df8f170e02473b682df15bfcdacc3d32d72", + "shasum": "" + }, + "require": { + "php": ">=7.3", + "sebastian/recursion-context": "^4.0" + }, + "require-dev": { + "ext-mbstring": "*", + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" + }, + { + "name": "Jeff Welch", + "email": "whatthejeff@gmail.com" + }, + { + "name": "Volker Dusch", + "email": "github@wallbash.com" + }, + { + "name": "Adam Harvey", + "email": "aharvey@php.net" + }, + { + "name": "Bernhard Schussek", + "email": "bschussek@gmail.com" + } + ], + "description": "Provides the functionality to export PHP variables for visualization", + "homepage": "https://www.github.com/sebastianbergmann/exporter", + "keywords": [ + "export", + "exporter" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/exporter/issues", + "source": "https://github.com/sebastianbergmann/exporter/tree/4.0.6" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2024-03-02T06:33:00+00:00" + }, + { + "name": "sebastian/global-state", + "version": "5.0.7", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/global-state.git", + "reference": "bca7df1f32ee6fe93b4d4a9abbf69e13a4ada2c9" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/bca7df1f32ee6fe93b4d4a9abbf69e13a4ada2c9", + "reference": "bca7df1f32ee6fe93b4d4a9abbf69e13a4ada2c9", + "shasum": "" + }, + "require": { + "php": ">=7.3", + "sebastian/object-reflector": "^2.0", + "sebastian/recursion-context": "^4.0" + }, + "require-dev": { + "ext-dom": "*", + "phpunit/phpunit": "^9.3" + }, + "suggest": { + "ext-uopz": "*" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "5.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" + } + ], + "description": "Snapshotting of global state", + "homepage": "http://www.github.com/sebastianbergmann/global-state", + "keywords": [ + "global state" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/global-state/issues", + "source": "https://github.com/sebastianbergmann/global-state/tree/5.0.7" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2024-03-02T06:35:11+00:00" + }, + { + "name": "sebastian/lines-of-code", + "version": "1.0.4", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/lines-of-code.git", + "reference": "e1e4a170560925c26d424b6a03aed157e7dcc5c5" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/lines-of-code/zipball/e1e4a170560925c26d424b6a03aed157e7dcc5c5", + "reference": "e1e4a170560925c26d424b6a03aed157e7dcc5c5", + "shasum": "" + }, + "require": { + "nikic/php-parser": "^4.18 || ^5.0", + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Library for counting the lines of code in PHP source code", + "homepage": "https://github.com/sebastianbergmann/lines-of-code", + "support": { + "issues": "https://github.com/sebastianbergmann/lines-of-code/issues", + "source": "https://github.com/sebastianbergmann/lines-of-code/tree/1.0.4" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2023-12-22T06:20:34+00:00" + }, + { + "name": "sebastian/object-enumerator", + "version": "4.0.4", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/object-enumerator.git", + "reference": "5c9eeac41b290a3712d88851518825ad78f45c71" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/object-enumerator/zipball/5c9eeac41b290a3712d88851518825ad78f45c71", + "reference": "5c9eeac41b290a3712d88851518825ad78f45c71", + "shasum": "" + }, + "require": { + "php": ">=7.3", + "sebastian/object-reflector": "^2.0", + "sebastian/recursion-context": "^4.0" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" + } + ], + "description": "Traverses array structures and object graphs to enumerate all referenced objects", + "homepage": "https://github.com/sebastianbergmann/object-enumerator/", + "support": { + "issues": "https://github.com/sebastianbergmann/object-enumerator/issues", + "source": "https://github.com/sebastianbergmann/object-enumerator/tree/4.0.4" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-10-26T13:12:34+00:00" + }, + { + "name": "sebastian/object-reflector", + "version": "2.0.4", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/object-reflector.git", + "reference": "b4f479ebdbf63ac605d183ece17d8d7fe49c15c7" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/object-reflector/zipball/b4f479ebdbf63ac605d183ece17d8d7fe49c15c7", + "reference": "b4f479ebdbf63ac605d183ece17d8d7fe49c15c7", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" + } + ], + "description": "Allows reflection of object attributes, including inherited and non-public ones", + "homepage": "https://github.com/sebastianbergmann/object-reflector/", + "support": { + "issues": "https://github.com/sebastianbergmann/object-reflector/issues", + "source": "https://github.com/sebastianbergmann/object-reflector/tree/2.0.4" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-10-26T13:14:26+00:00" + }, + { + "name": "sebastian/recursion-context", + "version": "4.0.5", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/recursion-context.git", + "reference": "e75bd0f07204fec2a0af9b0f3cfe97d05f92efc1" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/e75bd0f07204fec2a0af9b0f3cfe97d05f92efc1", + "reference": "e75bd0f07204fec2a0af9b0f3cfe97d05f92efc1", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" + }, + { + "name": "Jeff Welch", + "email": "whatthejeff@gmail.com" + }, + { + "name": "Adam Harvey", + "email": "aharvey@php.net" + } + ], + "description": "Provides functionality to recursively process PHP variables", + "homepage": "https://github.com/sebastianbergmann/recursion-context", + "support": { + "issues": "https://github.com/sebastianbergmann/recursion-context/issues", + "source": "https://github.com/sebastianbergmann/recursion-context/tree/4.0.5" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2023-02-03T06:07:39+00:00" + }, + { + "name": "sebastian/resource-operations", + "version": "3.0.4", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/resource-operations.git", + "reference": "05d5692a7993ecccd56a03e40cd7e5b09b1d404e" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/resource-operations/zipball/05d5692a7993ecccd56a03e40cd7e5b09b1d404e", + "reference": "05d5692a7993ecccd56a03e40cd7e5b09b1d404e", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "3.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" + } + ], + "description": "Provides a list of PHP built-in functions that operate on resources", + "homepage": "https://www.github.com/sebastianbergmann/resource-operations", + "support": { + "source": "https://github.com/sebastianbergmann/resource-operations/tree/3.0.4" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2024-03-14T16:00:52+00:00" + }, + { + "name": "sebastian/type", + "version": "3.2.1", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/type.git", + "reference": "75e2c2a32f5e0b3aef905b9ed0b179b953b3d7c7" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/type/zipball/75e2c2a32f5e0b3aef905b9ed0b179b953b3d7c7", + "reference": "75e2c2a32f5e0b3aef905b9ed0b179b953b3d7c7", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.5" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "3.2-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Collection of value objects that represent the types of the PHP type system", + "homepage": "https://github.com/sebastianbergmann/type", + "support": { + "issues": "https://github.com/sebastianbergmann/type/issues", + "source": "https://github.com/sebastianbergmann/type/tree/3.2.1" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2023-02-03T06:13:03+00:00" + }, + { + "name": "sebastian/version", + "version": "3.0.2", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/version.git", + "reference": "c6c1022351a901512170118436c764e473f6de8c" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/version/zipball/c6c1022351a901512170118436c764e473f6de8c", + "reference": "c6c1022351a901512170118436c764e473f6de8c", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "3.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Library that helps with managing the version number of Git-hosted PHP projects", + "homepage": "https://github.com/sebastianbergmann/version", + "support": { + "issues": "https://github.com/sebastianbergmann/version/issues", + "source": "https://github.com/sebastianbergmann/version/tree/3.0.2" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-09-28T06:39:44+00:00" + }, + { + "name": "spatie/backtrace", + "version": "1.6.1", + "source": { + "type": "git", + "url": "https://github.com/spatie/backtrace.git", + "reference": "8373b9d51638292e3bfd736a9c19a654111b4a23" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/spatie/backtrace/zipball/8373b9d51638292e3bfd736a9c19a654111b4a23", + "reference": "8373b9d51638292e3bfd736a9c19a654111b4a23", + "shasum": "" + }, + "require": { + "php": "^7.3|^8.0" + }, + "require-dev": { + "ext-json": "*", + "laravel/serializable-closure": "^1.3", + "phpunit/phpunit": "^9.3", + "spatie/phpunit-snapshot-assertions": "^4.2", + "symfony/var-dumper": "^5.1" + }, + "type": "library", + "autoload": { + "psr-4": { + "Spatie\\Backtrace\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Freek Van de Herten", + "email": "freek@spatie.be", + "homepage": "https://spatie.be", + "role": "Developer" + } + ], + "description": "A better backtrace", + "homepage": "https://github.com/spatie/backtrace", + "keywords": [ + "Backtrace", + "spatie" + ], + "support": { + "source": "https://github.com/spatie/backtrace/tree/1.6.1" + }, + "funding": [ + { + "url": "https://github.com/sponsors/spatie", + "type": "github" + }, + { + "url": "https://spatie.be/open-source/support-us", + "type": "other" + } + ], + "time": "2024-04-24T13:22:11+00:00" + }, + { + "name": "spatie/flare-client-php", + "version": "1.7.0", + "source": { + "type": "git", + "url": "https://github.com/spatie/flare-client-php.git", + "reference": "097040ff51e660e0f6fc863684ac4b02c93fa234" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/spatie/flare-client-php/zipball/097040ff51e660e0f6fc863684ac4b02c93fa234", + "reference": "097040ff51e660e0f6fc863684ac4b02c93fa234", + "shasum": "" + }, + "require": { + "illuminate/pipeline": "^8.0|^9.0|^10.0|^11.0", + "php": "^8.0", + "spatie/backtrace": "^1.6.1", + "symfony/http-foundation": "^5.2|^6.0|^7.0", + "symfony/mime": "^5.2|^6.0|^7.0", + "symfony/process": "^5.2|^6.0|^7.0", + "symfony/var-dumper": "^5.2|^6.0|^7.0" + }, + "require-dev": { + "dms/phpunit-arraysubset-asserts": "^0.5.0", + "pestphp/pest": "^1.20|^2.0", + "phpstan/extension-installer": "^1.1", + "phpstan/phpstan-deprecation-rules": "^1.0", + "phpstan/phpstan-phpunit": "^1.0", + "spatie/phpunit-snapshot-assertions": "^4.0|^5.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "1.3.x-dev" + } + }, + "autoload": { + "files": [ + "src/helpers.php" + ], + "psr-4": { + "Spatie\\FlareClient\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "description": "Send PHP errors to Flare", + "homepage": "https://github.com/spatie/flare-client-php", + "keywords": [ + "exception", + "flare", + "reporting", + "spatie" + ], + "support": { + "issues": "https://github.com/spatie/flare-client-php/issues", + "source": "https://github.com/spatie/flare-client-php/tree/1.7.0" + }, + "funding": [ + { + "url": "https://github.com/spatie", + "type": "github" + } + ], + "time": "2024-06-12T14:39:14+00:00" + }, + { + "name": "spatie/ignition", + "version": "1.14.2", + "source": { + "type": "git", + "url": "https://github.com/spatie/ignition.git", + "reference": "5e11c11f675bb5251f061491a493e04a1a571532" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/spatie/ignition/zipball/5e11c11f675bb5251f061491a493e04a1a571532", + "reference": "5e11c11f675bb5251f061491a493e04a1a571532", + "shasum": "" + }, + "require": { + "ext-json": "*", + "ext-mbstring": "*", + "php": "^8.0", + "spatie/backtrace": "^1.5.3", + "spatie/flare-client-php": "^1.4.0", + "symfony/console": "^5.4|^6.0|^7.0", + "symfony/var-dumper": "^5.4|^6.0|^7.0" + }, + "require-dev": { + "illuminate/cache": "^9.52|^10.0|^11.0", + "mockery/mockery": "^1.4", + "pestphp/pest": "^1.20|^2.0", + "phpstan/extension-installer": "^1.1", + "phpstan/phpstan-deprecation-rules": "^1.0", + "phpstan/phpstan-phpunit": "^1.0", + "psr/simple-cache-implementation": "*", + "symfony/cache": "^5.4|^6.0|^7.0", + "symfony/process": "^5.4|^6.0|^7.0", + "vlucas/phpdotenv": "^5.5" + }, + "suggest": { + "openai-php/client": "Require get solutions from OpenAI", + "simple-cache-implementation": "To cache solutions from OpenAI" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "1.5.x-dev" + } + }, + "autoload": { + "psr-4": { + "Spatie\\Ignition\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Spatie", + "email": "info@spatie.be", + "role": "Developer" + } + ], + "description": "A beautiful error page for PHP applications.", + "homepage": "https://flareapp.io/ignition", + "keywords": [ + "error", + "flare", + "laravel", + "page" + ], + "support": { + "docs": "https://flareapp.io/docs/ignition-for-laravel/introduction", + "forum": "https://twitter.com/flareappio", + "issues": "https://github.com/spatie/ignition/issues", + "source": "https://github.com/spatie/ignition" + }, + "funding": [ + { + "url": "https://github.com/spatie", + "type": "github" + } + ], + "time": "2024-05-29T08:10:20+00:00" + }, + { + "name": "spatie/laravel-ignition", + "version": "1.7.0", + "source": { + "type": "git", + "url": "https://github.com/spatie/laravel-ignition.git", + "reference": "b6d5c33cf0b8260d6540572af2d9bcf9182fe5fb" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/spatie/laravel-ignition/zipball/b6d5c33cf0b8260d6540572af2d9bcf9182fe5fb", + "reference": "b6d5c33cf0b8260d6540572af2d9bcf9182fe5fb", + "shasum": "" + }, + "require": { + "ext-curl": "*", + "ext-json": "*", + "ext-mbstring": "*", + "illuminate/support": "^8.77|^9.27", + "monolog/monolog": "^2.3", + "php": "^8.0", + "spatie/flare-client-php": "^1.0.1", + "spatie/ignition": "<= 1.14.2", + "symfony/console": "^5.0|^6.0", + "symfony/var-dumper": "^5.0|^6.0" + }, + "require-dev": { + "filp/whoops": "^2.14", + "livewire/livewire": "^2.8|dev-develop", + "mockery/mockery": "^1.4", + "nunomaduro/larastan": "^1.0", + "orchestra/testbench": "^6.23|^7.0", + "pestphp/pest": "^1.20", + "phpstan/extension-installer": "^1.1", + "phpstan/phpstan-deprecation-rules": "^1.0", + "phpstan/phpstan-phpunit": "^1.0", + "spatie/laravel-ray": "^1.27" + }, + "type": "library", + "extra": { + "laravel": { + "providers": [ + "Spatie\\LaravelIgnition\\IgnitionServiceProvider" + ], + "aliases": { + "Flare": "Spatie\\LaravelIgnition\\Facades\\Flare" + } + } + }, + "autoload": { + "files": [ + "src/helpers.php" + ], + "psr-4": { + "Spatie\\LaravelIgnition\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Spatie", + "email": "info@spatie.be", + "role": "Developer" + } + ], + "description": "A beautiful error page for Laravel applications.", + "homepage": "https://flareapp.io/ignition", + "keywords": [ + "error", + "flare", + "laravel", + "page" + ], + "support": { + "docs": "https://flareapp.io/docs/ignition-for-laravel/introduction", + "forum": "https://twitter.com/flareappio", + "issues": "https://github.com/spatie/laravel-ignition/issues", + "source": "https://github.com/spatie/laravel-ignition" + }, + "funding": [ + { + "url": "https://github.com/spatie", + "type": "github" + } + ], + "time": "2024-06-13T07:21:06+00:00" + }, + { + "name": "theseer/tokenizer", + "version": "1.2.3", + "source": { + "type": "git", + "url": "https://github.com/theseer/tokenizer.git", + "reference": "737eda637ed5e28c3413cb1ebe8bb52cbf1ca7a2" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/theseer/tokenizer/zipball/737eda637ed5e28c3413cb1ebe8bb52cbf1ca7a2", + "reference": "737eda637ed5e28c3413cb1ebe8bb52cbf1ca7a2", + "shasum": "" + }, + "require": { + "ext-dom": "*", + "ext-tokenizer": "*", + "ext-xmlwriter": "*", + "php": "^7.2 || ^8.0" + }, + "type": "library", + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Arne Blankerts", + "email": "arne@blankerts.de", + "role": "Developer" + } + ], + "description": "A small library for converting tokenized PHP source code into XML and potentially other formats", + "support": { + "issues": "https://github.com/theseer/tokenizer/issues", + "source": "https://github.com/theseer/tokenizer/tree/1.2.3" + }, + "funding": [ + { + "url": "https://github.com/theseer", + "type": "github" + } + ], + "time": "2024-03-03T12:36:25+00:00" + } + ], + "aliases": [], + "minimum-stability": "dev", + "stability-flags": [], + "prefer-stable": true, + "prefer-lowest": false, + "platform": { + "php": "^8.0.2|^8.2.0" + }, + "platform-dev": [], + "plugin-api-version": "2.6.0" +} diff --git a/config/app.php b/config/app.php new file mode 100755 index 0000000..f806a1e --- /dev/null +++ b/config/app.php @@ -0,0 +1,229 @@ + env("APP_NAME", "Laravel"), + + /* + |-------------------------------------------------------------------------- + | Application Environment + |-------------------------------------------------------------------------- + | + | This value determines the "environment" your application is currently + | running in. This may determine how you prefer to configure various + | services the application utilizes. Set this in your ".env" file. + | + */ + + "env" => env("APP_ENV", "production"), + + /* + |-------------------------------------------------------------------------- + | Application Debug Mode + |-------------------------------------------------------------------------- + | + | When your application is in debug mode, detailed error messages with + | stack traces will be shown on every error that occurs within your + | application. If disabled, a simple generic error page is shown. + | + */ + + "debug" => (bool) env("APP_DEBUG", false), + + /* + |-------------------------------------------------------------------------- + | Application URL + |-------------------------------------------------------------------------- + | + | This URL is used by the console to properly generate URLs when using + | the Artisan command line tool. You should set this to the root of + | your application so that it is used when running Artisan tasks. + | + */ + + "url" => env("APP_URL", "http://localhost"), + + "asset_url" => env("ASSET_URL", null), + + /* + |-------------------------------------------------------------------------- + | Application Timezone + |-------------------------------------------------------------------------- + | + | Here you may specify the default timezone for your application, which + | will be used by the PHP date and date-time functions. We have gone + | ahead and set this to a sensible default for you out of the box. + | + */ + + "timezone" => env("APP_TIMEZONE", "Asia/Jakarta"), // UTC + + /* + |-------------------------------------------------------------------------- + | Application Locale Configuration + |-------------------------------------------------------------------------- + | + | The application locale determines the default locale that will be used + | by the translation service provider. You are free to set this value + | to any of the locales which will be supported by the application. + | + */ + + "locale" => "en", // en + + /* + |-------------------------------------------------------------------------- + | Application Fallback Locale + |-------------------------------------------------------------------------- + | + | The fallback locale determines the locale to use when the current one + | is not available. You may change the value to correspond to any of + | the language folders that are provided through your application. + | + */ + + "fallback_locale" => "en", // en + + /* + |-------------------------------------------------------------------------- + | Faker Locale + |-------------------------------------------------------------------------- + | + | This locale will be used by the Faker PHP library when generating fake + | data for your database seeds. For example, this will be used to get + | localized telephone numbers, street address information and more. + | + */ + + "faker_locale" => "en_US", // en_US + + /* + |-------------------------------------------------------------------------- + | Encryption Key + |-------------------------------------------------------------------------- + | + | This key is used by the Illuminate encrypter service and should be set + | to a random, 32 character string, otherwise these encrypted strings + | will not be safe. Please do this before deploying an application! + | + */ + + "key" => env("APP_KEY"), + + "cipher" => "AES-256-CBC", + + /* + |-------------------------------------------------------------------------- + | Autoloaded Service Providers + |-------------------------------------------------------------------------- + | + | The service providers listed here will be automatically loaded on the + | request to your application. Feel free to add your own services to + | this array to grant expanded functionality to your applications. + | + */ + + "providers" => [ + /* + * Laravel Framework Service Providers... + */ + Illuminate\Auth\AuthServiceProvider::class, + Illuminate\Broadcasting\BroadcastServiceProvider::class, + Illuminate\Bus\BusServiceProvider::class, + Illuminate\Cache\CacheServiceProvider::class, + Illuminate\Foundation\Providers\ConsoleSupportServiceProvider::class, + Illuminate\Cookie\CookieServiceProvider::class, + Illuminate\Database\DatabaseServiceProvider::class, + Illuminate\Encryption\EncryptionServiceProvider::class, + Illuminate\Filesystem\FilesystemServiceProvider::class, + Illuminate\Foundation\Providers\FoundationServiceProvider::class, + Illuminate\Hashing\HashServiceProvider::class, + Illuminate\Mail\MailServiceProvider::class, + Illuminate\Notifications\NotificationServiceProvider::class, + Illuminate\Pagination\PaginationServiceProvider::class, + Illuminate\Pipeline\PipelineServiceProvider::class, + Illuminate\Queue\QueueServiceProvider::class, + Illuminate\Redis\RedisServiceProvider::class, + Illuminate\Auth\Passwords\PasswordResetServiceProvider::class, + Illuminate\Session\SessionServiceProvider::class, + Illuminate\Translation\TranslationServiceProvider::class, + Illuminate\Validation\ValidationServiceProvider::class, + Illuminate\View\ViewServiceProvider::class, + Yajra\DataTables\DatatablesServiceProvider::class, + // Barryvdh\DomPDF\ServiceProvider::class, + + /* + * Package Service Providers... + */ + + /* + * Application Service Providers... + */ + App\Providers\AppServiceProvider::class, + App\Providers\AuthServiceProvider::class, + // App\Providers\BroadcastServiceProvider::class, + App\Providers\EventServiceProvider::class, + App\Providers\RouteServiceProvider::class, + ], + + /* + |-------------------------------------------------------------------------- + | Class Aliases + |-------------------------------------------------------------------------- + | + | This array of class aliases will be registered when this application + | is started. However, feel free to register as many as you wish as + | the aliases are "lazy" loaded so they don't hinder performance. + | + */ + + "aliases" => [ + "App" => Illuminate\Support\Facades\App::class, + "Arr" => Illuminate\Support\Arr::class, + "Artisan" => Illuminate\Support\Facades\Artisan::class, + "Auth" => Illuminate\Support\Facades\Auth::class, + "Blade" => Illuminate\Support\Facades\Blade::class, + "Broadcast" => Illuminate\Support\Facades\Broadcast::class, + "Bus" => Illuminate\Support\Facades\Bus::class, + "Cache" => Illuminate\Support\Facades\Cache::class, + "Config" => Illuminate\Support\Facades\Config::class, + "Cookie" => Illuminate\Support\Facades\Cookie::class, + "Crypt" => Illuminate\Support\Facades\Crypt::class, + "DB" => Illuminate\Support\Facades\DB::class, + "Eloquent" => Illuminate\Database\Eloquent\Model::class, + "Event" => Illuminate\Support\Facades\Event::class, + "File" => Illuminate\Support\Facades\File::class, + "Gate" => Illuminate\Support\Facades\Gate::class, + "Hash" => Illuminate\Support\Facades\Hash::class, + "Http" => Illuminate\Support\Facades\Http::class, + "Lang" => Illuminate\Support\Facades\Lang::class, + "Log" => Illuminate\Support\Facades\Log::class, + "Mail" => Illuminate\Support\Facades\Mail::class, + "Notification" => Illuminate\Support\Facades\Notification::class, + "Password" => Illuminate\Support\Facades\Password::class, + "Queue" => Illuminate\Support\Facades\Queue::class, + "Redirect" => Illuminate\Support\Facades\Redirect::class, + "Redis" => Illuminate\Support\Facades\Redis::class, + "Request" => Illuminate\Support\Facades\Request::class, + "Response" => Illuminate\Support\Facades\Response::class, + "Route" => Illuminate\Support\Facades\Route::class, + "Schema" => Illuminate\Support\Facades\Schema::class, + "Session" => Illuminate\Support\Facades\Session::class, + "Storage" => Illuminate\Support\Facades\Storage::class, + "Str" => Illuminate\Support\Str::class, + "URL" => Illuminate\Support\Facades\URL::class, + "Validator" => Illuminate\Support\Facades\Validator::class, + "View" => Illuminate\Support\Facades\View::class, + // 'PDF' => Barryvdh\DomPDF\Facade::class, + ], +]; diff --git a/config/auth.php b/config/auth.php new file mode 100755 index 0000000..aaf982b --- /dev/null +++ b/config/auth.php @@ -0,0 +1,117 @@ + [ + 'guard' => 'web', + 'passwords' => 'users', + ], + + /* + |-------------------------------------------------------------------------- + | Authentication Guards + |-------------------------------------------------------------------------- + | + | Next, you may define every authentication guard for your application. + | Of course, a great default configuration has been defined for you + | here which uses session storage and the Eloquent user provider. + | + | All authentication drivers have a user provider. This defines how the + | users are actually retrieved out of your database or other storage + | mechanisms used by this application to persist your user's data. + | + | Supported: "session", "token" + | + */ + + 'guards' => [ + 'web' => [ + 'driver' => 'session', + 'provider' => 'users', + ], + + 'api' => [ + 'driver' => 'token', + 'provider' => 'users', + 'hash' => false, + ], + ], + + /* + |-------------------------------------------------------------------------- + | User Providers + |-------------------------------------------------------------------------- + | + | All authentication drivers have a user provider. This defines how the + | users are actually retrieved out of your database or other storage + | mechanisms used by this application to persist your user's data. + | + | If you have multiple user tables or models you may configure multiple + | sources which represent each model / table. These sources may then + | be assigned to any extra authentication guards you have defined. + | + | Supported: "database", "eloquent" + | + */ + + 'providers' => [ + 'users' => [ + 'driver' => 'eloquent', + 'model' => App\User::class, + ], + + // 'users' => [ + // 'driver' => 'database', + // 'table' => 'users', + // ], + ], + + /* + |-------------------------------------------------------------------------- + | Resetting Passwords + |-------------------------------------------------------------------------- + | + | You may specify multiple password reset configurations if you have more + | than one user table or model in the application and you want to have + | separate password reset settings based on the specific user types. + | + | The expire time is the number of minutes that the reset token should be + | considered valid. This security feature keeps tokens short-lived so + | they have less time to be guessed. You may change this as needed. + | + */ + + 'passwords' => [ + 'users' => [ + 'provider' => 'users', + 'table' => 'password_resets', + 'expire' => 60, + 'throttle' => 60, + ], + ], + + /* + |-------------------------------------------------------------------------- + | Password Confirmation Timeout + |-------------------------------------------------------------------------- + | + | Here you may define the amount of seconds before a password confirmation + | times out and the user is prompted to re-enter their password via the + | confirmation screen. By default, the timeout lasts for three hours. + | + */ + + 'password_timeout' => 10800, + +]; diff --git a/config/broadcasting.php b/config/broadcasting.php new file mode 100755 index 0000000..3bba110 --- /dev/null +++ b/config/broadcasting.php @@ -0,0 +1,59 @@ + env('BROADCAST_DRIVER', 'null'), + + /* + |-------------------------------------------------------------------------- + | Broadcast Connections + |-------------------------------------------------------------------------- + | + | Here you may define all of the broadcast connections that will be used + | to broadcast events to other systems or over websockets. Samples of + | each available type of connection are provided inside this array. + | + */ + + 'connections' => [ + + 'pusher' => [ + 'driver' => 'pusher', + 'key' => env('PUSHER_APP_KEY'), + 'secret' => env('PUSHER_APP_SECRET'), + 'app_id' => env('PUSHER_APP_ID'), + 'options' => [ + 'cluster' => env('PUSHER_APP_CLUSTER'), + 'useTLS' => true, + ], + ], + + 'redis' => [ + 'driver' => 'redis', + 'connection' => 'default', + ], + + 'log' => [ + 'driver' => 'log', + ], + + 'null' => [ + 'driver' => 'null', + ], + + ], + +]; diff --git a/config/cache.php b/config/cache.php new file mode 100755 index 0000000..4f41fdf --- /dev/null +++ b/config/cache.php @@ -0,0 +1,104 @@ + env('CACHE_DRIVER', 'file'), + + /* + |-------------------------------------------------------------------------- + | Cache Stores + |-------------------------------------------------------------------------- + | + | Here you may define all of the cache "stores" for your application as + | well as their drivers. You may even define multiple stores for the + | same cache driver to group types of items stored in your caches. + | + */ + + 'stores' => [ + + 'apc' => [ + 'driver' => 'apc', + ], + + 'array' => [ + 'driver' => 'array', + 'serialize' => false, + ], + + 'database' => [ + 'driver' => 'database', + 'table' => 'cache', + 'connection' => null, + ], + + 'file' => [ + 'driver' => 'file', + 'path' => storage_path('framework/cache/data'), + ], + + 'memcached' => [ + 'driver' => 'memcached', + 'persistent_id' => env('MEMCACHED_PERSISTENT_ID'), + 'sasl' => [ + env('MEMCACHED_USERNAME'), + env('MEMCACHED_PASSWORD'), + ], + 'options' => [ + // Memcached::OPT_CONNECT_TIMEOUT => 2000, + ], + 'servers' => [ + [ + 'host' => env('MEMCACHED_HOST', '127.0.0.1'), + 'port' => env('MEMCACHED_PORT', 11211), + 'weight' => 100, + ], + ], + ], + + 'redis' => [ + 'driver' => 'redis', + 'connection' => 'cache', + ], + + 'dynamodb' => [ + 'driver' => 'dynamodb', + 'key' => env('AWS_ACCESS_KEY_ID'), + 'secret' => env('AWS_SECRET_ACCESS_KEY'), + 'region' => env('AWS_DEFAULT_REGION', 'us-east-1'), + 'table' => env('DYNAMODB_CACHE_TABLE', 'cache'), + 'endpoint' => env('DYNAMODB_ENDPOINT'), + ], + + ], + + /* + |-------------------------------------------------------------------------- + | Cache Key Prefix + |-------------------------------------------------------------------------- + | + | When utilizing a RAM based store such as APC or Memcached, there might + | be other applications utilizing the same cache. So, we'll specify a + | value to get prefixed to all our keys so we can avoid collisions. + | + */ + + 'prefix' => env('CACHE_PREFIX', Str::slug(env('APP_NAME', 'laravel'), '_').'_cache'), + +]; diff --git a/config/cors.php b/config/cors.php new file mode 100755 index 0000000..558369d --- /dev/null +++ b/config/cors.php @@ -0,0 +1,34 @@ + ['api/*'], + + 'allowed_methods' => ['*'], + + 'allowed_origins' => ['*'], + + 'allowed_origins_patterns' => [], + + 'allowed_headers' => ['*'], + + 'exposed_headers' => [], + + 'max_age' => 0, + + 'supports_credentials' => false, + +]; diff --git a/config/database.php b/config/database.php new file mode 100755 index 0000000..c2c6c8f --- /dev/null +++ b/config/database.php @@ -0,0 +1,147 @@ + env('DB_CONNECTION', 'mysql'), + + /* + |-------------------------------------------------------------------------- + | Database Connections + |-------------------------------------------------------------------------- + | + | Here are each of the database connections setup for your application. + | Of course, examples of configuring each database platform that is + | supported by Laravel is shown below to make development simple. + | + | + | All database work in Laravel is done through the PHP PDO facilities + | so make sure you have the driver for your particular database of + | choice installed on your machine before you begin development. + | + */ + + 'connections' => [ + + 'sqlite' => [ + 'driver' => 'sqlite', + 'url' => env('DATABASE_URL'), + 'database' => env('DB_DATABASE', database_path('database.sqlite')), + 'prefix' => '', + 'foreign_key_constraints' => env('DB_FOREIGN_KEYS', true), + ], + + 'mysql' => [ + 'driver' => 'mysql', + 'url' => env('DATABASE_URL'), + 'host' => env('DB_HOST', '127.0.0.1'), + 'port' => env('DB_PORT', '3306'), + 'database' => env('DB_DATABASE', 'forge'), + 'username' => env('DB_USERNAME', 'forge'), + 'password' => env('DB_PASSWORD', ''), + 'unix_socket' => env('DB_SOCKET', ''), + 'charset' => 'utf8mb4', + 'collation' => 'utf8mb4_unicode_ci', + 'prefix' => '', + 'prefix_indexes' => true, + 'strict' => false, // true, + 'engine' => null, + 'options' => extension_loaded('pdo_mysql') ? array_filter([ + PDO::MYSQL_ATTR_SSL_CA => env('MYSQL_ATTR_SSL_CA'), + ]) : [], + ], + + 'pgsql' => [ + 'driver' => 'pgsql', + 'url' => env('DATABASE_URL'), + 'host' => env('DB_HOST', '127.0.0.1'), + 'port' => env('DB_PORT', '5432'), + 'database' => env('DB_DATABASE', 'forge'), + 'username' => env('DB_USERNAME', 'forge'), + 'password' => env('DB_PASSWORD', ''), + 'charset' => 'utf8', + 'prefix' => '', + 'prefix_indexes' => true, + 'schema' => 'public', + 'sslmode' => 'prefer', + ], + + 'sqlsrv' => [ + 'driver' => 'sqlsrv', + 'url' => env('DATABASE_URL'), + 'host' => env('DB_HOST', 'localhost'), + 'port' => env('DB_PORT', '1433'), + 'database' => env('DB_DATABASE', 'forge'), + 'username' => env('DB_USERNAME', 'forge'), + 'password' => env('DB_PASSWORD', ''), + 'charset' => 'utf8', + 'prefix' => '', + 'prefix_indexes' => true, + ], + + ], + + /* + |-------------------------------------------------------------------------- + | Migration Repository Table + |-------------------------------------------------------------------------- + | + | This table keeps track of all the migrations that have already run for + | your application. Using this information, we can determine which of + | the migrations on disk haven't actually been run in the database. + | + */ + + 'migrations' => 'migrations', + + /* + |-------------------------------------------------------------------------- + | Redis Databases + |-------------------------------------------------------------------------- + | + | Redis is an open source, fast, and advanced key-value store that also + | provides a richer body of commands than a typical key-value system + | such as APC or Memcached. Laravel makes it easy to dig right in. + | + */ + + 'redis' => [ + + 'client' => env('REDIS_CLIENT', 'phpredis'), + + 'options' => [ + 'cluster' => env('REDIS_CLUSTER', 'redis'), + 'prefix' => env('REDIS_PREFIX', Str::slug(env('APP_NAME', 'laravel'), '_').'_database_'), + ], + + 'default' => [ + 'url' => env('REDIS_URL'), + 'host' => env('REDIS_HOST', '127.0.0.1'), + 'password' => env('REDIS_PASSWORD', null), + 'port' => env('REDIS_PORT', '6379'), + 'database' => env('REDIS_DB', '0'), + ], + + 'cache' => [ + 'url' => env('REDIS_URL'), + 'host' => env('REDIS_HOST', '127.0.0.1'), + 'password' => env('REDIS_PASSWORD', null), + 'port' => env('REDIS_PORT', '6379'), + 'database' => env('REDIS_CACHE_DB', '1'), + ], + + ], + +]; diff --git a/config/datatables.php b/config/datatables.php new file mode 100644 index 0000000..0891264 --- /dev/null +++ b/config/datatables.php @@ -0,0 +1,127 @@ + [ + /* + * Smart search will enclose search keyword with wildcard string "%keyword%". + * SQL: column LIKE "%keyword%" + */ + 'smart' => true, + + /* + * Multi-term search will explode search keyword using spaces resulting into multiple term search. + */ + 'multi_term' => true, + + /* + * Case insensitive will search the keyword in lower case format. + * SQL: LOWER(column) LIKE LOWER(keyword) + */ + 'case_insensitive' => true, + + /* + * Wild card will add "%" in between every characters of the keyword. + * SQL: column LIKE "%k%e%y%w%o%r%d%" + */ + 'use_wildcards' => false, + + /* + * Perform a search which starts with the given keyword. + * SQL: column LIKE "keyword%" + */ + 'starts_with' => false, + ], + + /* + * DataTables internal index id response column name. + */ + 'index_column' => 'DT_RowIndex', + + /* + * List of available builders for DataTables. + * This is where you can register your custom dataTables builder. + */ + 'engines' => [ + 'eloquent' => Yajra\DataTables\EloquentDataTable::class, + 'query' => Yajra\DataTables\QueryDataTable::class, + 'collection' => Yajra\DataTables\CollectionDataTable::class, + 'resource' => Yajra\DataTables\ApiResourceDataTable::class, + ], + + /* + * DataTables accepted builder to engine mapping. + * This is where you can override which engine a builder should use + * Note, only change this if you know what you are doing! + */ + 'builders' => [ + //Illuminate\Database\Eloquent\Relations\Relation::class => 'eloquent', + //Illuminate\Database\Eloquent\Builder::class => 'eloquent', + //Illuminate\Database\Query\Builder::class => 'query', + //Illuminate\Support\Collection::class => 'collection', + ], + + /* + * Nulls last sql pattern for PostgreSQL & Oracle. + * For MySQL, use 'CASE WHEN :column IS NULL THEN 1 ELSE 0 END, :column :direction' + */ + 'nulls_last_sql' => ':column :direction NULLS LAST', + + /* + * User friendly message to be displayed on user if error occurs. + * Possible values: + * null - The exception message will be used on error response. + * 'throw' - Throws a \Yajra\DataTables\Exceptions\Exception. Use your custom error handler if needed. + * 'custom message' - Any friendly message to be displayed to the user. You can also use translation key. + */ + 'error' => env('DATATABLES_ERROR', null), + + /* + * Default columns definition of dataTable utility functions. + */ + 'columns' => [ + /* + * List of columns hidden/removed on json response. + */ + 'excess' => ['rn', 'row_num'], + + /* + * List of columns to be escaped. If set to *, all columns are escape. + * Note: You can set the value to empty array to disable XSS protection. + */ + 'escape' => '*', + + /* + * List of columns that are allowed to display html content. + * Note: Adding columns to list will make us available to XSS attacks. + */ + 'raw' => ['action'], + + /* + * List of columns are forbidden from being searched/sorted. + */ + 'blacklist' => ['password', 'remember_token'], + + /* + * List of columns that are only allowed fo search/sort. + * If set to *, all columns are allowed. + */ + 'whitelist' => '*', + ], + + /* + * JsonResponse header and options config. + */ + 'json' => [ + 'header' => [], + 'options' => 0, + ], + + /* + * Default condition to determine if a parameter is a callback or not. + * Callbacks needs to start by those terms, or they will be cast to string. + */ + 'callback' => ['$', '$.', 'function'], +]; diff --git a/config/dompdf.php b/config/dompdf.php new file mode 100755 index 0000000..0683df1 --- /dev/null +++ b/config/dompdf.php @@ -0,0 +1,248 @@ + false, // Throw an Exception on warnings from dompdf + 'orientation' => 'portrait', + /* + * Dejavu Sans font is missing glyphs for converted entities, turn it off if you need to show € and £. + */ + 'convert_entities' => true, + 'defines' => array( + /** + * The location of the DOMPDF font directory + * + * The location of the directory where DOMPDF will store fonts and font metrics + * Note: This directory must exist and be writable by the webserver process. + * *Please note the trailing slash.* + * + * Notes regarding fonts: + * Additional .afm font metrics can be added by executing load_font.php from command line. + * + * Only the original "Base 14 fonts" are present on all pdf viewers. Additional fonts must + * be embedded in the pdf file or the PDF may not display correctly. This can significantly + * increase file size unless font subsetting is enabled. Before embedding a font please + * review your rights under the font license. + * + * Any font specification in the source HTML is translated to the closest font available + * in the font directory. + * + * The pdf standard "Base 14 fonts" are: + * Courier, Courier-Bold, Courier-BoldOblique, Courier-Oblique, + * Helvetica, Helvetica-Bold, Helvetica-BoldOblique, Helvetica-Oblique, + * Times-Roman, Times-Bold, Times-BoldItalic, Times-Italic, + * Symbol, ZapfDingbats. + */ + "font_dir" => storage_path('fonts'), // advised by dompdf (https://github.com/dompdf/dompdf/pull/782) + + /** + * The location of the DOMPDF font cache directory + * + * This directory contains the cached font metrics for the fonts used by DOMPDF. + * This directory can be the same as DOMPDF_FONT_DIR + * + * Note: This directory must exist and be writable by the webserver process. + */ + "font_cache" => storage_path('fonts'), + + /** + * The location of a temporary directory. + * + * The directory specified must be writeable by the webserver process. + * The temporary directory is required to download remote images and when + * using the PFDLib back end. + */ + "temp_dir" => sys_get_temp_dir(), + + /** + * ==== IMPORTANT ==== + * + * dompdf's "chroot": Prevents dompdf from accessing system files or other + * files on the webserver. All local files opened by dompdf must be in a + * subdirectory of this directory. DO NOT set it to '/' since this could + * allow an attacker to use dompdf to read any files on the server. This + * should be an absolute path. + * This is only checked on command line call by dompdf.php, but not by + * direct class use like: + * $dompdf = new DOMPDF(); $dompdf->load_html($htmldata); $dompdf->render(); $pdfdata = $dompdf->output(); + */ + "chroot" => realpath(base_path()), + + /** + * Whether to enable font subsetting or not. + */ + "enable_font_subsetting" => false, + + /** + * The PDF rendering backend to use + * + * Valid settings are 'PDFLib', 'CPDF' (the bundled R&OS PDF class), 'GD' and + * 'auto'. 'auto' will look for PDFLib and use it if found, or if not it will + * fall back on CPDF. 'GD' renders PDFs to graphic files. {@link + * Canvas_Factory} ultimately determines which rendering class to instantiate + * based on this setting. + * + * Both PDFLib & CPDF rendering backends provide sufficient rendering + * capabilities for dompdf, however additional features (e.g. object, + * image and font support, etc.) differ between backends. Please see + * {@link PDFLib_Adapter} for more information on the PDFLib backend + * and {@link CPDF_Adapter} and lib/class.pdf.php for more information + * on CPDF. Also see the documentation for each backend at the links + * below. + * + * The GD rendering backend is a little different than PDFLib and + * CPDF. Several features of CPDF and PDFLib are not supported or do + * not make any sense when creating image files. For example, + * multiple pages are not supported, nor are PDF 'objects'. Have a + * look at {@link GD_Adapter} for more information. GD support is + * experimental, so use it at your own risk. + * + * @link http://www.pdflib.com + * @link http://www.ros.co.nz/pdf + * @link http://www.php.net/image + */ + "pdf_backend" => "CPDF", + + /** + * PDFlib license key + * + * If you are using a licensed, commercial version of PDFlib, specify + * your license key here. If you are using PDFlib-Lite or are evaluating + * the commercial version of PDFlib, comment out this setting. + * + * @link http://www.pdflib.com + * + * If pdflib present in web server and auto or selected explicitely above, + * a real license code must exist! + */ + //"DOMPDF_PDFLIB_LICENSE" => "your license key here", + + /** + * html target media view which should be rendered into pdf. + * List of types and parsing rules for future extensions: + * http://www.w3.org/TR/REC-html40/types.html + * screen, tty, tv, projection, handheld, print, braille, aural, all + * Note: aural is deprecated in CSS 2.1 because it is replaced by speech in CSS 3. + * Note, even though the generated pdf file is intended for print output, + * the desired content might be different (e.g. screen or projection view of html file). + * Therefore allow specification of content here. + */ + "default_media_type" => "screen", + + /** + * The default paper size. + * + * North America standard is "letter"; other countries generally "a4" + * + * @see CPDF_Adapter::PAPER_SIZES for valid sizes ('letter', 'legal', 'A4', etc.) + */ + "default_paper_size" => "a4", + + /** + * The default font family + * + * Used if no suitable fonts can be found. This must exist in the font folder. + * @var string + */ + "default_font" => "sans-serif", + + /** + * Image DPI setting + * + * This setting determines the default DPI setting for images and fonts. The + * DPI may be overridden for inline images by explictly setting the + * image's width & height style attributes (i.e. if the image's native + * width is 600 pixels and you specify the image's width as 72 points, + * the image will have a DPI of 600 in the rendered PDF. The DPI of + * background images can not be overridden and is controlled entirely + * via this parameter. + * + * For the purposes of DOMPDF, pixels per inch (PPI) = dots per inch (DPI). + * If a size in html is given as px (or without unit as image size), + * this tells the corresponding size in pt. + * This adjusts the relative sizes to be similar to the rendering of the + * html page in a reference browser. + * + * In pdf, always 1 pt = 1/72 inch + * + * Rendering resolution of various browsers in px per inch: + * Windows Firefox and Internet Explorer: + * SystemControl->Display properties->FontResolution: Default:96, largefonts:120, custom:? + * Linux Firefox: + * about:config *resolution: Default:96 + * (xorg screen dimension in mm and Desktop font dpi settings are ignored) + * + * Take care about extra font/image zoom factor of browser. + * + * In images, size in pixel attribute, img css style, are overriding + * the real image dimension in px for rendering. + * + * @var int + */ + "dpi" => 96, + + /** + * Enable inline PHP + * + * If this setting is set to true then DOMPDF will automatically evaluate + * inline PHP contained within tags. + * + * Enabling this for documents you do not trust (e.g. arbitrary remote html + * pages) is a security risk. Set this option to false if you wish to process + * untrusted documents. + * + * @var bool + */ + "enable_php" => false, + + /** + * Enable inline Javascript + * + * If this setting is set to true then DOMPDF will automatically insert + * JavaScript code contained within tags. + * + * @var bool + */ + "enable_javascript" => true, + + /** + * Enable remote file access + * + * If this setting is set to true, DOMPDF will access remote sites for + * images and CSS files as required. + * This is required for part of test case www/test/image_variants.html through www/examples.php + * + * Attention! + * This can be a security risk, in particular in combination with DOMPDF_ENABLE_PHP and + * allowing remote access to dompdf.php or on allowing remote html code to be passed to + * $dompdf = new DOMPDF(, $dompdf->load_html(..., + * This allows anonymous users to download legally doubtful internet content which on + * tracing back appears to being downloaded by your server, or allows malicious php code + * in remote html pages to be executed by your server with your account privileges. + * + * @var bool + */ + "enable_remote" => true, + + /** + * A ratio applied to the fonts height to be more like browsers' line height + */ + "font_height_ratio" => 1.1, + + /** + * Use the more-than-experimental HTML5 Lib parser + */ + "enable_html5_parser" => false, + ), + + +); diff --git a/config/filesystems.php b/config/filesystems.php new file mode 100755 index 0000000..94c8112 --- /dev/null +++ b/config/filesystems.php @@ -0,0 +1,85 @@ + env('FILESYSTEM_DRIVER', 'local'), + + /* + |-------------------------------------------------------------------------- + | Default Cloud Filesystem Disk + |-------------------------------------------------------------------------- + | + | Many applications store files both locally and in the cloud. For this + | reason, you may specify a default "cloud" driver here. This driver + | will be bound as the Cloud disk implementation in the container. + | + */ + + 'cloud' => env('FILESYSTEM_CLOUD', 's3'), + + /* + |-------------------------------------------------------------------------- + | Filesystem Disks + |-------------------------------------------------------------------------- + | + | Here you may configure as many filesystem "disks" as you wish, and you + | may even configure multiple disks of the same driver. Defaults have + | been setup for each driver as an example of the required options. + | + | Supported Drivers: "local", "ftp", "sftp", "s3" + | + */ + + 'disks' => [ + + 'local' => [ + 'driver' => 'local', + 'root' => storage_path('app'), + ], + + 'public' => [ + 'driver' => 'local', + 'root' => storage_path('app/public'), + 'url' => env('APP_URL').'/storage', + 'visibility' => 'public', + ], + + 's3' => [ + 'driver' => 's3', + 'key' => env('AWS_ACCESS_KEY_ID'), + 'secret' => env('AWS_SECRET_ACCESS_KEY'), + 'region' => env('AWS_DEFAULT_REGION'), + 'bucket' => env('AWS_BUCKET'), + 'url' => env('AWS_URL'), + 'endpoint' => env('AWS_ENDPOINT'), + ], + + ], + + /* + |-------------------------------------------------------------------------- + | Symbolic Links + |-------------------------------------------------------------------------- + | + | Here you may configure the symbolic links that will be created when the + | `storage:link` Artisan command is executed. The array keys should be + | the locations of the links and the values should be their targets. + | + */ + + 'links' => [ + public_path('storage') => storage_path('app/public'), + ], + +]; diff --git a/config/hashing.php b/config/hashing.php new file mode 100755 index 0000000..8425770 --- /dev/null +++ b/config/hashing.php @@ -0,0 +1,52 @@ + 'bcrypt', + + /* + |-------------------------------------------------------------------------- + | Bcrypt Options + |-------------------------------------------------------------------------- + | + | Here you may specify the configuration options that should be used when + | passwords are hashed using the Bcrypt algorithm. This will allow you + | to control the amount of time it takes to hash the given password. + | + */ + + 'bcrypt' => [ + 'rounds' => env('BCRYPT_ROUNDS', 10), + ], + + /* + |-------------------------------------------------------------------------- + | Argon Options + |-------------------------------------------------------------------------- + | + | Here you may specify the configuration options that should be used when + | passwords are hashed using the Argon algorithm. These will allow you + | to control the amount of time it takes to hash the given password. + | + */ + + 'argon' => [ + 'memory' => 1024, + 'threads' => 2, + 'time' => 2, + ], + +]; diff --git a/config/logging.php b/config/logging.php new file mode 100755 index 0000000..088c204 --- /dev/null +++ b/config/logging.php @@ -0,0 +1,104 @@ + env('LOG_CHANNEL', 'stack'), + + /* + |-------------------------------------------------------------------------- + | Log Channels + |-------------------------------------------------------------------------- + | + | Here you may configure the log channels for your application. Out of + | the box, Laravel uses the Monolog PHP logging library. This gives + | you a variety of powerful log handlers / formatters to utilize. + | + | Available Drivers: "single", "daily", "slack", "syslog", + | "errorlog", "monolog", + | "custom", "stack" + | + */ + + 'channels' => [ + 'stack' => [ + 'driver' => 'stack', + 'channels' => ['single'], + 'ignore_exceptions' => false, + ], + + 'single' => [ + 'driver' => 'single', + 'path' => storage_path('logs/laravel.log'), + 'level' => 'debug', + ], + + 'daily' => [ + 'driver' => 'daily', + 'path' => storage_path('logs/laravel.log'), + 'level' => 'debug', + 'days' => 14, + ], + + 'slack' => [ + 'driver' => 'slack', + 'url' => env('LOG_SLACK_WEBHOOK_URL'), + 'username' => 'Laravel Log', + 'emoji' => ':boom:', + 'level' => 'critical', + ], + + 'papertrail' => [ + 'driver' => 'monolog', + 'level' => 'debug', + 'handler' => SyslogUdpHandler::class, + 'handler_with' => [ + 'host' => env('PAPERTRAIL_URL'), + 'port' => env('PAPERTRAIL_PORT'), + ], + ], + + 'stderr' => [ + 'driver' => 'monolog', + 'handler' => StreamHandler::class, + 'formatter' => env('LOG_STDERR_FORMATTER'), + 'with' => [ + 'stream' => 'php://stderr', + ], + ], + + 'syslog' => [ + 'driver' => 'syslog', + 'level' => 'debug', + ], + + 'errorlog' => [ + 'driver' => 'errorlog', + 'level' => 'debug', + ], + + 'null' => [ + 'driver' => 'monolog', + 'handler' => NullHandler::class, + ], + + 'emergency' => [ + 'path' => storage_path('logs/laravel.log'), + ], + ], + +]; diff --git a/config/mail.php b/config/mail.php new file mode 100755 index 0000000..54299aa --- /dev/null +++ b/config/mail.php @@ -0,0 +1,110 @@ + env('MAIL_MAILER', 'smtp'), + + /* + |-------------------------------------------------------------------------- + | Mailer Configurations + |-------------------------------------------------------------------------- + | + | Here you may configure all of the mailers used by your application plus + | their respective settings. Several examples have been configured for + | you and you are free to add your own as your application requires. + | + | Laravel supports a variety of mail "transport" drivers to be used while + | sending an e-mail. You will specify which one you are using for your + | mailers below. You are free to add additional mailers as required. + | + | Supported: "smtp", "sendmail", "mailgun", "ses", + | "postmark", "log", "array" + | + */ + + 'mailers' => [ + 'smtp' => [ + 'transport' => 'smtp', + 'host' => env('MAIL_HOST', 'smtp.mailgun.org'), + 'port' => env('MAIL_PORT', 587), + 'encryption' => env('MAIL_ENCRYPTION', 'tls'), + 'username' => env('MAIL_USERNAME'), + 'password' => env('MAIL_PASSWORD'), + 'timeout' => null, + 'auth_mode' => null, + ], + + 'ses' => [ + 'transport' => 'ses', + ], + + 'mailgun' => [ + 'transport' => 'mailgun', + ], + + 'postmark' => [ + 'transport' => 'postmark', + ], + + 'sendmail' => [ + 'transport' => 'sendmail', + 'path' => '/usr/sbin/sendmail -bs', + ], + + 'log' => [ + 'transport' => 'log', + 'channel' => env('MAIL_LOG_CHANNEL'), + ], + + 'array' => [ + 'transport' => 'array', + ], + ], + + /* + |-------------------------------------------------------------------------- + | Global "From" Address + |-------------------------------------------------------------------------- + | + | You may wish for all e-mails sent by your application to be sent from + | the same address. Here, you may specify a name and address that is + | used globally for all e-mails that are sent by your application. + | + */ + + 'from' => [ + 'address' => env('MAIL_FROM_ADDRESS', 'hello@example.com'), + 'name' => env('MAIL_FROM_NAME', 'Example'), + ], + + /* + |-------------------------------------------------------------------------- + | Markdown Mail Settings + |-------------------------------------------------------------------------- + | + | If you are using Markdown based email rendering, you may configure your + | theme and component paths here, allowing you to customize the design + | of the emails. Or, you may simply stick with the Laravel defaults! + | + */ + + 'markdown' => [ + 'theme' => 'default', + + 'paths' => [ + resource_path('views/vendor/mail'), + ], + ], + +]; diff --git a/config/queue.php b/config/queue.php new file mode 100755 index 0000000..00b76d6 --- /dev/null +++ b/config/queue.php @@ -0,0 +1,89 @@ + env('QUEUE_CONNECTION', 'sync'), + + /* + |-------------------------------------------------------------------------- + | Queue Connections + |-------------------------------------------------------------------------- + | + | Here you may configure the connection information for each server that + | is used by your application. A default configuration has been added + | for each back-end shipped with Laravel. You are free to add more. + | + | Drivers: "sync", "database", "beanstalkd", "sqs", "redis", "null" + | + */ + + 'connections' => [ + + 'sync' => [ + 'driver' => 'sync', + ], + + 'database' => [ + 'driver' => 'database', + 'table' => 'jobs', + 'queue' => 'default', + 'retry_after' => 90, + ], + + 'beanstalkd' => [ + 'driver' => 'beanstalkd', + 'host' => 'localhost', + 'queue' => 'default', + 'retry_after' => 90, + 'block_for' => 0, + ], + + 'sqs' => [ + 'driver' => 'sqs', + 'key' => env('AWS_ACCESS_KEY_ID'), + 'secret' => env('AWS_SECRET_ACCESS_KEY'), + 'prefix' => env('SQS_PREFIX', 'https://sqs.us-east-1.amazonaws.com/your-account-id'), + 'queue' => env('SQS_QUEUE', 'your-queue-name'), + 'suffix' => env('SQS_SUFFIX'), + 'region' => env('AWS_DEFAULT_REGION', 'us-east-1'), + ], + + 'redis' => [ + 'driver' => 'redis', + 'connection' => 'default', + 'queue' => env('REDIS_QUEUE', 'default'), + 'retry_after' => 90, + 'block_for' => null, + ], + + ], + + /* + |-------------------------------------------------------------------------- + | Failed Queue Jobs + |-------------------------------------------------------------------------- + | + | These options configure the behavior of failed queue job logging so you + | can control which database and table are used to store the jobs that + | have failed. You may change them to any database / table you wish. + | + */ + + 'failed' => [ + 'driver' => env('QUEUE_FAILED_DRIVER', 'database'), + 'database' => env('DB_CONNECTION', 'mysql'), + 'table' => 'failed_jobs', + ], + +]; diff --git a/config/services.php b/config/services.php new file mode 100755 index 0000000..2a1d616 --- /dev/null +++ b/config/services.php @@ -0,0 +1,33 @@ + [ + 'domain' => env('MAILGUN_DOMAIN'), + 'secret' => env('MAILGUN_SECRET'), + 'endpoint' => env('MAILGUN_ENDPOINT', 'api.mailgun.net'), + ], + + 'postmark' => [ + 'token' => env('POSTMARK_TOKEN'), + ], + + 'ses' => [ + 'key' => env('AWS_ACCESS_KEY_ID'), + 'secret' => env('AWS_SECRET_ACCESS_KEY'), + 'region' => env('AWS_DEFAULT_REGION', 'us-east-1'), + ], + +]; diff --git a/config/session.php b/config/session.php new file mode 100755 index 0000000..4e0f66c --- /dev/null +++ b/config/session.php @@ -0,0 +1,201 @@ + env('SESSION_DRIVER', 'file'), + + /* + |-------------------------------------------------------------------------- + | Session Lifetime + |-------------------------------------------------------------------------- + | + | Here you may specify the number of minutes that you wish the session + | to be allowed to remain idle before it expires. If you want them + | to immediately expire on the browser closing, set that option. + | + */ + + 'lifetime' => env('SESSION_LIFETIME', 120), + + 'expire_on_close' => false, + + /* + |-------------------------------------------------------------------------- + | Session Encryption + |-------------------------------------------------------------------------- + | + | This option allows you to easily specify that all of your session data + | should be encrypted before it is stored. All encryption will be run + | automatically by Laravel and you can use the Session like normal. + | + */ + + 'encrypt' => false, + + /* + |-------------------------------------------------------------------------- + | Session File Location + |-------------------------------------------------------------------------- + | + | When using the native session driver, we need a location where session + | files may be stored. A default has been set for you but a different + | location may be specified. This is only needed for file sessions. + | + */ + + 'files' => storage_path('framework/sessions'), + + /* + |-------------------------------------------------------------------------- + | Session Database Connection + |-------------------------------------------------------------------------- + | + | When using the "database" or "redis" session drivers, you may specify a + | connection that should be used to manage these sessions. This should + | correspond to a connection in your database configuration options. + | + */ + + 'connection' => env('SESSION_CONNECTION', null), + + /* + |-------------------------------------------------------------------------- + | Session Database Table + |-------------------------------------------------------------------------- + | + | When using the "database" session driver, you may specify the table we + | should use to manage the sessions. Of course, a sensible default is + | provided for you; however, you are free to change this as needed. + | + */ + + 'table' => 'sessions', + + /* + |-------------------------------------------------------------------------- + | Session Cache Store + |-------------------------------------------------------------------------- + | + | While using one of the framework's cache driven session backends you may + | list a cache store that should be used for these sessions. This value + | must match with one of the application's configured cache "stores". + | + | Affects: "apc", "dynamodb", "memcached", "redis" + | + */ + + 'store' => env('SESSION_STORE', null), + + /* + |-------------------------------------------------------------------------- + | Session Sweeping Lottery + |-------------------------------------------------------------------------- + | + | Some session drivers must manually sweep their storage location to get + | rid of old sessions from storage. Here are the chances that it will + | happen on a given request. By default, the odds are 2 out of 100. + | + */ + + 'lottery' => [2, 100], + + /* + |-------------------------------------------------------------------------- + | Session Cookie Name + |-------------------------------------------------------------------------- + | + | Here you may change the name of the cookie used to identify a session + | instance by ID. The name specified here will get used every time a + | new session cookie is created by the framework for every driver. + | + */ + + 'cookie' => env( + 'SESSION_COOKIE', + Str::slug(env('APP_NAME', 'laravel'), '_').'_session' + ), + + /* + |-------------------------------------------------------------------------- + | Session Cookie Path + |-------------------------------------------------------------------------- + | + | The session cookie path determines the path for which the cookie will + | be regarded as available. Typically, this will be the root path of + | your application but you are free to change this when necessary. + | + */ + + 'path' => '/', + + /* + |-------------------------------------------------------------------------- + | Session Cookie Domain + |-------------------------------------------------------------------------- + | + | Here you may change the domain of the cookie used to identify a session + | in your application. This will determine which domains the cookie is + | available to in your application. A sensible default has been set. + | + */ + + 'domain' => env('SESSION_DOMAIN', null), + + /* + |-------------------------------------------------------------------------- + | HTTPS Only Cookies + |-------------------------------------------------------------------------- + | + | By setting this option to true, session cookies will only be sent back + | to the server if the browser has a HTTPS connection. This will keep + | the cookie from being sent to you if it can not be done securely. + | + */ + + 'secure' => env('SESSION_SECURE_COOKIE'), + + /* + |-------------------------------------------------------------------------- + | HTTP Access Only + |-------------------------------------------------------------------------- + | + | Setting this value to true will prevent JavaScript from accessing the + | value of the cookie and the cookie will only be accessible through + | the HTTP protocol. You are free to modify this option if needed. + | + */ + + 'http_only' => true, + + /* + |-------------------------------------------------------------------------- + | Same-Site Cookies + |-------------------------------------------------------------------------- + | + | This option determines how your cookies behave when cross-site requests + | take place, and can be used to mitigate CSRF attacks. By default, we + | will set this value to "lax" since this is a secure default value. + | + | Supported: "lax", "strict", "none", null + | + */ + + 'same_site' => 'lax', + +]; diff --git a/config/view.php b/config/view.php new file mode 100755 index 0000000..22b8a18 --- /dev/null +++ b/config/view.php @@ -0,0 +1,36 @@ + [ + resource_path('views'), + ], + + /* + |-------------------------------------------------------------------------- + | Compiled View Path + |-------------------------------------------------------------------------- + | + | This option determines where all the compiled Blade templates will be + | stored for your application. Typically, this is within the storage + | directory. However, as usual, you are free to change this value. + | + */ + + 'compiled' => env( + 'VIEW_COMPILED_PATH', + realpath(storage_path('framework/views')) + ), + +]; diff --git a/database/.gitignore b/database/.gitignore new file mode 100755 index 0000000..97fc976 --- /dev/null +++ b/database/.gitignore @@ -0,0 +1,2 @@ +*.sqlite +*.sqlite-journal diff --git a/database/factories/UserFactory.php b/database/factories/UserFactory.php new file mode 100755 index 0000000..741edea --- /dev/null +++ b/database/factories/UserFactory.php @@ -0,0 +1,28 @@ +define(User::class, function (Faker $faker) { + return [ + 'name' => $faker->name, + 'email' => $faker->unique()->safeEmail, + 'email_verified_at' => now(), + 'password' => '$2y$10$92IXUNpkjO0rOQ5byMi.Ye4oKoEa3Ro9llC/.og/at2.uheWG/igi', // password + 'remember_token' => Str::random(10), + ]; +}); diff --git a/database/migrations/2014_10_12_000000_create_users_table.php b/database/migrations/2014_10_12_000000_create_users_table.php new file mode 100755 index 0000000..f229f1e --- /dev/null +++ b/database/migrations/2014_10_12_000000_create_users_table.php @@ -0,0 +1,47 @@ +id(); + $table->string('first_name'); + $table->string('last_name')->nullable(); + $table->string('email')->unique(); + $table->timestamp('email_verified_at')->nullable(); + $table->bigInteger('phone')->nullable(); + $table->tinyInteger('phone_code')->default(62); + $table->string('password'); + $table->rememberToken(); + $table->integer('role')->comment('1=>su, 2=>admin, 3=>user')->default(2); + $table->integer('status')->comment('1=>active, 2=>not_active, 3=>suspend')->default(1); + $table->integer('is_login')->comment('1=>login,2=>logout')->default(2); + $table->integer('crt'); + $table->integer('crt_by'); + $table->integer('updt'); + $table->integer('updt_by'); + $table->integer('dlt')->nullable(); + $table->integer('dlt_by')->nullable(); + }); + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('t_users'); + } +} diff --git a/database/migrations/2014_10_12_100000_create_password_resets_table.php b/database/migrations/2014_10_12_100000_create_password_resets_table.php new file mode 100755 index 0000000..0ee0a36 --- /dev/null +++ b/database/migrations/2014_10_12_100000_create_password_resets_table.php @@ -0,0 +1,32 @@ +string('email')->index(); + $table->string('token'); + $table->timestamp('created_at')->nullable(); + }); + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('password_resets'); + } +} diff --git a/database/migrations/2019_08_19_000000_create_failed_jobs_table.php b/database/migrations/2019_08_19_000000_create_failed_jobs_table.php new file mode 100755 index 0000000..9bddee3 --- /dev/null +++ b/database/migrations/2019_08_19_000000_create_failed_jobs_table.php @@ -0,0 +1,35 @@ +id(); + $table->text('connection'); + $table->text('queue'); + $table->longText('payload'); + $table->longText('exception'); + $table->timestamp('failed_at')->useCurrent(); + }); + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('failed_jobs'); + } +} diff --git a/database/seeds/DatabaseSeeder.php b/database/seeds/DatabaseSeeder.php new file mode 100755 index 0000000..5f851ce --- /dev/null +++ b/database/seeds/DatabaseSeeder.php @@ -0,0 +1,31 @@ +call(UserSeeder::class); + $now = time(); + $data = [ + 'first_name' => 'admin', + 'last_name' => null, + 'email' => 'admin@gmail.com', + 'phone' => null, + 'password' => Hash::make('123'), + 'role' => Users::ROLE_ADMIN, + 'crt' => $now, + 'crt_by' => 0, + 'updt' => $now, + 'updt_by' => 0, + ]; + Users::addUser($data); + } +} diff --git a/docker-compose.yml b/docker-compose.yml new file mode 100755 index 0000000..f9bb626 --- /dev/null +++ b/docker-compose.yml @@ -0,0 +1,31 @@ +version: "3.7" +services: + app: + build: + context: ./ + dockerfile: Dockerfile + image: trucking + container_name: trucking-app + restart: unless-stopped + working_dir: /var/www/html/trucking + # comment volumes, kalo file/folder yg existing di container gamau ketiban + volumes: + - ./:/var/www/html/trucking + networks: + - trucking + + nginx: + image: nginx:alpine + container_name: trucking-nginx + restart: unless-stopped + ports: + - "5000:80" + volumes: + - ./:/var/www/html/trucking + - ./docker-data/nginx/default.conf:/etc/nginx/conf.d/default.conf + networks: + - trucking + +networks: + trucking: + driver: bridge \ No newline at end of file diff --git a/docker-data/nginx/default.conf b/docker-data/nginx/default.conf new file mode 100755 index 0000000..2dd9f63 --- /dev/null +++ b/docker-data/nginx/default.conf @@ -0,0 +1,72 @@ +server { + listen 80 default_server; + listen [::]:80 default_server; + + server_name localhost; + root /var/www/html; + + error_log /var/log/nginx/error.log; + access_log /var/log/nginx/access.log; + + add_header X-Frame-Options "SAMEORIGIN"; + add_header X-Content-Type-Options "nosniff"; + + index index.html index.php; + + charset utf-8; + + # prevent port change when rewriting + # port_in_redirect off; + # server_name_in_redirect off; + # absolute_redirect off; + + error_page 404 /index.php; + + proxy_read_timeout 2m; + proxy_connect_timeout 2m; + proxy_send_timeout 2m; + + client_max_body_size 20m; + + location = /favicon.ico { + access_log off; + log_not_found off; + } + location = /robots.txt { + access_log off; + log_not_found off; + } + + location ~ /\.(?!well-known).* { + deny all; + } + + location / { + try_files $uri $uri/ /index.php?$query_string; + } + + location ~ \.php$ { + try_files $uri =404; + fastcgi_split_path_info ^(.+\.php)(/.+)$; + fastcgi_pass app:9000; + fastcgi_index index.php; + include fastcgi_params; + fastcgi_param SCRIPT_FILENAME $realpath_root$fastcgi_script_name; + fastcgi_param PATH_INFO $fastcgi_path_info; + } + + location /trucking { + alias /var/www/html/trucking/public; + index index.php; + try_files $uri $uri/ @trucking; + + location ~ \.php$ { + include fastcgi_params; + fastcgi_pass app:9000; + fastcgi_param SCRIPT_FILENAME /var/www/html/trucking/public/index.php; + } + } + location @trucking { + rewrite /trucking/(.*)$ /trucking/index.php?/$1 last; + } +} \ No newline at end of file diff --git a/docker-data/nginx/default_pro.conf b/docker-data/nginx/default_pro.conf new file mode 100755 index 0000000..75da597 --- /dev/null +++ b/docker-data/nginx/default_pro.conf @@ -0,0 +1,150 @@ +## +# You should look at the following URL's in order to grasp a solid understanding +# of Nginx configuration files in order to fully unleash the power of Nginx. +# https://www.nginx.com/resources/wiki/start/ +# https://www.nginx.com/resources/wiki/start/topics/tutorials/config_pitfalls/ +# https://wiki.debian.org/Nginx/DirectoryStructure +# +# In most cases, administrators will remove this file from sites-enabled/ and +# leave it as reference inside of sites-available where it will continue to be +# updated by the nginx packaging team. +# +# This file will automatically load configuration files provided by other +# applications, such as Drupal or Wordpress. These applications will be made +# available underneath a path with that package name, such as /drupal8. +# +# Please see /usr/share/doc/nginx-doc/examples/ for more detailed examples. +## + +# Default server configuration +# +server { + listen 80 default_server; + listen [::]:80 default_server; + + # SSL configuration + # + # listen 443 ssl default_server; + # listen [::]:443 ssl default_server; + # + # Note: You should disable gzip for SSL traffic. + # See: https://bugs.debian.org/773332 + # + # Read up on ssl_ciphers to ensure a secure configuration. + # See: https://bugs.debian.org/765782 + # + # Self signed certs generated by the ssl-cert package + # Don't use them in a production server! + # + # include snippets/snakeoil.conf; + + root /var/www/html; + + # Add index.php to the list if you are using PHP + # index index.html index.htm index.nginx-debian.html; + + server_name _; + + #location / { + # First attempt to serve request as file, then + # as directory, then fall back to displaying a 404. + # try_files $uri $uri/ =404; + #} + + #location / { + # rewrite ^/(.*)$ http://bingkis-corporate.com/lp/bingcorp redirect; + #} + + client_max_body_size 20m; + + location / { + alias /var/www/html/lp/public; + try_files $uri @lp_outer; + + proxy_read_timeout 12000; + proxy_connect_timeout 12000; + proxy_send_timeout 12000; + + location ~ \.php { + include snippets/fastcgi-php.conf; + fastcgi_pass unix:/var/run/php/php7.2-fpm.sock; + fastcgi_param SCRIPT_FILENAME /var/www/html/lp/public/index.php; + } + } + location @lp_outer { + rewrite ^/(.*)$ /lp/bingcorp last; + } + + # pass PHP scripts to FastCGI server + # + #location ~ \.php$ { + # include snippets/fastcgi-php.conf; + # + # # With php-fpm (or other unix sockets): + # fastcgi_pass unix:/var/run/php/php7.0-fpm.sock; + # # With php-cgi (or other tcp sockets): + # fastcgi_pass 127.0.0.1:9000; + #} + + # deny access to .htaccess files, if Apache's document root + # concurs with nginx's one + # + #location ~ /\.ht { + # deny all; + #} + + location /fms { + alias /var/www/html/fms/public; + try_files $uri @fms; + + proxy_read_timeout 12000; + proxy_connect_timeout 12000; + proxy_send_timeout 12000; + + location ~ \.php { + include snippets/fastcgi-php.conf; + fastcgi_pass unix:/var/run/php/php7.2-fpm.sock; + fastcgi_param SCRIPT_FILENAME /var/www/html/fms/public/index.php; + } + } + location @fms { + rewrite /fms/(.*)$ /fms/index.php?/$1 last; + } + + location /lp { + alias /var/www/html/lp/public; + try_files $uri @lp; + + proxy_read_timeout 12000; + proxy_connect_timeout 12000; + proxy_send_timeout 12000; + + location ~ \.php { + include snippets/fastcgi-php.conf; + fastcgi_pass unix:/var/run/php/php7.2-fpm.sock; + fastcgi_param SCRIPT_FILENAME /var/www/html/lp/public/index.php; + } + } + location @lp { + rewrite /lp/(.*)$ /lp/index.php?/$1 last; + } +} + +# Virtual Host configuration for example.com +# +# You can move that to a different file under sites-available/ and symlink that +# to sites-enabled/ to enable it. +# +#server { +# listen 80; +# listen [::]:80; +# +# server_name example.com; +# +# root /var/www/example.com; +# index index.html; +# +# location / { +# try_files $uri $uri/ =404; +# } +#} \ No newline at end of file diff --git a/docker-data/nginx/default_pro_flexible_http_https.conf b/docker-data/nginx/default_pro_flexible_http_https.conf new file mode 100755 index 0000000..b65f3e0 --- /dev/null +++ b/docker-data/nginx/default_pro_flexible_http_https.conf @@ -0,0 +1,269 @@ +## +# You should look at the following URL's in order to grasp a solid understanding +# of Nginx configuration files in order to fully unleash the power of Nginx. +# https://www.nginx.com/resources/wiki/start/ +# https://www.nginx.com/resources/wiki/start/topics/tutorials/config_pitfalls/ +# https://wiki.debian.org/Nginx/DirectoryStructure +# +# In most cases, administrators will remove this file from sites-enabled/ and +# leave it as reference inside of sites-available where it will continue to be +# updated by the nginx packaging team. +# +# This file will automatically load configuration files provided by other +# applications, such as Drupal or Wordpress. These applications will be made +# available underneath a path with that package name, such as /drupal8. +# +# Please see /usr/share/doc/nginx-doc/examples/ for more detailed examples. +## + +# Default server configuration +# +server { + + listen 80 default_server; + listen [::]:80 default_server; + + # SSL configuration + # + # listen 443 ssl default_server; + # listen [::]:443 ssl default_server; + # + # Note: You should disable gzip for SSL traffic. + # See: https://bugs.debian.org/773332 + # + # Read up on ssl_ciphers to ensure a secure configuration. + # See: https://bugs.debian.org/765782 + # + # Self signed certs generated by the ssl-cert package + # Don't use them in a production server! + # + # include snippets/snakeoil.conf; + + root /var/www/html; + + # Add index.php to the list if you are using PHP + # index index.html index.htm index.nginx-debian.html; + + server_name bingkis-corporate.com www.bingkis-corporate.com; + + #location / { + # First attempt to serve request as file, then + # as directory, then fall back to displaying a 404. + # try_files $uri $uri/ =404; + #} + + #location / { + # rewrite ^/(.*)$ http://bingkis-corporate.com/lp/bingcorp redirect; + #} + + client_max_body_size 20m; + + location / { + alias /var/www/html/lp/public; + try_files $uri @lp_outer; + + proxy_read_timeout 12000; + proxy_connect_timeout 12000; + proxy_send_timeout 12000; + + location ~ \.php { + include snippets/fastcgi-php.conf; + fastcgi_pass unix:/var/run/php/php7.2-fpm.sock; + fastcgi_param SCRIPT_FILENAME /var/www/html/lp/public/index.php; + } + } + location @lp_outer { + rewrite ^/(.*)$ /lp/bingcorp last; + } + + # pass PHP scripts to FastCGI server + # + #location ~ \.php$ { + # include snippets/fastcgi-php.conf; + # + # # With php-fpm (or other unix sockets): + # fastcgi_pass unix:/var/run/php/php7.0-fpm.sock; + # # With php-cgi (or other tcp sockets): + # fastcgi_pass 127.0.0.1:9000; + #} + + # deny access to .htaccess files, if Apache's document root + # concurs with nginx's one + # + #location ~ /\.ht { + # deny all; + #} + + location /fms { + alias /var/www/html/fms/public; + try_files $uri @fms; + + proxy_read_timeout 12000; + proxy_connect_timeout 12000; + proxy_send_timeout 12000; + + location ~ \.php { + include snippets/fastcgi-php.conf; + fastcgi_pass unix:/var/run/php/php7.2-fpm.sock; + fastcgi_param SCRIPT_FILENAME /var/www/html/fms/public/index.php; + } + } + location @fms { + rewrite /fms/(.*)$ /fms/index.php?/$1 last; + } + + location /fms_dev { + alias /var/www/html/fms_dev/public; + try_files $uri @fms_dev; + + proxy_read_timeout 12000; + proxy_connect_timeout 12000; + proxy_send_timeout 12000; + + location ~ \.php { + include snippets/fastcgi-php.conf; + fastcgi_pass unix:/var/run/php/php7.2-fpm.sock; + fastcgi_param SCRIPT_FILENAME /var/www/html/fms_dev/public/index.php; + } + } + location @fms_dev { + rewrite /fms_dev/(.*)$ /fms_dev/index.php?/$1 last; + } + + location /lp { + alias /var/www/html/lp/public; + try_files $uri @lp; + + proxy_read_timeout 12000; + proxy_connect_timeout 12000; + proxy_send_timeout 12000; + + location ~ \.php { + include snippets/fastcgi-php.conf; + fastcgi_pass unix:/var/run/php/php7.2-fpm.sock; + fastcgi_param SCRIPT_FILENAME /var/www/html/lp/public/index.php; + } + } + location @lp { + rewrite /lp/(.*)$ /lp/index.php?/$1 last; + } + + # start part auto redirect https + #listen [::]:443 ssl ipv6only=on; # managed by Certbot + #listen 443 ssl; # managed by Certbot + #ssl_certificate /etc/letsencrypt/live/bingkis-corporate.com/fullchain.pem; # managed by Certbot + #ssl_certificate_key /etc/letsencrypt/live/bingkis-corporate.com/privkey.pem; # managed by Certbot + #include /etc/letsencrypt/options-ssl-nginx.conf; # managed by Certbot + #ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem; # managed by Certbot + # end part auto redirect https + +} + +server { + + # start part auto redirect https + #if ($host = www.bingkis-corporate.com) { + # return 301 https://$host$request_uri; + #} # managed by Certbot + + #if ($host = bingkis-corporate.com) { + # return 301 https://$host$request_uri; + #} # managed by Certbot + + #listen 80 default_server; + #listen [::]:80 default_server; + + #server_name bingkis-corporate.com www.bingkis-corporate.com; + #return 404; # managed by Certbot + # end part auto redirect https + + + listen 443 ssl default_server; + listen [::]:443 ssl default_server; + + server_name bingkis-corporate.com www.bingkis-corporate.com; + + #listen [::]:443 ssl ipv6only=on; # managed by Certbot + #listen 443 ssl; # managed by Certbot + ssl_certificate /etc/letsencrypt/live/bingkis-corporate.com/fullchain.pem; # managed by Certbot + ssl_certificate_key /etc/letsencrypt/live/bingkis-corporate.com/privkey.pem; # managed by Certbot + include /etc/letsencrypt/options-ssl-nginx.conf; # managed by Certbot + ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem; # managed by Certbot + + root /var/www/html; + + client_max_body_size 20m; + + location / { + alias /var/www/html/lp/public; + try_files $uri @lp_outer; + + proxy_read_timeout 12000; + proxy_connect_timeout 12000; + proxy_send_timeout 12000; + + location ~ \.php { + include snippets/fastcgi-php.conf; + fastcgi_pass unix:/var/run/php/php7.2-fpm.sock; + fastcgi_param SCRIPT_FILENAME /var/www/html/lp/public/index.php; + } + } + location @lp_outer { + rewrite ^/(.*)$ /lp/bingcorp last; + } + + location /fms { + alias /var/www/html/fms/public; + try_files $uri @fms; + + proxy_read_timeout 12000; + proxy_connect_timeout 12000; + proxy_send_timeout 12000; + + location ~ \.php { + include snippets/fastcgi-php.conf; + fastcgi_pass unix:/var/run/php/php7.2-fpm.sock; + fastcgi_param SCRIPT_FILENAME /var/www/html/fms/public/index.php; + } + } + location @fms { + rewrite /fms/(.*)$ /fms/index.php?/$1 last; + } + + location /fms_dev { + alias /var/www/html/fms_dev/public; + try_files $uri @fms_dev; + + proxy_read_timeout 12000; + proxy_connect_timeout 12000; + proxy_send_timeout 12000; + + location ~ \.php { + include snippets/fastcgi-php.conf; + fastcgi_pass unix:/var/run/php/php7.2-fpm.sock; + fastcgi_param SCRIPT_FILENAME /var/www/html/fms_dev/public/index.php; + } + } + location @fms_dev { + rewrite /fms_dev/(.*)$ /fms_dev/index.php?/$1 last; + } + + location /lp { + alias /var/www/html/lp/public; + try_files $uri @lp; + + proxy_read_timeout 12000; + proxy_connect_timeout 12000; + proxy_send_timeout 12000; + + location ~ \.php { + include snippets/fastcgi-php.conf; + fastcgi_pass unix:/var/run/php/php7.2-fpm.sock; + fastcgi_param SCRIPT_FILENAME /var/www/html/lp/public/index.php; + } + } + location @lp { + rewrite /lp/(.*)$ /lp/index.php?/$1 last; + } + +} \ No newline at end of file diff --git a/package-lock.json b/package-lock.json new file mode 100755 index 0000000..a5846d5 --- /dev/null +++ b/package-lock.json @@ -0,0 +1,9936 @@ +{ + "name": "sysadmin", + "lockfileVersion": 3, + "requires": true, + "packages": { + "": { + "devDependencies": { + "@prettier/plugin-php": "^0.19.4", + "axios": "^1.7.2", + "bootstrap": "^4.0.0", + "cross-env": "^7.0", + "jquery": "^3.2", + "laravel-mix": "^6.0.49", + "lodash": "^4.17.19", + "popper.js": "^1.12", + "prettier": "^2.8.7", + "resolve-url-loader": "^3.1.0", + "sass": "^1.15.2", + "sass-loader": "^8.0.0", + "vue-template-compiler": "^2.6.14" + } + }, + "node_modules/@ampproject/remapping": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/@ampproject/remapping/-/remapping-2.0.1.tgz", + "integrity": "sha512-EldHF4Ufj3NL9yCAmYrPzY+3/Yqrzxu24F4Mu4nRjK3w70AKYRmhuLwGZdA9JeoDsbIwkgGkbqUK2INuF582Og==", + "dev": true, + "dependencies": { + "@jridgewell/resolve-uri": "^3.0.3", + "@jridgewell/trace-mapping": "^0.2.2", + "sourcemap-codec": "1.4.8" + }, + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/@babel/code-frame": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.24.7.tgz", + "integrity": "sha512-BcYH1CVJBO9tvyIZ2jVeXgSIMvGZ2FDRvDdOIVQyuklNKSsx+eppDEBq/g47Ayw+RqNFE+URvOShmf+f/qwAlA==", + "dev": true, + "dependencies": { + "@babel/highlight": "^7.24.7", + "picocolors": "^1.0.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/compat-data": { + "version": "7.17.0", + "resolved": "https://registry.npmjs.org/@babel/compat-data/-/compat-data-7.17.0.tgz", + "integrity": "sha512-392byTlpGWXMv4FbyWw3sAZ/FrW/DrwqLGXpy0mbyNe9Taqv1mg9yON5/o0cnr8XYCkFTZbC1eV+c+LAROgrng==", + "dev": true, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/core": { + "version": "7.17.0", + "resolved": "https://registry.npmjs.org/@babel/core/-/core-7.17.0.tgz", + "integrity": "sha512-x/5Ea+RO5MvF9ize5DeVICJoVrNv0Mi2RnIABrZEKYvPEpldXwauPkgvYA17cKa6WpU3LoYvYbuEMFtSNFsarA==", + "dev": true, + "dependencies": { + "@ampproject/remapping": "^2.0.0", + "@babel/code-frame": "^7.16.7", + "@babel/generator": "^7.17.0", + "@babel/helper-compilation-targets": "^7.16.7", + "@babel/helper-module-transforms": "^7.16.7", + "@babel/helpers": "^7.17.0", + "@babel/parser": "^7.17.0", + "@babel/template": "^7.16.7", + "@babel/traverse": "^7.17.0", + "@babel/types": "^7.17.0", + "convert-source-map": "^1.7.0", + "debug": "^4.1.0", + "gensync": "^1.0.0-beta.2", + "json5": "^2.1.2", + "semver": "^6.3.0" + }, + "engines": { + "node": ">=6.9.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/babel" + } + }, + "node_modules/@babel/core/node_modules/debug": { + "version": "4.3.3", + "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.3.tgz", + "integrity": "sha512-/zxw5+vh1Tfv+4Qn7a5nsbcJKPaSvCDhojn6FEl9vupwK2VCSDtEiEtqr8DFtzYFOdz63LBkxec7DYuc2jon6Q==", + "dev": true, + "dependencies": { + "ms": "2.1.2" + }, + "engines": { + "node": ">=6.0" + }, + "peerDependenciesMeta": { + "supports-color": { + "optional": true + } + } + }, + "node_modules/@babel/core/node_modules/ms": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", + "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==", + "dev": true + }, + "node_modules/@babel/generator": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.24.7.tgz", + "integrity": "sha512-oipXieGC3i45Y1A41t4tAqpnEZWgB/lC6Ehh6+rOviR5XWpTtMmLN+fGjz9vOiNRt0p6RtO6DtD0pdU3vpqdSA==", + "dev": true, + "dependencies": { + "@babel/types": "^7.24.7", + "@jridgewell/gen-mapping": "^0.3.5", + "@jridgewell/trace-mapping": "^0.3.25", + "jsesc": "^2.5.1" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/generator/node_modules/@jridgewell/trace-mapping": { + "version": "0.3.25", + "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.25.tgz", + "integrity": "sha512-vNk6aEwybGtawWmy/PzwnGDOjCkLWSD2wqvjGGAgOAwCGWySYXfYoxt00IJkTF+8Lb57DwOb3Aa0o9CApepiYQ==", + "dev": true, + "dependencies": { + "@jridgewell/resolve-uri": "^3.1.0", + "@jridgewell/sourcemap-codec": "^1.4.14" + } + }, + "node_modules/@babel/helper-annotate-as-pure": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/helper-annotate-as-pure/-/helper-annotate-as-pure-7.16.7.tgz", + "integrity": "sha512-s6t2w/IPQVTAET1HitoowRGXooX8mCgtuP5195wD/QJPV6wYjpujCGF7JuMODVX2ZAJOf1GT6DT9MHEZvLOFSw==", + "dev": true, + "dependencies": { + "@babel/types": "^7.16.7" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-builder-binary-assignment-operator-visitor": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/helper-builder-binary-assignment-operator-visitor/-/helper-builder-binary-assignment-operator-visitor-7.16.7.tgz", + "integrity": "sha512-C6FdbRaxYjwVu/geKW4ZeQ0Q31AftgRcdSnZ5/jsH6BzCJbtvXvhpfkbkThYSuutZA7nCXpPR6AD9zd1dprMkA==", + "dev": true, + "dependencies": { + "@babel/helper-explode-assignable-expression": "^7.16.7", + "@babel/types": "^7.16.7" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-compilation-targets": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/helper-compilation-targets/-/helper-compilation-targets-7.16.7.tgz", + "integrity": "sha512-mGojBwIWcwGD6rfqgRXVlVYmPAv7eOpIemUG3dGnDdCY4Pae70ROij3XmfrH6Fa1h1aiDylpglbZyktfzyo/hA==", + "dev": true, + "dependencies": { + "@babel/compat-data": "^7.16.4", + "@babel/helper-validator-option": "^7.16.7", + "browserslist": "^4.17.5", + "semver": "^6.3.0" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/@babel/helper-create-class-features-plugin": { + "version": "7.17.0", + "resolved": "https://registry.npmjs.org/@babel/helper-create-class-features-plugin/-/helper-create-class-features-plugin-7.17.0.tgz", + "integrity": "sha512-S3+IHG72pJFb0RmJgeXg/TjVKt641ZsLla028haXJjdqCf9eccE5r1JsdO//L7nzTDzXjtC+hwV/lrkEb2+t0Q==", + "dev": true, + "dependencies": { + "@babel/helper-annotate-as-pure": "^7.16.7", + "@babel/helper-environment-visitor": "^7.16.7", + "@babel/helper-function-name": "^7.16.7", + "@babel/helper-member-expression-to-functions": "^7.16.7", + "@babel/helper-optimise-call-expression": "^7.16.7", + "@babel/helper-replace-supers": "^7.16.7", + "@babel/helper-split-export-declaration": "^7.16.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/@babel/helper-create-regexp-features-plugin": { + "version": "7.17.0", + "resolved": "https://registry.npmjs.org/@babel/helper-create-regexp-features-plugin/-/helper-create-regexp-features-plugin-7.17.0.tgz", + "integrity": "sha512-awO2So99wG6KnlE+TPs6rn83gCz5WlEePJDTnLEqbchMVrBeAujURVphRdigsk094VhvZehFoNOihSlcBjwsXA==", + "dev": true, + "dependencies": { + "@babel/helper-annotate-as-pure": "^7.16.7", + "regexpu-core": "^5.0.1" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/@babel/helper-define-polyfill-provider": { + "version": "0.3.1", + "resolved": "https://registry.npmjs.org/@babel/helper-define-polyfill-provider/-/helper-define-polyfill-provider-0.3.1.tgz", + "integrity": "sha512-J9hGMpJQmtWmj46B3kBHmL38UhJGhYX7eqkcq+2gsstyYt341HmPeWspihX43yVRA0mS+8GGk2Gckc7bY/HCmA==", + "dev": true, + "dependencies": { + "@babel/helper-compilation-targets": "^7.13.0", + "@babel/helper-module-imports": "^7.12.13", + "@babel/helper-plugin-utils": "^7.13.0", + "@babel/traverse": "^7.13.0", + "debug": "^4.1.1", + "lodash.debounce": "^4.0.8", + "resolve": "^1.14.2", + "semver": "^6.1.2" + }, + "peerDependencies": { + "@babel/core": "^7.4.0-0" + } + }, + "node_modules/@babel/helper-define-polyfill-provider/node_modules/debug": { + "version": "4.3.3", + "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.3.tgz", + "integrity": "sha512-/zxw5+vh1Tfv+4Qn7a5nsbcJKPaSvCDhojn6FEl9vupwK2VCSDtEiEtqr8DFtzYFOdz63LBkxec7DYuc2jon6Q==", + "dev": true, + "dependencies": { + "ms": "2.1.2" + }, + "engines": { + "node": ">=6.0" + }, + "peerDependenciesMeta": { + "supports-color": { + "optional": true + } + } + }, + "node_modules/@babel/helper-define-polyfill-provider/node_modules/ms": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", + "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==", + "dev": true + }, + "node_modules/@babel/helper-environment-visitor": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/helper-environment-visitor/-/helper-environment-visitor-7.24.7.tgz", + "integrity": "sha512-DoiN84+4Gnd0ncbBOM9AZENV4a5ZiL39HYMyZJGZ/AZEykHYdJw0wW3kdcsh9/Kn+BRXHLkkklZ51ecPKmI1CQ==", + "dev": true, + "dependencies": { + "@babel/types": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-explode-assignable-expression": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/helper-explode-assignable-expression/-/helper-explode-assignable-expression-7.16.7.tgz", + "integrity": "sha512-KyUenhWMC8VrxzkGP0Jizjo4/Zx+1nNZhgocs+gLzyZyB8SHidhoq9KK/8Ato4anhwsivfkBLftky7gvzbZMtQ==", + "dev": true, + "dependencies": { + "@babel/types": "^7.16.7" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-function-name": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/helper-function-name/-/helper-function-name-7.24.7.tgz", + "integrity": "sha512-FyoJTsj/PEUWu1/TYRiXTIHc8lbw+TDYkZuoE43opPS5TrI7MyONBE1oNvfguEXAD9yhQRrVBnXdXzSLQl9XnA==", + "dev": true, + "dependencies": { + "@babel/template": "^7.24.7", + "@babel/types": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-hoist-variables": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/helper-hoist-variables/-/helper-hoist-variables-7.24.7.tgz", + "integrity": "sha512-MJJwhkoGy5c4ehfoRyrJ/owKeMl19U54h27YYftT0o2teQ3FJ3nQUf/I3LlJsX4l3qlw7WRXUmiyajvHXoTubQ==", + "dev": true, + "dependencies": { + "@babel/types": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-member-expression-to-functions": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/helper-member-expression-to-functions/-/helper-member-expression-to-functions-7.16.7.tgz", + "integrity": "sha512-VtJ/65tYiU/6AbMTDwyoXGPKHgTsfRarivm+YbB5uAzKUyuPjgZSgAFeG87FCigc7KNHu2Pegh1XIT3lXjvz3Q==", + "dev": true, + "dependencies": { + "@babel/types": "^7.16.7" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-module-imports": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/helper-module-imports/-/helper-module-imports-7.16.7.tgz", + "integrity": "sha512-LVtS6TqjJHFc+nYeITRo6VLXve70xmq7wPhWTqDJusJEgGmkAACWwMiTNrvfoQo6hEhFwAIixNkvB0jPXDL8Wg==", + "dev": true, + "dependencies": { + "@babel/types": "^7.16.7" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-module-transforms": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/helper-module-transforms/-/helper-module-transforms-7.16.7.tgz", + "integrity": "sha512-gaqtLDxJEFCeQbYp9aLAefjhkKdjKcdh6DB7jniIGU3Pz52WAmP268zK0VgPz9hUNkMSYeH976K2/Y6yPadpng==", + "dev": true, + "dependencies": { + "@babel/helper-environment-visitor": "^7.16.7", + "@babel/helper-module-imports": "^7.16.7", + "@babel/helper-simple-access": "^7.16.7", + "@babel/helper-split-export-declaration": "^7.16.7", + "@babel/helper-validator-identifier": "^7.16.7", + "@babel/template": "^7.16.7", + "@babel/traverse": "^7.16.7", + "@babel/types": "^7.16.7" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-optimise-call-expression": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/helper-optimise-call-expression/-/helper-optimise-call-expression-7.16.7.tgz", + "integrity": "sha512-EtgBhg7rd/JcnpZFXpBy0ze1YRfdm7BnBX4uKMBd3ixa3RGAE002JZB66FJyNH7g0F38U05pXmA5P8cBh7z+1w==", + "dev": true, + "dependencies": { + "@babel/types": "^7.16.7" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-plugin-utils": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/helper-plugin-utils/-/helper-plugin-utils-7.16.7.tgz", + "integrity": "sha512-Qg3Nk7ZxpgMrsox6HreY1ZNKdBq7K72tDSliA6dCl5f007jR4ne8iD5UzuNnCJH2xBf2BEEVGr+/OL6Gdp7RxA==", + "dev": true, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-remap-async-to-generator": { + "version": "7.16.8", + "resolved": "https://registry.npmjs.org/@babel/helper-remap-async-to-generator/-/helper-remap-async-to-generator-7.16.8.tgz", + "integrity": "sha512-fm0gH7Flb8H51LqJHy3HJ3wnE1+qtYR2A99K06ahwrawLdOFsCEWjZOrYricXJHoPSudNKxrMBUPEIPxiIIvBw==", + "dev": true, + "dependencies": { + "@babel/helper-annotate-as-pure": "^7.16.7", + "@babel/helper-wrap-function": "^7.16.8", + "@babel/types": "^7.16.8" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-replace-supers": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/helper-replace-supers/-/helper-replace-supers-7.16.7.tgz", + "integrity": "sha512-y9vsWilTNaVnVh6xiJfABzsNpgDPKev9HnAgz6Gb1p6UUwf9NepdlsV7VXGCftJM+jqD5f7JIEubcpLjZj5dBw==", + "dev": true, + "dependencies": { + "@babel/helper-environment-visitor": "^7.16.7", + "@babel/helper-member-expression-to-functions": "^7.16.7", + "@babel/helper-optimise-call-expression": "^7.16.7", + "@babel/traverse": "^7.16.7", + "@babel/types": "^7.16.7" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-simple-access": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/helper-simple-access/-/helper-simple-access-7.16.7.tgz", + "integrity": "sha512-ZIzHVyoeLMvXMN/vok/a4LWRy8G2v205mNP0XOuf9XRLyX5/u9CnVulUtDgUTama3lT+bf/UqucuZjqiGuTS1g==", + "dev": true, + "dependencies": { + "@babel/types": "^7.16.7" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-skip-transparent-expression-wrappers": { + "version": "7.16.0", + "resolved": "https://registry.npmjs.org/@babel/helper-skip-transparent-expression-wrappers/-/helper-skip-transparent-expression-wrappers-7.16.0.tgz", + "integrity": "sha512-+il1gTy0oHwUsBQZyJvukbB4vPMdcYBrFHa0Uc4AizLxbq6BOYC51Rv4tWocX9BLBDLZ4kc6qUFpQ6HRgL+3zw==", + "dev": true, + "dependencies": { + "@babel/types": "^7.16.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-split-export-declaration": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.24.7.tgz", + "integrity": "sha512-oy5V7pD+UvfkEATUKvIjvIAH/xCzfsFVw7ygW2SI6NClZzquT+mwdTfgfdbUiceh6iQO0CHtCPsyze/MZ2YbAA==", + "dev": true, + "dependencies": { + "@babel/types": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-string-parser": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/helper-string-parser/-/helper-string-parser-7.24.7.tgz", + "integrity": "sha512-7MbVt6xrwFQbunH2DNQsAP5sTGxfqQtErvBIvIMi6EQnbgUOuVYanvREcmFrOPhoXBrTtjhhP+lW+o5UfK+tDg==", + "dev": true, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-validator-identifier": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.24.7.tgz", + "integrity": "sha512-rR+PBcQ1SMQDDyF6X0wxtG8QyLCgUB0eRAGguqRLfkCA87l7yAP7ehq8SNj96OOGTO8OBV70KhuFYcIkHXOg0w==", + "dev": true, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-validator-option": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/helper-validator-option/-/helper-validator-option-7.16.7.tgz", + "integrity": "sha512-TRtenOuRUVo9oIQGPC5G9DgK4743cdxvtOw0weQNpZXaS16SCBi5MNjZF8vba3ETURjZpTbVn7Vvcf2eAwFozQ==", + "dev": true, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-wrap-function": { + "version": "7.16.8", + "resolved": "https://registry.npmjs.org/@babel/helper-wrap-function/-/helper-wrap-function-7.16.8.tgz", + "integrity": "sha512-8RpyRVIAW1RcDDGTA+GpPAwV22wXCfKOoM9bet6TLkGIFTkRQSkH1nMQ5Yet4MpoXe1ZwHPVtNasc2w0uZMqnw==", + "dev": true, + "dependencies": { + "@babel/helper-function-name": "^7.16.7", + "@babel/template": "^7.16.7", + "@babel/traverse": "^7.16.8", + "@babel/types": "^7.16.8" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helpers": { + "version": "7.17.0", + "resolved": "https://registry.npmjs.org/@babel/helpers/-/helpers-7.17.0.tgz", + "integrity": "sha512-Xe/9NFxjPwELUvW2dsukcMZIp6XwPSbI4ojFBJuX5ramHuVE22SVcZIwqzdWo5uCgeTXW8qV97lMvSOjq+1+nQ==", + "dev": true, + "dependencies": { + "@babel/template": "^7.16.7", + "@babel/traverse": "^7.17.0", + "@babel/types": "^7.17.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/highlight": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.24.7.tgz", + "integrity": "sha512-EStJpq4OuY8xYfhGVXngigBJRWxftKX9ksiGDnmlY3o7B/V7KIAc9X4oiK87uPJSc/vs5L869bem5fhZa8caZw==", + "dev": true, + "dependencies": { + "@babel/helper-validator-identifier": "^7.24.7", + "chalk": "^2.4.2", + "js-tokens": "^4.0.0", + "picocolors": "^1.0.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/parser": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.24.7.tgz", + "integrity": "sha512-9uUYRm6OqQrCqQdG1iCBwBPZgN8ciDBro2nIOFaiRz1/BCxaI7CNvQbDHvsArAC7Tw9Hda/B3U+6ui9u4HWXPw==", + "dev": true, + "bin": { + "parser": "bin/babel-parser.js" + }, + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression/-/plugin-bugfix-safari-id-destructuring-collision-in-function-expression-7.16.7.tgz", + "integrity": "sha512-anv/DObl7waiGEnC24O9zqL0pSuI9hljihqiDuFHC8d7/bjr/4RLGPWuc8rYOff/QPzbEPSkzG8wGG9aDuhHRg==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.16.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining/-/plugin-bugfix-v8-spread-parameters-in-optional-chaining-7.16.7.tgz", + "integrity": "sha512-di8vUHRdf+4aJ7ltXhaDbPoszdkh59AQtJM5soLsuHpQJdFQZOA4uGj0V2u/CZ8bJ/u8ULDL5yq6FO/bCXnKHw==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.16.7", + "@babel/helper-skip-transparent-expression-wrappers": "^7.16.0", + "@babel/plugin-proposal-optional-chaining": "^7.16.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.13.0" + } + }, + "node_modules/@babel/plugin-proposal-async-generator-functions": { + "version": "7.16.8", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-async-generator-functions/-/plugin-proposal-async-generator-functions-7.16.8.tgz", + "integrity": "sha512-71YHIvMuiuqWJQkebWJtdhQTfd4Q4mF76q2IX37uZPkG9+olBxsX+rH1vkhFto4UeJZ9dPY2s+mDvhDm1u2BGQ==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.16.7", + "@babel/helper-remap-async-to-generator": "^7.16.8", + "@babel/plugin-syntax-async-generators": "^7.8.4" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-proposal-class-properties": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-class-properties/-/plugin-proposal-class-properties-7.16.7.tgz", + "integrity": "sha512-IobU0Xme31ewjYOShSIqd/ZGM/r/cuOz2z0MDbNrhF5FW+ZVgi0f2lyeoj9KFPDOAqsYxmLWZte1WOwlvY9aww==", + "dev": true, + "dependencies": { + "@babel/helper-create-class-features-plugin": "^7.16.7", + "@babel/helper-plugin-utils": "^7.16.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-proposal-class-static-block": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-class-static-block/-/plugin-proposal-class-static-block-7.16.7.tgz", + "integrity": "sha512-dgqJJrcZoG/4CkMopzhPJjGxsIe9A8RlkQLnL/Vhhx8AA9ZuaRwGSlscSh42hazc7WSrya/IK7mTeoF0DP9tEw==", + "dev": true, + "dependencies": { + "@babel/helper-create-class-features-plugin": "^7.16.7", + "@babel/helper-plugin-utils": "^7.16.7", + "@babel/plugin-syntax-class-static-block": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.12.0" + } + }, + "node_modules/@babel/plugin-proposal-dynamic-import": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-dynamic-import/-/plugin-proposal-dynamic-import-7.16.7.tgz", + "integrity": "sha512-I8SW9Ho3/8DRSdmDdH3gORdyUuYnk1m4cMxUAdu5oy4n3OfN8flDEH+d60iG7dUfi0KkYwSvoalHzzdRzpWHTg==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.16.7", + "@babel/plugin-syntax-dynamic-import": "^7.8.3" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-proposal-export-namespace-from": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-export-namespace-from/-/plugin-proposal-export-namespace-from-7.16.7.tgz", + "integrity": "sha512-ZxdtqDXLRGBL64ocZcs7ovt71L3jhC1RGSyR996svrCi3PYqHNkb3SwPJCs8RIzD86s+WPpt2S73+EHCGO+NUA==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.16.7", + "@babel/plugin-syntax-export-namespace-from": "^7.8.3" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-proposal-json-strings": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-json-strings/-/plugin-proposal-json-strings-7.16.7.tgz", + "integrity": "sha512-lNZ3EEggsGY78JavgbHsK9u5P3pQaW7k4axlgFLYkMd7UBsiNahCITShLjNQschPyjtO6dADrL24757IdhBrsQ==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.16.7", + "@babel/plugin-syntax-json-strings": "^7.8.3" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-proposal-logical-assignment-operators": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-logical-assignment-operators/-/plugin-proposal-logical-assignment-operators-7.16.7.tgz", + "integrity": "sha512-K3XzyZJGQCr00+EtYtrDjmwX7o7PLK6U9bi1nCwkQioRFVUv6dJoxbQjtWVtP+bCPy82bONBKG8NPyQ4+i6yjg==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.16.7", + "@babel/plugin-syntax-logical-assignment-operators": "^7.10.4" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-proposal-nullish-coalescing-operator": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-nullish-coalescing-operator/-/plugin-proposal-nullish-coalescing-operator-7.16.7.tgz", + "integrity": "sha512-aUOrYU3EVtjf62jQrCj63pYZ7k6vns2h/DQvHPWGmsJRYzWXZ6/AsfgpiRy6XiuIDADhJzP2Q9MwSMKauBQ+UQ==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.16.7", + "@babel/plugin-syntax-nullish-coalescing-operator": "^7.8.3" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-proposal-numeric-separator": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-numeric-separator/-/plugin-proposal-numeric-separator-7.16.7.tgz", + "integrity": "sha512-vQgPMknOIgiuVqbokToyXbkY/OmmjAzr/0lhSIbG/KmnzXPGwW/AdhdKpi+O4X/VkWiWjnkKOBiqJrTaC98VKw==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.16.7", + "@babel/plugin-syntax-numeric-separator": "^7.10.4" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-proposal-object-rest-spread": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-object-rest-spread/-/plugin-proposal-object-rest-spread-7.16.7.tgz", + "integrity": "sha512-3O0Y4+dw94HA86qSg9IHfyPktgR7q3gpNVAeiKQd+8jBKFaU5NQS1Yatgo4wY+UFNuLjvxcSmzcsHqrhgTyBUA==", + "dev": true, + "dependencies": { + "@babel/compat-data": "^7.16.4", + "@babel/helper-compilation-targets": "^7.16.7", + "@babel/helper-plugin-utils": "^7.16.7", + "@babel/plugin-syntax-object-rest-spread": "^7.8.3", + "@babel/plugin-transform-parameters": "^7.16.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-proposal-optional-catch-binding": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-optional-catch-binding/-/plugin-proposal-optional-catch-binding-7.16.7.tgz", + "integrity": "sha512-eMOH/L4OvWSZAE1VkHbr1vckLG1WUcHGJSLqqQwl2GaUqG6QjddvrOaTUMNYiv77H5IKPMZ9U9P7EaHwvAShfA==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.16.7", + "@babel/plugin-syntax-optional-catch-binding": "^7.8.3" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-proposal-optional-chaining": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-optional-chaining/-/plugin-proposal-optional-chaining-7.16.7.tgz", + "integrity": "sha512-eC3xy+ZrUcBtP7x+sq62Q/HYd674pPTb/77XZMb5wbDPGWIdUbSr4Agr052+zaUPSb+gGRnjxXfKFvx5iMJ+DA==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.16.7", + "@babel/helper-skip-transparent-expression-wrappers": "^7.16.0", + "@babel/plugin-syntax-optional-chaining": "^7.8.3" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-proposal-private-methods": { + "version": "7.16.11", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-private-methods/-/plugin-proposal-private-methods-7.16.11.tgz", + "integrity": "sha512-F/2uAkPlXDr8+BHpZvo19w3hLFKge+k75XUprE6jaqKxjGkSYcK+4c+bup5PdW/7W/Rpjwql7FTVEDW+fRAQsw==", + "dev": true, + "dependencies": { + "@babel/helper-create-class-features-plugin": "^7.16.10", + "@babel/helper-plugin-utils": "^7.16.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-proposal-private-property-in-object": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-private-property-in-object/-/plugin-proposal-private-property-in-object-7.16.7.tgz", + "integrity": "sha512-rMQkjcOFbm+ufe3bTZLyOfsOUOxyvLXZJCTARhJr+8UMSoZmqTe1K1BgkFcrW37rAchWg57yI69ORxiWvUINuQ==", + "dev": true, + "dependencies": { + "@babel/helper-annotate-as-pure": "^7.16.7", + "@babel/helper-create-class-features-plugin": "^7.16.7", + "@babel/helper-plugin-utils": "^7.16.7", + "@babel/plugin-syntax-private-property-in-object": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-proposal-unicode-property-regex": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-unicode-property-regex/-/plugin-proposal-unicode-property-regex-7.16.7.tgz", + "integrity": "sha512-QRK0YI/40VLhNVGIjRNAAQkEHws0cswSdFFjpFyt943YmJIU1da9uW63Iu6NFV6CxTZW5eTDCrwZUstBWgp/Rg==", + "dev": true, + "dependencies": { + "@babel/helper-create-regexp-features-plugin": "^7.16.7", + "@babel/helper-plugin-utils": "^7.16.7" + }, + "engines": { + "node": ">=4" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-async-generators": { + "version": "7.8.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-async-generators/-/plugin-syntax-async-generators-7.8.4.tgz", + "integrity": "sha512-tycmZxkGfZaxhMRbXlPXuVFpdWlXpir2W4AMhSJgRKzk/eDlIXOhb2LHWoLpDF7TEHylV5zNhykX6KAgHJmTNw==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-class-properties": { + "version": "7.12.13", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-class-properties/-/plugin-syntax-class-properties-7.12.13.tgz", + "integrity": "sha512-fm4idjKla0YahUNgFNLCB0qySdsoPiZP3iQE3rky0mBUtMZ23yDJ9SJdg6dXTSDnulOVqiF3Hgr9nbXvXTQZYA==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.12.13" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-class-static-block": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-class-static-block/-/plugin-syntax-class-static-block-7.14.5.tgz", + "integrity": "sha512-b+YyPmr6ldyNnM6sqYeMWE+bgJcJpO6yS4QD7ymxgH34GBPNDM/THBh8iunyvKIZztiwLH4CJZ0RxTk9emgpjw==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-dynamic-import": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-dynamic-import/-/plugin-syntax-dynamic-import-7.8.3.tgz", + "integrity": "sha512-5gdGbFon+PszYzqs83S3E5mpi7/y/8M9eC90MRTZfduQOYW76ig6SOSPNe41IG5LoP3FGBn2N0RjVDSQiS94kQ==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-export-namespace-from": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-export-namespace-from/-/plugin-syntax-export-namespace-from-7.8.3.tgz", + "integrity": "sha512-MXf5laXo6c1IbEbegDmzGPwGNTsHZmEy6QGznu5Sh2UCWvueywb2ee+CCE4zQiZstxU9BMoQO9i6zUFSY0Kj0Q==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.3" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-json-strings": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-json-strings/-/plugin-syntax-json-strings-7.8.3.tgz", + "integrity": "sha512-lY6kdGpWHvjoe2vk4WrAapEuBR69EMxZl+RoGRhrFGNYVK8mOPAW8VfbT/ZgrFbXlDNiiaxQnAtgVCZ6jv30EA==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-logical-assignment-operators": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-logical-assignment-operators/-/plugin-syntax-logical-assignment-operators-7.10.4.tgz", + "integrity": "sha512-d8waShlpFDinQ5MtvGU9xDAOzKH47+FFoney2baFIoMr952hKOLp1HR7VszoZvOsV/4+RRszNY7D17ba0te0ig==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.10.4" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-nullish-coalescing-operator": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-nullish-coalescing-operator/-/plugin-syntax-nullish-coalescing-operator-7.8.3.tgz", + "integrity": "sha512-aSff4zPII1u2QD7y+F8oDsz19ew4IGEJg9SVW+bqwpwtfFleiQDMdzA/R+UlWDzfnHFCxxleFT0PMIrR36XLNQ==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-numeric-separator": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-numeric-separator/-/plugin-syntax-numeric-separator-7.10.4.tgz", + "integrity": "sha512-9H6YdfkcK/uOnY/K7/aA2xpzaAgkQn37yzWUMRK7OaPOqOpGS1+n0H5hxT9AUw9EsSjPW8SVyMJwYRtWs3X3ug==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.10.4" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-object-rest-spread": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-object-rest-spread/-/plugin-syntax-object-rest-spread-7.8.3.tgz", + "integrity": "sha512-XoqMijGZb9y3y2XskN+P1wUGiVwWZ5JmoDRwx5+3GmEplNyVM2s2Dg8ILFQm8rWM48orGy5YpI5Bl8U1y7ydlA==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-optional-catch-binding": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-optional-catch-binding/-/plugin-syntax-optional-catch-binding-7.8.3.tgz", + "integrity": "sha512-6VPD0Pc1lpTqw0aKoeRTMiB+kWhAoT24PA+ksWSBrFtl5SIRVpZlwN3NNPQjehA2E/91FV3RjLWoVTglWcSV3Q==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-optional-chaining": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-optional-chaining/-/plugin-syntax-optional-chaining-7.8.3.tgz", + "integrity": "sha512-KoK9ErH1MBlCPxV0VANkXW2/dw4vlbGDrFgz8bmUsBGYkFRcbRwMh6cIJubdPrkxRwuGdtCk0v/wPTKbQgBjkg==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-private-property-in-object": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-private-property-in-object/-/plugin-syntax-private-property-in-object-7.14.5.tgz", + "integrity": "sha512-0wVnp9dxJ72ZUJDV27ZfbSj6iHLoytYZmh3rFcxNnvsJF3ktkzLDZPy/mA17HGsaQT3/DQsWYX1f1QGWkCoVUg==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-top-level-await": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-top-level-await/-/plugin-syntax-top-level-await-7.14.5.tgz", + "integrity": "sha512-hx++upLv5U1rgYfwe1xBQUhRmU41NEvpUvrp8jkrSCdvGSnM5/qdRMtylJ6PG5OFkBaHkbTAKTnd3/YyESRHFw==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-arrow-functions": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-arrow-functions/-/plugin-transform-arrow-functions-7.16.7.tgz", + "integrity": "sha512-9ffkFFMbvzTvv+7dTp/66xvZAWASuPD5Tl9LK3Z9vhOmANo6j94rik+5YMBt4CwHVMWLWpMsriIc2zsa3WW3xQ==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.16.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-async-to-generator": { + "version": "7.16.8", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-async-to-generator/-/plugin-transform-async-to-generator-7.16.8.tgz", + "integrity": "sha512-MtmUmTJQHCnyJVrScNzNlofQJ3dLFuobYn3mwOTKHnSCMtbNsqvF71GQmJfFjdrXSsAA7iysFmYWw4bXZ20hOg==", + "dev": true, + "dependencies": { + "@babel/helper-module-imports": "^7.16.7", + "@babel/helper-plugin-utils": "^7.16.7", + "@babel/helper-remap-async-to-generator": "^7.16.8" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-block-scoped-functions": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-block-scoped-functions/-/plugin-transform-block-scoped-functions-7.16.7.tgz", + "integrity": "sha512-JUuzlzmF40Z9cXyytcbZEZKckgrQzChbQJw/5PuEHYeqzCsvebDx0K0jWnIIVcmmDOAVctCgnYs0pMcrYj2zJg==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.16.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-block-scoping": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-block-scoping/-/plugin-transform-block-scoping-7.16.7.tgz", + "integrity": "sha512-ObZev2nxVAYA4bhyusELdo9hb3H+A56bxH3FZMbEImZFiEDYVHXQSJ1hQKFlDnlt8G9bBrCZ5ZpURZUrV4G5qQ==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.16.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-classes": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-classes/-/plugin-transform-classes-7.16.7.tgz", + "integrity": "sha512-WY7og38SFAGYRe64BrjKf8OrE6ulEHtr5jEYaZMwox9KebgqPi67Zqz8K53EKk1fFEJgm96r32rkKZ3qA2nCWQ==", + "dev": true, + "dependencies": { + "@babel/helper-annotate-as-pure": "^7.16.7", + "@babel/helper-environment-visitor": "^7.16.7", + "@babel/helper-function-name": "^7.16.7", + "@babel/helper-optimise-call-expression": "^7.16.7", + "@babel/helper-plugin-utils": "^7.16.7", + "@babel/helper-replace-supers": "^7.16.7", + "@babel/helper-split-export-declaration": "^7.16.7", + "globals": "^11.1.0" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-computed-properties": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-computed-properties/-/plugin-transform-computed-properties-7.16.7.tgz", + "integrity": "sha512-gN72G9bcmenVILj//sv1zLNaPyYcOzUho2lIJBMh/iakJ9ygCo/hEF9cpGb61SCMEDxbbyBoVQxrt+bWKu5KGw==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.16.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-destructuring": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-destructuring/-/plugin-transform-destructuring-7.16.7.tgz", + "integrity": "sha512-VqAwhTHBnu5xBVDCvrvqJbtLUa++qZaWC0Fgr2mqokBlulZARGyIvZDoqbPlPaKImQ9dKAcCzbv+ul//uqu70A==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.16.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-dotall-regex": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-dotall-regex/-/plugin-transform-dotall-regex-7.16.7.tgz", + "integrity": "sha512-Lyttaao2SjZF6Pf4vk1dVKv8YypMpomAbygW+mU5cYP3S5cWTfCJjG8xV6CFdzGFlfWK81IjL9viiTvpb6G7gQ==", + "dev": true, + "dependencies": { + "@babel/helper-create-regexp-features-plugin": "^7.16.7", + "@babel/helper-plugin-utils": "^7.16.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-duplicate-keys": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-duplicate-keys/-/plugin-transform-duplicate-keys-7.16.7.tgz", + "integrity": "sha512-03DvpbRfvWIXyK0/6QiR1KMTWeT6OcQ7tbhjrXyFS02kjuX/mu5Bvnh5SDSWHxyawit2g5aWhKwI86EE7GUnTw==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.16.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-exponentiation-operator": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-exponentiation-operator/-/plugin-transform-exponentiation-operator-7.16.7.tgz", + "integrity": "sha512-8UYLSlyLgRixQvlYH3J2ekXFHDFLQutdy7FfFAMm3CPZ6q9wHCwnUyiXpQCe3gVVnQlHc5nsuiEVziteRNTXEA==", + "dev": true, + "dependencies": { + "@babel/helper-builder-binary-assignment-operator-visitor": "^7.16.7", + "@babel/helper-plugin-utils": "^7.16.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-for-of": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-for-of/-/plugin-transform-for-of-7.16.7.tgz", + "integrity": "sha512-/QZm9W92Ptpw7sjI9Nx1mbcsWz33+l8kuMIQnDwgQBG5s3fAfQvkRjQ7NqXhtNcKOnPkdICmUHyCaWW06HCsqg==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.16.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-function-name": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-function-name/-/plugin-transform-function-name-7.16.7.tgz", + "integrity": "sha512-SU/C68YVwTRxqWj5kgsbKINakGag0KTgq9f2iZEXdStoAbOzLHEBRYzImmA6yFo8YZhJVflvXmIHUO7GWHmxxA==", + "dev": true, + "dependencies": { + "@babel/helper-compilation-targets": "^7.16.7", + "@babel/helper-function-name": "^7.16.7", + "@babel/helper-plugin-utils": "^7.16.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-literals": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-literals/-/plugin-transform-literals-7.16.7.tgz", + "integrity": "sha512-6tH8RTpTWI0s2sV6uq3e/C9wPo4PTqqZps4uF0kzQ9/xPLFQtipynvmT1g/dOfEJ+0EQsHhkQ/zyRId8J2b8zQ==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.16.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-member-expression-literals": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-member-expression-literals/-/plugin-transform-member-expression-literals-7.16.7.tgz", + "integrity": "sha512-mBruRMbktKQwbxaJof32LT9KLy2f3gH+27a5XSuXo6h7R3vqltl0PgZ80C8ZMKw98Bf8bqt6BEVi3svOh2PzMw==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.16.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-modules-amd": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-modules-amd/-/plugin-transform-modules-amd-7.16.7.tgz", + "integrity": "sha512-KaaEtgBL7FKYwjJ/teH63oAmE3lP34N3kshz8mm4VMAw7U3PxjVwwUmxEFksbgsNUaO3wId9R2AVQYSEGRa2+g==", + "dev": true, + "dependencies": { + "@babel/helper-module-transforms": "^7.16.7", + "@babel/helper-plugin-utils": "^7.16.7", + "babel-plugin-dynamic-import-node": "^2.3.3" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-modules-commonjs": { + "version": "7.16.8", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-modules-commonjs/-/plugin-transform-modules-commonjs-7.16.8.tgz", + "integrity": "sha512-oflKPvsLT2+uKQopesJt3ApiaIS2HW+hzHFcwRNtyDGieAeC/dIHZX8buJQ2J2X1rxGPy4eRcUijm3qcSPjYcA==", + "dev": true, + "dependencies": { + "@babel/helper-module-transforms": "^7.16.7", + "@babel/helper-plugin-utils": "^7.16.7", + "@babel/helper-simple-access": "^7.16.7", + "babel-plugin-dynamic-import-node": "^2.3.3" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-modules-systemjs": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-modules-systemjs/-/plugin-transform-modules-systemjs-7.16.7.tgz", + "integrity": "sha512-DuK5E3k+QQmnOqBR9UkusByy5WZWGRxfzV529s9nPra1GE7olmxfqO2FHobEOYSPIjPBTr4p66YDcjQnt8cBmw==", + "dev": true, + "dependencies": { + "@babel/helper-hoist-variables": "^7.16.7", + "@babel/helper-module-transforms": "^7.16.7", + "@babel/helper-plugin-utils": "^7.16.7", + "@babel/helper-validator-identifier": "^7.16.7", + "babel-plugin-dynamic-import-node": "^2.3.3" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-modules-umd": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-modules-umd/-/plugin-transform-modules-umd-7.16.7.tgz", + "integrity": "sha512-EMh7uolsC8O4xhudF2F6wedbSHm1HHZ0C6aJ7K67zcDNidMzVcxWdGr+htW9n21klm+bOn+Rx4CBsAntZd3rEQ==", + "dev": true, + "dependencies": { + "@babel/helper-module-transforms": "^7.16.7", + "@babel/helper-plugin-utils": "^7.16.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-named-capturing-groups-regex": { + "version": "7.16.8", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-named-capturing-groups-regex/-/plugin-transform-named-capturing-groups-regex-7.16.8.tgz", + "integrity": "sha512-j3Jw+n5PvpmhRR+mrgIh04puSANCk/T/UA3m3P1MjJkhlK906+ApHhDIqBQDdOgL/r1UYpz4GNclTXxyZrYGSw==", + "dev": true, + "dependencies": { + "@babel/helper-create-regexp-features-plugin": "^7.16.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/@babel/plugin-transform-new-target": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-new-target/-/plugin-transform-new-target-7.16.7.tgz", + "integrity": "sha512-xiLDzWNMfKoGOpc6t3U+etCE2yRnn3SM09BXqWPIZOBpL2gvVrBWUKnsJx0K/ADi5F5YC5f8APFfWrz25TdlGg==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.16.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-object-super": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-object-super/-/plugin-transform-object-super-7.16.7.tgz", + "integrity": "sha512-14J1feiQVWaGvRxj2WjyMuXS2jsBkgB3MdSN5HuC2G5nRspa5RK9COcs82Pwy5BuGcjb+fYaUj94mYcOj7rCvw==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.16.7", + "@babel/helper-replace-supers": "^7.16.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-parameters": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-parameters/-/plugin-transform-parameters-7.16.7.tgz", + "integrity": "sha512-AT3MufQ7zZEhU2hwOA11axBnExW0Lszu4RL/tAlUJBuNoRak+wehQW8h6KcXOcgjY42fHtDxswuMhMjFEuv/aw==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.16.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-property-literals": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-property-literals/-/plugin-transform-property-literals-7.16.7.tgz", + "integrity": "sha512-z4FGr9NMGdoIl1RqavCqGG+ZuYjfZ/hkCIeuH6Do7tXmSm0ls11nYVSJqFEUOSJbDab5wC6lRE/w6YjVcr6Hqw==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.16.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-regenerator": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-regenerator/-/plugin-transform-regenerator-7.16.7.tgz", + "integrity": "sha512-mF7jOgGYCkSJagJ6XCujSQg+6xC1M77/03K2oBmVJWoFGNUtnVJO4WHKJk3dnPC8HCcj4xBQP1Egm8DWh3Pb3Q==", + "dev": true, + "dependencies": { + "regenerator-transform": "^0.14.2" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-reserved-words": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-reserved-words/-/plugin-transform-reserved-words-7.16.7.tgz", + "integrity": "sha512-KQzzDnZ9hWQBjwi5lpY5v9shmm6IVG0U9pB18zvMu2i4H90xpT4gmqwPYsn8rObiadYe2M0gmgsiOIF5A/2rtg==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.16.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-runtime": { + "version": "7.17.0", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-runtime/-/plugin-transform-runtime-7.17.0.tgz", + "integrity": "sha512-fr7zPWnKXNc1xoHfrIU9mN/4XKX4VLZ45Q+oMhfsYIaHvg7mHgmhfOy/ckRWqDK7XF3QDigRpkh5DKq6+clE8A==", + "dev": true, + "dependencies": { + "@babel/helper-module-imports": "^7.16.7", + "@babel/helper-plugin-utils": "^7.16.7", + "babel-plugin-polyfill-corejs2": "^0.3.0", + "babel-plugin-polyfill-corejs3": "^0.5.0", + "babel-plugin-polyfill-regenerator": "^0.3.0", + "semver": "^6.3.0" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-shorthand-properties": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-shorthand-properties/-/plugin-transform-shorthand-properties-7.16.7.tgz", + "integrity": "sha512-hah2+FEnoRoATdIb05IOXf+4GzXYTq75TVhIn1PewihbpyrNWUt2JbudKQOETWw6QpLe+AIUpJ5MVLYTQbeeUg==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.16.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-spread": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-spread/-/plugin-transform-spread-7.16.7.tgz", + "integrity": "sha512-+pjJpgAngb53L0iaA5gU/1MLXJIfXcYepLgXB3esVRf4fqmj8f2cxM3/FKaHsZms08hFQJkFccEWuIpm429TXg==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.16.7", + "@babel/helper-skip-transparent-expression-wrappers": "^7.16.0" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-sticky-regex": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-sticky-regex/-/plugin-transform-sticky-regex-7.16.7.tgz", + "integrity": "sha512-NJa0Bd/87QV5NZZzTuZG5BPJjLYadeSZ9fO6oOUoL4iQx+9EEuw/eEM92SrsT19Yc2jgB1u1hsjqDtH02c3Drw==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.16.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-template-literals": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-template-literals/-/plugin-transform-template-literals-7.16.7.tgz", + "integrity": "sha512-VwbkDDUeenlIjmfNeDX/V0aWrQH2QiVyJtwymVQSzItFDTpxfyJh3EVaQiS0rIN/CqbLGr0VcGmuwyTdZtdIsA==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.16.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-typeof-symbol": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-typeof-symbol/-/plugin-transform-typeof-symbol-7.16.7.tgz", + "integrity": "sha512-p2rOixCKRJzpg9JB4gjnG4gjWkWa89ZoYUnl9snJ1cWIcTH/hvxZqfO+WjG6T8DRBpctEol5jw1O5rA8gkCokQ==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.16.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-unicode-escapes": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-unicode-escapes/-/plugin-transform-unicode-escapes-7.16.7.tgz", + "integrity": "sha512-TAV5IGahIz3yZ9/Hfv35TV2xEm+kaBDaZQCn2S/hG9/CZ0DktxJv9eKfPc7yYCvOYR4JGx1h8C+jcSOvgaaI/Q==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.16.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-unicode-regex": { + "version": "7.16.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-unicode-regex/-/plugin-transform-unicode-regex-7.16.7.tgz", + "integrity": "sha512-oC5tYYKw56HO75KZVLQ+R/Nl3Hro9kf8iG0hXoaHP7tjAyCpvqBiSNe6vGrZni1Z6MggmUOC6A7VP7AVmw225Q==", + "dev": true, + "dependencies": { + "@babel/helper-create-regexp-features-plugin": "^7.16.7", + "@babel/helper-plugin-utils": "^7.16.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-env": { + "version": "7.16.11", + "resolved": "https://registry.npmjs.org/@babel/preset-env/-/preset-env-7.16.11.tgz", + "integrity": "sha512-qcmWG8R7ZW6WBRPZK//y+E3Cli151B20W1Rv7ln27vuPaXU/8TKms6jFdiJtF7UDTxcrb7mZd88tAeK9LjdT8g==", + "dev": true, + "dependencies": { + "@babel/compat-data": "^7.16.8", + "@babel/helper-compilation-targets": "^7.16.7", + "@babel/helper-plugin-utils": "^7.16.7", + "@babel/helper-validator-option": "^7.16.7", + "@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression": "^7.16.7", + "@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining": "^7.16.7", + "@babel/plugin-proposal-async-generator-functions": "^7.16.8", + "@babel/plugin-proposal-class-properties": "^7.16.7", + "@babel/plugin-proposal-class-static-block": "^7.16.7", + "@babel/plugin-proposal-dynamic-import": "^7.16.7", + "@babel/plugin-proposal-export-namespace-from": "^7.16.7", + "@babel/plugin-proposal-json-strings": "^7.16.7", + "@babel/plugin-proposal-logical-assignment-operators": "^7.16.7", + "@babel/plugin-proposal-nullish-coalescing-operator": "^7.16.7", + "@babel/plugin-proposal-numeric-separator": "^7.16.7", + "@babel/plugin-proposal-object-rest-spread": "^7.16.7", + "@babel/plugin-proposal-optional-catch-binding": "^7.16.7", + "@babel/plugin-proposal-optional-chaining": "^7.16.7", + "@babel/plugin-proposal-private-methods": "^7.16.11", + "@babel/plugin-proposal-private-property-in-object": "^7.16.7", + "@babel/plugin-proposal-unicode-property-regex": "^7.16.7", + "@babel/plugin-syntax-async-generators": "^7.8.4", + "@babel/plugin-syntax-class-properties": "^7.12.13", + "@babel/plugin-syntax-class-static-block": "^7.14.5", + "@babel/plugin-syntax-dynamic-import": "^7.8.3", + "@babel/plugin-syntax-export-namespace-from": "^7.8.3", + "@babel/plugin-syntax-json-strings": "^7.8.3", + "@babel/plugin-syntax-logical-assignment-operators": "^7.10.4", + "@babel/plugin-syntax-nullish-coalescing-operator": "^7.8.3", + "@babel/plugin-syntax-numeric-separator": "^7.10.4", + "@babel/plugin-syntax-object-rest-spread": "^7.8.3", + "@babel/plugin-syntax-optional-catch-binding": "^7.8.3", + "@babel/plugin-syntax-optional-chaining": "^7.8.3", + "@babel/plugin-syntax-private-property-in-object": "^7.14.5", + "@babel/plugin-syntax-top-level-await": "^7.14.5", + "@babel/plugin-transform-arrow-functions": "^7.16.7", + "@babel/plugin-transform-async-to-generator": "^7.16.8", + "@babel/plugin-transform-block-scoped-functions": "^7.16.7", + "@babel/plugin-transform-block-scoping": "^7.16.7", + "@babel/plugin-transform-classes": "^7.16.7", + "@babel/plugin-transform-computed-properties": "^7.16.7", + "@babel/plugin-transform-destructuring": "^7.16.7", + "@babel/plugin-transform-dotall-regex": "^7.16.7", + "@babel/plugin-transform-duplicate-keys": "^7.16.7", + "@babel/plugin-transform-exponentiation-operator": "^7.16.7", + "@babel/plugin-transform-for-of": "^7.16.7", + "@babel/plugin-transform-function-name": "^7.16.7", + "@babel/plugin-transform-literals": "^7.16.7", + "@babel/plugin-transform-member-expression-literals": "^7.16.7", + "@babel/plugin-transform-modules-amd": "^7.16.7", + "@babel/plugin-transform-modules-commonjs": "^7.16.8", + "@babel/plugin-transform-modules-systemjs": "^7.16.7", + "@babel/plugin-transform-modules-umd": "^7.16.7", + "@babel/plugin-transform-named-capturing-groups-regex": "^7.16.8", + "@babel/plugin-transform-new-target": "^7.16.7", + "@babel/plugin-transform-object-super": "^7.16.7", + "@babel/plugin-transform-parameters": "^7.16.7", + "@babel/plugin-transform-property-literals": "^7.16.7", + "@babel/plugin-transform-regenerator": "^7.16.7", + "@babel/plugin-transform-reserved-words": "^7.16.7", + "@babel/plugin-transform-shorthand-properties": "^7.16.7", + "@babel/plugin-transform-spread": "^7.16.7", + "@babel/plugin-transform-sticky-regex": "^7.16.7", + "@babel/plugin-transform-template-literals": "^7.16.7", + "@babel/plugin-transform-typeof-symbol": "^7.16.7", + "@babel/plugin-transform-unicode-escapes": "^7.16.7", + "@babel/plugin-transform-unicode-regex": "^7.16.7", + "@babel/preset-modules": "^0.1.5", + "@babel/types": "^7.16.8", + "babel-plugin-polyfill-corejs2": "^0.3.0", + "babel-plugin-polyfill-corejs3": "^0.5.0", + "babel-plugin-polyfill-regenerator": "^0.3.0", + "core-js-compat": "^3.20.2", + "semver": "^6.3.0" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-modules": { + "version": "0.1.5", + "resolved": "https://registry.npmjs.org/@babel/preset-modules/-/preset-modules-0.1.5.tgz", + "integrity": "sha512-A57th6YRG7oR3cq/yt/Y84MvGgE0eJG2F1JLhKuyG+jFxEgrd/HAMJatiFtmOiZurz+0DkrvbheCLaV5f2JfjA==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.0.0", + "@babel/plugin-proposal-unicode-property-regex": "^7.4.4", + "@babel/plugin-transform-dotall-regex": "^7.4.4", + "@babel/types": "^7.4.4", + "esutils": "^2.0.2" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/runtime": { + "version": "7.17.0", + "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.17.0.tgz", + "integrity": "sha512-etcO/ohMNaNA2UBdaXBBSX/3aEzFMRrVfaPv8Ptc0k+cWpWW0QFiGZ2XnVqQZI1Cf734LbPGmqBKWESfW4x/dQ==", + "dev": true, + "dependencies": { + "regenerator-runtime": "^0.13.4" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/template": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/template/-/template-7.24.7.tgz", + "integrity": "sha512-jYqfPrU9JTF0PmPy1tLYHW4Mp4KlgxJD9l2nP9fD6yT/ICi554DmrWBAEYpIelzjHf1msDP3PxJIRt/nFNfBig==", + "dev": true, + "dependencies": { + "@babel/code-frame": "^7.24.7", + "@babel/parser": "^7.24.7", + "@babel/types": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/traverse": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.24.7.tgz", + "integrity": "sha512-yb65Ed5S/QAcewNPh0nZczy9JdYXkkAbIsEo+P7BE7yO3txAY30Y/oPa3QkQ5It3xVG2kpKMg9MsdxZaO31uKA==", + "dev": true, + "dependencies": { + "@babel/code-frame": "^7.24.7", + "@babel/generator": "^7.24.7", + "@babel/helper-environment-visitor": "^7.24.7", + "@babel/helper-function-name": "^7.24.7", + "@babel/helper-hoist-variables": "^7.24.7", + "@babel/helper-split-export-declaration": "^7.24.7", + "@babel/parser": "^7.24.7", + "@babel/types": "^7.24.7", + "debug": "^4.3.1", + "globals": "^11.1.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/traverse/node_modules/debug": { + "version": "4.3.3", + "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.3.tgz", + "integrity": "sha512-/zxw5+vh1Tfv+4Qn7a5nsbcJKPaSvCDhojn6FEl9vupwK2VCSDtEiEtqr8DFtzYFOdz63LBkxec7DYuc2jon6Q==", + "dev": true, + "dependencies": { + "ms": "2.1.2" + }, + "engines": { + "node": ">=6.0" + }, + "peerDependenciesMeta": { + "supports-color": { + "optional": true + } + } + }, + "node_modules/@babel/traverse/node_modules/ms": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", + "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==", + "dev": true + }, + "node_modules/@babel/types": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.24.7.tgz", + "integrity": "sha512-XEFXSlxiG5td2EJRe8vOmRbaXVgfcBlszKujvVmWIK/UpywWljQCfzAv3RQCGujWQ1RD4YYWEAqDXfuJiy8f5Q==", + "dev": true, + "dependencies": { + "@babel/helper-string-parser": "^7.24.7", + "@babel/helper-validator-identifier": "^7.24.7", + "to-fast-properties": "^2.0.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@colors/colors": { + "version": "1.5.0", + "resolved": "https://registry.npmjs.org/@colors/colors/-/colors-1.5.0.tgz", + "integrity": "sha512-ooWCrlZP11i8GImSjTHYHLkvFDP48nS4+204nGb1RiX/WXYHmJA2III9/e2DWVabCESdW7hBAEzHRqUn9OUVvQ==", + "dev": true, + "optional": true, + "engines": { + "node": ">=0.1.90" + } + }, + "node_modules/@discoveryjs/json-ext": { + "version": "0.5.7", + "resolved": "https://registry.npmjs.org/@discoveryjs/json-ext/-/json-ext-0.5.7.tgz", + "integrity": "sha512-dBVuXR082gk3jsFp7Rd/JI4kytwGHecnCoTtXFb7DB6CNHp4rg5k1bhg0nWdLGLnOV71lmDzGQaLMy8iPLY0pw==", + "dev": true, + "engines": { + "node": ">=10.0.0" + } + }, + "node_modules/@jridgewell/gen-mapping": { + "version": "0.3.5", + "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.5.tgz", + "integrity": "sha512-IzL8ZoEDIBRWEzlCcRhOaCupYyN5gdIK+Q6fbFdPDg6HqX6jpkItn7DFIpW9LQzXG6Df9sA7+OKnq0qlz/GaQg==", + "dev": true, + "dependencies": { + "@jridgewell/set-array": "^1.2.1", + "@jridgewell/sourcemap-codec": "^1.4.10", + "@jridgewell/trace-mapping": "^0.3.24" + }, + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/@jridgewell/gen-mapping/node_modules/@jridgewell/trace-mapping": { + "version": "0.3.25", + "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.25.tgz", + "integrity": "sha512-vNk6aEwybGtawWmy/PzwnGDOjCkLWSD2wqvjGGAgOAwCGWySYXfYoxt00IJkTF+8Lb57DwOb3Aa0o9CApepiYQ==", + "dev": true, + "dependencies": { + "@jridgewell/resolve-uri": "^3.1.0", + "@jridgewell/sourcemap-codec": "^1.4.14" + } + }, + "node_modules/@jridgewell/resolve-uri": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.1.2.tgz", + "integrity": "sha512-bRISgCIjP20/tbWSPWMEi54QVPRZExkuD9lJL+UIxUKtwVJA8wW1Trb1jMs1RFXo1CBTNZ/5hpC9QvmKWdopKw==", + "dev": true, + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/@jridgewell/set-array": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/@jridgewell/set-array/-/set-array-1.2.1.tgz", + "integrity": "sha512-R8gLRTZeyp03ymzP/6Lil/28tGeGEzhx1q2k703KGWRAI1VdvPIXdG70VJc2pAMw3NA6JKL5hhFu1sJX0Mnn/A==", + "dev": true, + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/@jridgewell/source-map": { + "version": "0.3.6", + "resolved": "https://registry.npmjs.org/@jridgewell/source-map/-/source-map-0.3.6.tgz", + "integrity": "sha512-1ZJTZebgqllO79ue2bm3rIGud/bOe0pP5BjSRCRxxYkEZS8STV7zN84UBbiYu7jy+eCKSnVIUgoWWE/tt+shMQ==", + "dev": true, + "dependencies": { + "@jridgewell/gen-mapping": "^0.3.5", + "@jridgewell/trace-mapping": "^0.3.25" + } + }, + "node_modules/@jridgewell/source-map/node_modules/@jridgewell/trace-mapping": { + "version": "0.3.25", + "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.25.tgz", + "integrity": "sha512-vNk6aEwybGtawWmy/PzwnGDOjCkLWSD2wqvjGGAgOAwCGWySYXfYoxt00IJkTF+8Lb57DwOb3Aa0o9CApepiYQ==", + "dev": true, + "dependencies": { + "@jridgewell/resolve-uri": "^3.1.0", + "@jridgewell/sourcemap-codec": "^1.4.14" + } + }, + "node_modules/@jridgewell/sourcemap-codec": { + "version": "1.4.15", + "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.15.tgz", + "integrity": "sha512-eF2rxCRulEKXHTRiDrDy6erMYWqNw4LPdQ8UQA4huuxaQsVeRPFl2oM8oDGxMFhJUWZf9McpLtJasDDZb/Bpeg==", + "dev": true + }, + "node_modules/@jridgewell/trace-mapping": { + "version": "0.2.3", + "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.2.3.tgz", + "integrity": "sha512-X8ybLjwxY8VNxEddYmlQQI14wVM+VSSTFnOuHTS3eplDSGAXKZuNuedBxgXGlcKdPjJOrgeygu8/dtVkA1YslQ==", + "dev": true, + "dependencies": { + "@jridgewell/resolve-uri": "^3.0.3", + "sourcemap-codec": "1.4.8" + } + }, + "node_modules/@leichtgewicht/ip-codec": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/@leichtgewicht/ip-codec/-/ip-codec-2.0.5.tgz", + "integrity": "sha512-Vo+PSpZG2/fmgmiNzYK9qWRh8h/CHrwD0mo1h1DzL4yzHNSfWYujGTYsWGreD000gcgmZ7K4Ys6Tx9TxtsKdDw==", + "dev": true + }, + "node_modules/@nodelib/fs.scandir": { + "version": "2.1.5", + "resolved": "https://registry.npmjs.org/@nodelib/fs.scandir/-/fs.scandir-2.1.5.tgz", + "integrity": "sha512-vq24Bq3ym5HEQm2NKCr3yXDwjc7vTsEThRDnkp2DK9p1uqLR+DHurm/NOTo0KG7HYHU7eppKZj3MyqYuMBf62g==", + "dev": true, + "dependencies": { + "@nodelib/fs.stat": "2.0.5", + "run-parallel": "^1.1.9" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/@nodelib/fs.stat": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/@nodelib/fs.stat/-/fs.stat-2.0.5.tgz", + "integrity": "sha512-RkhPPp2zrqDAQA/2jNhnztcPAlv64XdhIp7a7454A5ovI7Bukxgt7MX7udwAu3zg1DcpPU0rz3VV1SeaqvY4+A==", + "dev": true, + "engines": { + "node": ">= 8" + } + }, + "node_modules/@nodelib/fs.walk": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/@nodelib/fs.walk/-/fs.walk-1.2.8.tgz", + "integrity": "sha512-oGB+UxlgWcgQkgwo8GcEGwemoTFt3FIO9ababBmaGwXIoBKZ+GTy0pP185beGg7Llih/NSHSV2XAs1lnznocSg==", + "dev": true, + "dependencies": { + "@nodelib/fs.scandir": "2.1.5", + "fastq": "^1.6.0" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/@prettier/plugin-php": { + "version": "0.19.7", + "resolved": "https://registry.npmjs.org/@prettier/plugin-php/-/plugin-php-0.19.7.tgz", + "integrity": "sha512-QOzBs05nwuR92uak7xBHf7RCZCFXml+6Sk3cjTp2ahQlilBtupqlNjitlTXsOfPIAYwlFgLP1oSfyapS6DN00w==", + "dev": true, + "dependencies": { + "linguist-languages": "^7.21.0", + "mem": "^8.0.0", + "php-parser": "^3.1.5" + }, + "peerDependencies": { + "prettier": "^1.15.0 || ^2.0.0" + } + }, + "node_modules/@trysound/sax": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/@trysound/sax/-/sax-0.2.0.tgz", + "integrity": "sha512-L7z9BgrNEcYyUYtF+HaEfiS5ebkh9jXqbszz7pC0hRBPaatV0XjSD3+eHrpqFemQfgwiFF0QPIarnIihIDn7OA==", + "dev": true, + "engines": { + "node": ">=10.13.0" + } + }, + "node_modules/@types/babel__core": { + "version": "7.20.5", + "resolved": "https://registry.npmjs.org/@types/babel__core/-/babel__core-7.20.5.tgz", + "integrity": "sha512-qoQprZvz5wQFJwMDqeseRXWv3rqMvhgpbXFfVyWhbx9X47POIA6i/+dXefEmZKoAgOaTdaIgNSMqMIU61yRyzA==", + "dev": true, + "dependencies": { + "@babel/parser": "^7.20.7", + "@babel/types": "^7.20.7", + "@types/babel__generator": "*", + "@types/babel__template": "*", + "@types/babel__traverse": "*" + } + }, + "node_modules/@types/babel__generator": { + "version": "7.6.8", + "resolved": "https://registry.npmjs.org/@types/babel__generator/-/babel__generator-7.6.8.tgz", + "integrity": "sha512-ASsj+tpEDsEiFr1arWrlN6V3mdfjRMZt6LtK/Vp/kreFLnr5QH5+DhvD5nINYZXzwJvXeGq+05iUXcAzVrqWtw==", + "dev": true, + "dependencies": { + "@babel/types": "^7.0.0" + } + }, + "node_modules/@types/babel__template": { + "version": "7.4.4", + "resolved": "https://registry.npmjs.org/@types/babel__template/-/babel__template-7.4.4.tgz", + "integrity": "sha512-h/NUaSyG5EyxBIp8YRxo4RMe2/qQgvyowRwVMzhYhBCONbW8PUsg4lkFMrhgZhUe5z3L3MiLDuvyJ/CaPa2A8A==", + "dev": true, + "dependencies": { + "@babel/parser": "^7.1.0", + "@babel/types": "^7.0.0" + } + }, + "node_modules/@types/babel__traverse": { + "version": "7.20.6", + "resolved": "https://registry.npmjs.org/@types/babel__traverse/-/babel__traverse-7.20.6.tgz", + "integrity": "sha512-r1bzfrm0tomOI8g1SzvCaQHo6Lcv6zu0EA+W2kHrt8dyrHQxGzBBL4kdkzIS+jBMV+EYcMAEAqXqYaLJq5rOZg==", + "dev": true, + "dependencies": { + "@babel/types": "^7.20.7" + } + }, + "node_modules/@types/body-parser": { + "version": "1.19.5", + "resolved": "https://registry.npmjs.org/@types/body-parser/-/body-parser-1.19.5.tgz", + "integrity": "sha512-fB3Zu92ucau0iQ0JMCFQE7b/dv8Ot07NI3KaZIkIUNXq82k4eBAqUaneXfleGY9JWskeS9y+u0nXMyspcuQrCg==", + "dev": true, + "dependencies": { + "@types/connect": "*", + "@types/node": "*" + } + }, + "node_modules/@types/bonjour": { + "version": "3.5.13", + "resolved": "https://registry.npmjs.org/@types/bonjour/-/bonjour-3.5.13.tgz", + "integrity": "sha512-z9fJ5Im06zvUL548KvYNecEVlA7cVDkGUi6kZusb04mpyEFKCIZJvloCcmpmLaIahDpOQGHaHmG6imtPMmPXGQ==", + "dev": true, + "dependencies": { + "@types/node": "*" + } + }, + "node_modules/@types/clean-css": { + "version": "4.2.11", + "resolved": "https://registry.npmjs.org/@types/clean-css/-/clean-css-4.2.11.tgz", + "integrity": "sha512-Y8n81lQVTAfP2TOdtJJEsCoYl1AnOkqDqMvXb9/7pfgZZ7r8YrEyurrAvAoAjHOGXKRybay+5CsExqIH6liccw==", + "dev": true, + "dependencies": { + "@types/node": "*", + "source-map": "^0.6.0" + } + }, + "node_modules/@types/connect": { + "version": "3.4.38", + "resolved": "https://registry.npmjs.org/@types/connect/-/connect-3.4.38.tgz", + "integrity": "sha512-K6uROf1LD88uDQqJCktA4yzL1YYAK6NgfsI0v/mTgyPKWsX1CnJ0XPSDhViejru1GcRkLWb8RlzFYJRqGUbaug==", + "dev": true, + "dependencies": { + "@types/node": "*" + } + }, + "node_modules/@types/connect-history-api-fallback": { + "version": "1.5.4", + "resolved": "https://registry.npmjs.org/@types/connect-history-api-fallback/-/connect-history-api-fallback-1.5.4.tgz", + "integrity": "sha512-n6Cr2xS1h4uAulPRdlw6Jl6s1oG8KrVilPN2yUITEs+K48EzMJJ3W1xy8K5eWuFvjp3R74AOIGSmp2UfBJ8HFw==", + "dev": true, + "dependencies": { + "@types/express-serve-static-core": "*", + "@types/node": "*" + } + }, + "node_modules/@types/eslint": { + "version": "8.56.10", + "resolved": "https://registry.npmjs.org/@types/eslint/-/eslint-8.56.10.tgz", + "integrity": "sha512-Shavhk87gCtY2fhXDctcfS3e6FdxWkCx1iUZ9eEUbh7rTqlZT0/IzOkCOVt0fCjcFuZ9FPYfuezTBImfHCDBGQ==", + "dev": true, + "dependencies": { + "@types/estree": "*", + "@types/json-schema": "*" + } + }, + "node_modules/@types/eslint-scope": { + "version": "3.7.7", + "resolved": "https://registry.npmjs.org/@types/eslint-scope/-/eslint-scope-3.7.7.tgz", + "integrity": "sha512-MzMFlSLBqNF2gcHWO0G1vP/YQyfvrxZ0bF+u7mzUdZ1/xK4A4sru+nraZz5i3iEIk1l1uyicaDVTB4QbbEkAYg==", + "dev": true, + "dependencies": { + "@types/eslint": "*", + "@types/estree": "*" + } + }, + "node_modules/@types/estree": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.5.tgz", + "integrity": "sha512-/kYRxGDLWzHOB7q+wtSUQlFrtcdUccpfy+X+9iMBpHK8QLLhx2wIPYuS5DYtR9Wa/YlZAbIovy7qVdB1Aq6Lyw==", + "dev": true + }, + "node_modules/@types/express": { + "version": "4.17.21", + "resolved": "https://registry.npmjs.org/@types/express/-/express-4.17.21.tgz", + "integrity": "sha512-ejlPM315qwLpaQlQDTjPdsUFSc6ZsP4AN6AlWnogPjQ7CVi7PYF3YVz+CY3jE2pwYf7E/7HlDAN0rV2GxTG0HQ==", + "dev": true, + "dependencies": { + "@types/body-parser": "*", + "@types/express-serve-static-core": "^4.17.33", + "@types/qs": "*", + "@types/serve-static": "*" + } + }, + "node_modules/@types/express-serve-static-core": { + "version": "4.19.3", + "resolved": "https://registry.npmjs.org/@types/express-serve-static-core/-/express-serve-static-core-4.19.3.tgz", + "integrity": "sha512-KOzM7MhcBFlmnlr/fzISFF5vGWVSvN6fTd4T+ExOt08bA/dA5kpSzY52nMsI1KDFmUREpJelPYyuslLRSjjgCg==", + "dev": true, + "dependencies": { + "@types/node": "*", + "@types/qs": "*", + "@types/range-parser": "*", + "@types/send": "*" + } + }, + "node_modules/@types/glob": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/@types/glob/-/glob-7.2.0.tgz", + "integrity": "sha512-ZUxbzKl0IfJILTS6t7ip5fQQM/J3TJYubDm3nMbgubNNYS62eXeUpoLUC8/7fJNiFYHTrGPQn7hspDUzIHX3UA==", + "dev": true, + "dependencies": { + "@types/minimatch": "*", + "@types/node": "*" + } + }, + "node_modules/@types/http-errors": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/@types/http-errors/-/http-errors-2.0.4.tgz", + "integrity": "sha512-D0CFMMtydbJAegzOyHjtiKPLlvnm3iTZyZRSZoLq2mRhDdmLfIWOCYPfQJ4cu2erKghU++QvjcUjp/5h7hESpA==", + "dev": true + }, + "node_modules/@types/http-proxy": { + "version": "1.17.14", + "resolved": "https://registry.npmjs.org/@types/http-proxy/-/http-proxy-1.17.14.tgz", + "integrity": "sha512-SSrD0c1OQzlFX7pGu1eXxSEjemej64aaNPRhhVYUGqXh0BtldAAx37MG8btcumvpgKyZp1F5Gn3JkktdxiFv6w==", + "dev": true, + "dependencies": { + "@types/node": "*" + } + }, + "node_modules/@types/imagemin": { + "version": "9.0.0", + "resolved": "https://registry.npmjs.org/@types/imagemin/-/imagemin-9.0.0.tgz", + "integrity": "sha512-4IaT+BdPUAFf/AAy3XlFAbqGk4RawhdidxWO5XTe+PJAYAr4d7m2FHiqyEPXbDpwS+IaLIJq5AIjLE9HcwMGBg==", + "dev": true, + "dependencies": { + "@types/node": "*" + } + }, + "node_modules/@types/imagemin-gifsicle": { + "version": "7.0.4", + "resolved": "https://registry.npmjs.org/@types/imagemin-gifsicle/-/imagemin-gifsicle-7.0.4.tgz", + "integrity": "sha512-ZghMBd/Jgqg5utTJNPmvf6DkuHzMhscJ8vgf/7MUGCpO+G+cLrhYltL+5d+h3A1B4W73S2SrmJZ1jS5LACpX+A==", + "dev": true, + "dependencies": { + "@types/imagemin": "*" + } + }, + "node_modules/@types/imagemin-mozjpeg": { + "version": "8.0.4", + "resolved": "https://registry.npmjs.org/@types/imagemin-mozjpeg/-/imagemin-mozjpeg-8.0.4.tgz", + "integrity": "sha512-ZCAxV8SYJB8ehwHpnbRpHjg5Wc4HcyuAMiDhXbkgC7gujDoOTyHO3dhDkUtZ1oK1DLBRZapqG9etdLVhUml7yQ==", + "dev": true, + "dependencies": { + "@types/imagemin": "*" + } + }, + "node_modules/@types/imagemin-optipng": { + "version": "5.2.4", + "resolved": "https://registry.npmjs.org/@types/imagemin-optipng/-/imagemin-optipng-5.2.4.tgz", + "integrity": "sha512-mvKnDMC8eCYZetAQudjs1DbgpR84WhsTx1wgvdiXnpuUEti3oJ+MaMYBRWPY0JlQ4+y4TXKOfa7+LOuT8daegQ==", + "dev": true, + "dependencies": { + "@types/imagemin": "*" + } + }, + "node_modules/@types/imagemin-svgo": { + "version": "8.0.1", + "resolved": "https://registry.npmjs.org/@types/imagemin-svgo/-/imagemin-svgo-8.0.1.tgz", + "integrity": "sha512-YafkdrVAcr38U0Ln1C+L1n4SIZqC47VBHTyxCq7gTUSd1R9MdIvMcrljWlgU1M9O68WZDeQWUrKipKYfEOCOvQ==", + "dev": true, + "dependencies": { + "@types/imagemin": "*", + "@types/svgo": "^1" + } + }, + "node_modules/@types/json-schema": { + "version": "7.0.9", + "resolved": "https://registry.npmjs.org/@types/json-schema/-/json-schema-7.0.9.tgz", + "integrity": "sha512-qcUXuemtEu+E5wZSJHNxUXeCZhAfXKQ41D+duX+VYPde7xyEVZci+/oXKJL13tnRs9lR2pr4fod59GT6/X1/yQ==", + "dev": true + }, + "node_modules/@types/mime": { + "version": "1.3.5", + "resolved": "https://registry.npmjs.org/@types/mime/-/mime-1.3.5.tgz", + "integrity": "sha512-/pyBZWSLD2n0dcHE3hq8s8ZvcETHtEuF+3E7XVt0Ig2nvsVQXdghHVcEkIWjy9A0wKfTn97a/PSDYohKIlnP/w==", + "dev": true + }, + "node_modules/@types/minimatch": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/@types/minimatch/-/minimatch-5.1.2.tgz", + "integrity": "sha512-K0VQKziLUWkVKiRVrx4a40iPaxTUefQmjtkQofBkYRcoaaL/8rhwDWww9qWbrgicNOgnpIsMxyNIUM4+n6dUIA==", + "dev": true + }, + "node_modules/@types/node": { + "version": "20.14.2", + "resolved": "https://registry.npmjs.org/@types/node/-/node-20.14.2.tgz", + "integrity": "sha512-xyu6WAMVwv6AKFLB+e/7ySZVr/0zLCzOa7rSpq6jNwpqOrUbcACDWC+53d4n2QHOnDou0fbIsg8wZu/sxrnI4Q==", + "dev": true, + "dependencies": { + "undici-types": "~5.26.4" + } + }, + "node_modules/@types/node-forge": { + "version": "1.3.11", + "resolved": "https://registry.npmjs.org/@types/node-forge/-/node-forge-1.3.11.tgz", + "integrity": "sha512-FQx220y22OKNTqaByeBGqHWYz4cl94tpcxeFdvBo3wjG6XPBuZ0BNgNZRV5J5TFmmcsJ4IzsLkmGRiQbnYsBEQ==", + "dev": true, + "dependencies": { + "@types/node": "*" + } + }, + "node_modules/@types/parse-json": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/@types/parse-json/-/parse-json-4.0.2.tgz", + "integrity": "sha512-dISoDXWWQwUquiKsyZ4Ng+HX2KsPL7LyHKHQwgGFEA3IaKac4Obd+h2a/a6waisAoepJlBcx9paWqjA8/HVjCw==", + "dev": true + }, + "node_modules/@types/qs": { + "version": "6.9.15", + "resolved": "https://registry.npmjs.org/@types/qs/-/qs-6.9.15.tgz", + "integrity": "sha512-uXHQKES6DQKKCLh441Xv/dwxOq1TVS3JPUMlEqoEglvlhR6Mxnlew/Xq/LRVHpLyk7iK3zODe1qYHIMltO7XGg==", + "dev": true + }, + "node_modules/@types/range-parser": { + "version": "1.2.7", + "resolved": "https://registry.npmjs.org/@types/range-parser/-/range-parser-1.2.7.tgz", + "integrity": "sha512-hKormJbkJqzQGhziax5PItDUTMAM9uE2XXQmM37dyd4hVM+5aVl7oVxMVUiVQn2oCQFN/LKCZdvSM0pFRqbSmQ==", + "dev": true + }, + "node_modules/@types/retry": { + "version": "0.12.0", + "resolved": "https://registry.npmjs.org/@types/retry/-/retry-0.12.0.tgz", + "integrity": "sha512-wWKOClTTiizcZhXnPY4wikVAwmdYHp8q6DmC+EJUzAMsycb7HB32Kh9RN4+0gExjmPmZSAQjgURXIGATPegAvA==", + "dev": true + }, + "node_modules/@types/send": { + "version": "0.17.4", + "resolved": "https://registry.npmjs.org/@types/send/-/send-0.17.4.tgz", + "integrity": "sha512-x2EM6TJOybec7c52BX0ZspPodMsQUd5L6PRwOunVyVUhXiBSKf3AezDL8Dgvgt5o0UfKNfuA0eMLr2wLT4AiBA==", + "dev": true, + "dependencies": { + "@types/mime": "^1", + "@types/node": "*" + } + }, + "node_modules/@types/serve-index": { + "version": "1.9.4", + "resolved": "https://registry.npmjs.org/@types/serve-index/-/serve-index-1.9.4.tgz", + "integrity": "sha512-qLpGZ/c2fhSs5gnYsQxtDEq3Oy8SXPClIXkW5ghvAvsNuVSA8k+gCONcUCS/UjLEYvYps+e8uBtfgXgvhwfNug==", + "dev": true, + "dependencies": { + "@types/express": "*" + } + }, + "node_modules/@types/serve-static": { + "version": "1.15.7", + "resolved": "https://registry.npmjs.org/@types/serve-static/-/serve-static-1.15.7.tgz", + "integrity": "sha512-W8Ym+h8nhuRwaKPaDw34QUkwsGi6Rc4yYqvKFo5rm2FUEhCFbzVWrxXUxuKK8TASjWsysJY0nsmNCGhCOIsrOw==", + "dev": true, + "dependencies": { + "@types/http-errors": "*", + "@types/node": "*", + "@types/send": "*" + } + }, + "node_modules/@types/sockjs": { + "version": "0.3.36", + "resolved": "https://registry.npmjs.org/@types/sockjs/-/sockjs-0.3.36.tgz", + "integrity": "sha512-MK9V6NzAS1+Ud7JV9lJLFqW85VbC9dq3LmwZCuBe4wBDgKC0Kj/jd8Xl+nSviU+Qc3+m7umHHyHg//2KSa0a0Q==", + "dev": true, + "dependencies": { + "@types/node": "*" + } + }, + "node_modules/@types/svgo": { + "version": "1.3.6", + "resolved": "https://registry.npmjs.org/@types/svgo/-/svgo-1.3.6.tgz", + "integrity": "sha512-AZU7vQcy/4WFEuwnwsNsJnFwupIpbllH1++LXScN6uxT1Z4zPzdrWG97w4/I7eFKFTvfy/bHFStWjdBAg2Vjug==", + "dev": true + }, + "node_modules/@types/ws": { + "version": "8.5.10", + "resolved": "https://registry.npmjs.org/@types/ws/-/ws-8.5.10.tgz", + "integrity": "sha512-vmQSUcfalpIq0R9q7uTo2lXs6eGIpt9wtnLdMv9LVpIjCA/+ufZRozlVoVelIYixx1ugCBKDhn89vnsEGOCx9A==", + "dev": true, + "dependencies": { + "@types/node": "*" + } + }, + "node_modules/@webassemblyjs/ast": { + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/ast/-/ast-1.12.1.tgz", + "integrity": "sha512-EKfMUOPRRUTy5UII4qJDGPpqfwjOmZ5jeGFwid9mnoqIFK+e0vqoi1qH56JpmZSzEL53jKnNzScdmftJyG5xWg==", + "dev": true, + "dependencies": { + "@webassemblyjs/helper-numbers": "1.11.6", + "@webassemblyjs/helper-wasm-bytecode": "1.11.6" + } + }, + "node_modules/@webassemblyjs/floating-point-hex-parser": { + "version": "1.11.6", + "resolved": "https://registry.npmjs.org/@webassemblyjs/floating-point-hex-parser/-/floating-point-hex-parser-1.11.6.tgz", + "integrity": "sha512-ejAj9hfRJ2XMsNHk/v6Fu2dGS+i4UaXBXGemOfQ/JfQ6mdQg/WXtwleQRLLS4OvfDhv8rYnVwH27YJLMyYsxhw==", + "dev": true + }, + "node_modules/@webassemblyjs/helper-api-error": { + "version": "1.11.6", + "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-api-error/-/helper-api-error-1.11.6.tgz", + "integrity": "sha512-o0YkoP4pVu4rN8aTJgAyj9hC2Sv5UlkzCHhxqWj8butaLvnpdc2jOwh4ewE6CX0txSfLn/UYaV/pheS2Txg//Q==", + "dev": true + }, + "node_modules/@webassemblyjs/helper-buffer": { + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-buffer/-/helper-buffer-1.12.1.tgz", + "integrity": "sha512-nzJwQw99DNDKr9BVCOZcLuJJUlqkJh+kVzVl6Fmq/tI5ZtEyWT1KZMyOXltXLZJmDtvLCDgwsyrkohEtopTXCw==", + "dev": true + }, + "node_modules/@webassemblyjs/helper-numbers": { + "version": "1.11.6", + "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-numbers/-/helper-numbers-1.11.6.tgz", + "integrity": "sha512-vUIhZ8LZoIWHBohiEObxVm6hwP034jwmc9kuq5GdHZH0wiLVLIPcMCdpJzG4C11cHoQ25TFIQj9kaVADVX7N3g==", + "dev": true, + "dependencies": { + "@webassemblyjs/floating-point-hex-parser": "1.11.6", + "@webassemblyjs/helper-api-error": "1.11.6", + "@xtuc/long": "4.2.2" + } + }, + "node_modules/@webassemblyjs/helper-wasm-bytecode": { + "version": "1.11.6", + "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-bytecode/-/helper-wasm-bytecode-1.11.6.tgz", + "integrity": "sha512-sFFHKwcmBprO9e7Icf0+gddyWYDViL8bpPjJJl0WHxCdETktXdmtWLGVzoHbqUcY4Be1LkNfwTmXOJUFZYSJdA==", + "dev": true + }, + "node_modules/@webassemblyjs/helper-wasm-section": { + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-section/-/helper-wasm-section-1.12.1.tgz", + "integrity": "sha512-Jif4vfB6FJlUlSbgEMHUyk1j234GTNG9dBJ4XJdOySoj518Xj0oGsNi59cUQF4RRMS9ouBUxDDdyBVfPTypa5g==", + "dev": true, + "dependencies": { + "@webassemblyjs/ast": "1.12.1", + "@webassemblyjs/helper-buffer": "1.12.1", + "@webassemblyjs/helper-wasm-bytecode": "1.11.6", + "@webassemblyjs/wasm-gen": "1.12.1" + } + }, + "node_modules/@webassemblyjs/ieee754": { + "version": "1.11.6", + "resolved": "https://registry.npmjs.org/@webassemblyjs/ieee754/-/ieee754-1.11.6.tgz", + "integrity": "sha512-LM4p2csPNvbij6U1f19v6WR56QZ8JcHg3QIJTlSwzFcmx6WSORicYj6I63f9yU1kEUtrpG+kjkiIAkevHpDXrg==", + "dev": true, + "dependencies": { + "@xtuc/ieee754": "^1.2.0" + } + }, + "node_modules/@webassemblyjs/leb128": { + "version": "1.11.6", + "resolved": "https://registry.npmjs.org/@webassemblyjs/leb128/-/leb128-1.11.6.tgz", + "integrity": "sha512-m7a0FhE67DQXgouf1tbN5XQcdWoNgaAuoULHIfGFIEVKA6tu/edls6XnIlkmS6FrXAquJRPni3ZZKjw6FSPjPQ==", + "dev": true, + "dependencies": { + "@xtuc/long": "4.2.2" + } + }, + "node_modules/@webassemblyjs/utf8": { + "version": "1.11.6", + "resolved": "https://registry.npmjs.org/@webassemblyjs/utf8/-/utf8-1.11.6.tgz", + "integrity": "sha512-vtXf2wTQ3+up9Zsg8sa2yWiQpzSsMyXj0qViVP6xKGCUT8p8YJ6HqI7l5eCnWx1T/FYdsv07HQs2wTFbbof/RA==", + "dev": true + }, + "node_modules/@webassemblyjs/wasm-edit": { + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-edit/-/wasm-edit-1.12.1.tgz", + "integrity": "sha512-1DuwbVvADvS5mGnXbE+c9NfA8QRcZ6iKquqjjmR10k6o+zzsRVesil54DKexiowcFCPdr/Q0qaMgB01+SQ1u6g==", + "dev": true, + "dependencies": { + "@webassemblyjs/ast": "1.12.1", + "@webassemblyjs/helper-buffer": "1.12.1", + "@webassemblyjs/helper-wasm-bytecode": "1.11.6", + "@webassemblyjs/helper-wasm-section": "1.12.1", + "@webassemblyjs/wasm-gen": "1.12.1", + "@webassemblyjs/wasm-opt": "1.12.1", + "@webassemblyjs/wasm-parser": "1.12.1", + "@webassemblyjs/wast-printer": "1.12.1" + } + }, + "node_modules/@webassemblyjs/wasm-gen": { + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-gen/-/wasm-gen-1.12.1.tgz", + "integrity": "sha512-TDq4Ojh9fcohAw6OIMXqiIcTq5KUXTGRkVxbSo1hQnSy6lAM5GSdfwWeSxpAo0YzgsgF182E/U0mDNhuA0tW7w==", + "dev": true, + "dependencies": { + "@webassemblyjs/ast": "1.12.1", + "@webassemblyjs/helper-wasm-bytecode": "1.11.6", + "@webassemblyjs/ieee754": "1.11.6", + "@webassemblyjs/leb128": "1.11.6", + "@webassemblyjs/utf8": "1.11.6" + } + }, + "node_modules/@webassemblyjs/wasm-opt": { + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-opt/-/wasm-opt-1.12.1.tgz", + "integrity": "sha512-Jg99j/2gG2iaz3hijw857AVYekZe2SAskcqlWIZXjji5WStnOpVoat3gQfT/Q5tb2djnCjBtMocY/Su1GfxPBg==", + "dev": true, + "dependencies": { + "@webassemblyjs/ast": "1.12.1", + "@webassemblyjs/helper-buffer": "1.12.1", + "@webassemblyjs/wasm-gen": "1.12.1", + "@webassemblyjs/wasm-parser": "1.12.1" + } + }, + "node_modules/@webassemblyjs/wasm-parser": { + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-parser/-/wasm-parser-1.12.1.tgz", + "integrity": "sha512-xikIi7c2FHXysxXe3COrVUPSheuBtpcfhbpFj4gmu7KRLYOzANztwUU0IbsqvMqzuNK2+glRGWCEqZo1WCLyAQ==", + "dev": true, + "dependencies": { + "@webassemblyjs/ast": "1.12.1", + "@webassemblyjs/helper-api-error": "1.11.6", + "@webassemblyjs/helper-wasm-bytecode": "1.11.6", + "@webassemblyjs/ieee754": "1.11.6", + "@webassemblyjs/leb128": "1.11.6", + "@webassemblyjs/utf8": "1.11.6" + } + }, + "node_modules/@webassemblyjs/wast-printer": { + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/wast-printer/-/wast-printer-1.12.1.tgz", + "integrity": "sha512-+X4WAlOisVWQMikjbcvY2e0rwPsKQ9F688lksZhBcPycBBuii3O7m8FACbDMWDojpAqvjIncrG8J0XHKyQfVeA==", + "dev": true, + "dependencies": { + "@webassemblyjs/ast": "1.12.1", + "@xtuc/long": "4.2.2" + } + }, + "node_modules/@webpack-cli/configtest": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/@webpack-cli/configtest/-/configtest-1.2.0.tgz", + "integrity": "sha512-4FB8Tj6xyVkyqjj1OaTqCjXYULB9FMkqQ8yGrZjRDrYh0nOE+7Lhs45WioWQQMV+ceFlE368Ukhe6xdvJM9Egg==", + "dev": true, + "peerDependencies": { + "webpack": "4.x.x || 5.x.x", + "webpack-cli": "4.x.x" + } + }, + "node_modules/@webpack-cli/info": { + "version": "1.5.0", + "resolved": "https://registry.npmjs.org/@webpack-cli/info/-/info-1.5.0.tgz", + "integrity": "sha512-e8tSXZpw2hPl2uMJY6fsMswaok5FdlGNRTktvFk2sD8RjH0hE2+XistawJx1vmKteh4NmGmNUrp+Tb2w+udPcQ==", + "dev": true, + "dependencies": { + "envinfo": "^7.7.3" + }, + "peerDependencies": { + "webpack-cli": "4.x.x" + } + }, + "node_modules/@webpack-cli/serve": { + "version": "1.7.0", + "resolved": "https://registry.npmjs.org/@webpack-cli/serve/-/serve-1.7.0.tgz", + "integrity": "sha512-oxnCNGj88fL+xzV+dacXs44HcDwf1ovs3AuEzvP7mqXw7fQntqIhQ1BRmynh4qEKQSSSRSWVyXRjmTbZIX9V2Q==", + "dev": true, + "peerDependencies": { + "webpack-cli": "4.x.x" + }, + "peerDependenciesMeta": { + "webpack-dev-server": { + "optional": true + } + } + }, + "node_modules/@xtuc/ieee754": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/@xtuc/ieee754/-/ieee754-1.2.0.tgz", + "integrity": "sha512-DX8nKgqcGwsc0eJSqYt5lwP4DH5FlHnmuWWBRy7X0NcaGR0ZtuyeESgMwTYVEtxmsNGY+qit4QYT/MIYTOTPeA==", + "dev": true + }, + "node_modules/@xtuc/long": { + "version": "4.2.2", + "resolved": "https://registry.npmjs.org/@xtuc/long/-/long-4.2.2.tgz", + "integrity": "sha512-NuHqBY1PB/D8xU6s/thBgOAiAP7HOYDQ32+BFZILJ8ivkUkAHQnWfn6WhL79Owj1qmUnoN/YPhktdIoucipkAQ==", + "dev": true + }, + "node_modules/accepts": { + "version": "1.3.8", + "resolved": "https://registry.npmjs.org/accepts/-/accepts-1.3.8.tgz", + "integrity": "sha512-PYAthTa2m2VKxuvSD3DPC/Gy+U+sOA1LAuT8mkmRuvw+NACSaeXEQ+NHcVF7rONl6qcaxV3Uuemwawk+7+SJLw==", + "dev": true, + "dependencies": { + "mime-types": "~2.1.34", + "negotiator": "0.6.3" + }, + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/acorn": { + "version": "8.12.0", + "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.12.0.tgz", + "integrity": "sha512-RTvkC4w+KNXrM39/lWCUaG0IbRkWdCv7W/IOW9oU6SawyxulvkQy5HQPVTKxEjczcUvapcrw3cFx/60VN/NRNw==", + "dev": true, + "bin": { + "acorn": "bin/acorn" + }, + "engines": { + "node": ">=0.4.0" + } + }, + "node_modules/acorn-import-attributes": { + "version": "1.9.5", + "resolved": "https://registry.npmjs.org/acorn-import-attributes/-/acorn-import-attributes-1.9.5.tgz", + "integrity": "sha512-n02Vykv5uA3eHGM/Z2dQrcD56kL8TyDb2p1+0P83PClMnC/nc+anbQRhIOWnSq4Ke/KvDPrY3C9hDtC/A3eHnQ==", + "dev": true, + "peerDependencies": { + "acorn": "^8" + } + }, + "node_modules/adjust-sourcemap-loader": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/adjust-sourcemap-loader/-/adjust-sourcemap-loader-3.0.0.tgz", + "integrity": "sha512-YBrGyT2/uVQ/c6Rr+t6ZJXniY03YtHGMJQYal368burRGYKqhx9qGTWqcBU5s1CwYY9E/ri63RYyG1IacMZtqw==", + "dev": true, + "dependencies": { + "loader-utils": "^2.0.0", + "regex-parser": "^2.2.11" + }, + "engines": { + "node": ">=8.9" + } + }, + "node_modules/adjust-sourcemap-loader/node_modules/loader-utils": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/loader-utils/-/loader-utils-2.0.4.tgz", + "integrity": "sha512-xXqpXoINfFhgua9xiqD8fPFHgkoq1mmmpE92WlDbm9rNRd/EbRb+Gqf908T2DMfuHjjJlksiK2RbHVOdD/MqSw==", + "dev": true, + "dependencies": { + "big.js": "^5.2.2", + "emojis-list": "^3.0.0", + "json5": "^2.1.2" + }, + "engines": { + "node": ">=8.9.0" + } + }, + "node_modules/ajv": { + "version": "6.12.6", + "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.12.6.tgz", + "integrity": "sha512-j3fVLgvTo527anyYyJOGTYJbG+vnnQYvE0m5mmkc1TK+nxAppkCLMIL0aZ4dblVCNoGShhm+kzE4ZUykBoMg4g==", + "dev": true, + "dependencies": { + "fast-deep-equal": "^3.1.1", + "fast-json-stable-stringify": "^2.0.0", + "json-schema-traverse": "^0.4.1", + "uri-js": "^4.2.2" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/epoberezkin" + } + }, + "node_modules/ajv-formats": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/ajv-formats/-/ajv-formats-2.1.1.tgz", + "integrity": "sha512-Wx0Kx52hxE7C18hkMEggYlEifqWZtYaRgouJor+WMdPnQyEK13vgEWyVNup7SoeeoLMsr4kf5h6dOW11I15MUA==", + "dev": true, + "dependencies": { + "ajv": "^8.0.0" + }, + "peerDependencies": { + "ajv": "^8.0.0" + }, + "peerDependenciesMeta": { + "ajv": { + "optional": true + } + } + }, + "node_modules/ajv-formats/node_modules/ajv": { + "version": "8.16.0", + "resolved": "https://registry.npmjs.org/ajv/-/ajv-8.16.0.tgz", + "integrity": "sha512-F0twR8U1ZU67JIEtekUcLkXkoO5mMMmgGD8sK/xUFzJ805jxHQl92hImFAqqXMyMYjSPOyUPAwHYhB72g5sTXw==", + "dev": true, + "dependencies": { + "fast-deep-equal": "^3.1.3", + "json-schema-traverse": "^1.0.0", + "require-from-string": "^2.0.2", + "uri-js": "^4.4.1" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/epoberezkin" + } + }, + "node_modules/ajv-formats/node_modules/json-schema-traverse": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz", + "integrity": "sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==", + "dev": true + }, + "node_modules/ajv-keywords": { + "version": "3.5.2", + "resolved": "https://registry.npmjs.org/ajv-keywords/-/ajv-keywords-3.5.2.tgz", + "integrity": "sha512-5p6WTN0DdTGVQk6VjcEju19IgaHudalcfabD7yhDGeA6bcQnmL+CpveLJq/3hvfwd1aof6L386Ougkx6RfyMIQ==", + "dev": true, + "peerDependencies": { + "ajv": "^6.9.1" + } + }, + "node_modules/ansi-html-community": { + "version": "0.0.8", + "resolved": "https://registry.npmjs.org/ansi-html-community/-/ansi-html-community-0.0.8.tgz", + "integrity": "sha512-1APHAyr3+PCamwNw3bXCPp4HFLONZt/yIH0sZp0/469KWNTEy+qN5jQ3GVX6DMZ1UXAi34yVwtTeaG/HpBuuzw==", + "dev": true, + "engines": [ + "node >= 0.8.0" + ], + "bin": { + "ansi-html": "bin/ansi-html" + } + }, + "node_modules/ansi-regex": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", + "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/ansi-styles": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", + "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "dev": true, + "dependencies": { + "color-convert": "^1.9.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/anymatch": { + "version": "3.1.3", + "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.3.tgz", + "integrity": "sha512-KMReFUr0B4t+D+OBkjR3KYqvocp2XaSzO55UcB6mgQMd3KbcE+mWTyvVV7D/zsdEbNnV6acZUutkiHQXvTr1Rw==", + "dev": true, + "dependencies": { + "normalize-path": "^3.0.0", + "picomatch": "^2.0.4" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/arity-n": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/arity-n/-/arity-n-1.0.4.tgz", + "integrity": "sha1-2edrEXM+CFacCEeuezmyhgswt0U=", + "dev": true + }, + "node_modules/array-flatten": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/array-flatten/-/array-flatten-1.1.1.tgz", + "integrity": "sha512-PCVAQswWemu6UdxsDFFX/+gVeYqKAod3D3UVm91jHwynguOwAvYPhx8nNlM++NqRcK6CxxpUafjmhIdKiHibqg==", + "dev": true + }, + "node_modules/array-union": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/array-union/-/array-union-2.1.0.tgz", + "integrity": "sha512-HGyxoOTYUyCM6stUe6EJgnd4EoewAI7zMdfqO+kGjnlZmBDz/cR5pf8r/cR4Wq60sL/p0IkcjUEEPwS3GFrIyw==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/asn1.js": { + "version": "4.10.1", + "resolved": "https://registry.npmjs.org/asn1.js/-/asn1.js-4.10.1.tgz", + "integrity": "sha512-p32cOF5q0Zqs9uBiONKYLm6BClCoBCM5O9JfeUSlnQLBTxYdTK+pW+nXflm8UkKd2UYlEbYz5qEi0JuZR9ckSw==", + "dev": true, + "dependencies": { + "bn.js": "^4.0.0", + "inherits": "^2.0.1", + "minimalistic-assert": "^1.0.0" + } + }, + "node_modules/asn1.js/node_modules/bn.js": { + "version": "4.12.0", + "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-4.12.0.tgz", + "integrity": "sha512-c98Bf3tPniI+scsdk237ku1Dc3ujXQTSgyiPUDEOe7tRkhrqridvh8klBv0HCEso1OLOYcHuCv/cS6DNxKH+ZA==", + "dev": true + }, + "node_modules/assert": { + "version": "1.5.0", + "resolved": "https://registry.npmjs.org/assert/-/assert-1.5.0.tgz", + "integrity": "sha512-EDsgawzwoun2CZkCgtxJbv392v4nbk9XDD06zI+kQYoBM/3RBWLlEyJARDOmhAAosBjWACEkKL6S+lIZtcAubA==", + "dev": true, + "dependencies": { + "object-assign": "^4.1.1", + "util": "0.10.3" + } + }, + "node_modules/assert/node_modules/inherits": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.1.tgz", + "integrity": "sha1-sX0I0ya0Qj5Wjv9xn5GwscvfafE=", + "dev": true + }, + "node_modules/assert/node_modules/util": { + "version": "0.10.3", + "resolved": "https://registry.npmjs.org/util/-/util-0.10.3.tgz", + "integrity": "sha1-evsa/lCAUkZInj23/g7TeTNqwPk=", + "dev": true, + "dependencies": { + "inherits": "2.0.1" + } + }, + "node_modules/asynckit": { + "version": "0.4.0", + "resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz", + "integrity": "sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q==", + "dev": true + }, + "node_modules/atob": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/atob/-/atob-2.1.2.tgz", + "integrity": "sha512-Wm6ukoaOGJi/73p/cl2GvLjTI5JM1k/O14isD73YML8StrH/7/lRFgmg8nICZgD3bZZvjwCGxtMOD3wWNAu8cg==", + "dev": true, + "bin": { + "atob": "bin/atob.js" + }, + "engines": { + "node": ">= 4.5.0" + } + }, + "node_modules/autoprefixer": { + "version": "10.4.19", + "resolved": "https://registry.npmjs.org/autoprefixer/-/autoprefixer-10.4.19.tgz", + "integrity": "sha512-BaENR2+zBZ8xXhM4pUaKUxlVdxZ0EZhjvbopwnXmxRUfqDmwSpC2lAi/QXvx7NRdPCo1WKEcEF6mV64si1z4Ew==", + "dev": true, + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/autoprefixer" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "dependencies": { + "browserslist": "^4.23.0", + "caniuse-lite": "^1.0.30001599", + "fraction.js": "^4.3.7", + "normalize-range": "^0.1.2", + "picocolors": "^1.0.0", + "postcss-value-parser": "^4.2.0" + }, + "bin": { + "autoprefixer": "bin/autoprefixer" + }, + "engines": { + "node": "^10 || ^12 || >=14" + }, + "peerDependencies": { + "postcss": "^8.1.0" + } + }, + "node_modules/axios": { + "version": "1.7.2", + "resolved": "https://registry.npmjs.org/axios/-/axios-1.7.2.tgz", + "integrity": "sha512-2A8QhOMrbomlDuiLeK9XibIBzuHeRcqqNOHp0Cyp5EoJ1IFDh+XZH3A6BkXtv0K4gFGCI0Y4BM7B1wOEi0Rmgw==", + "dev": true, + "dependencies": { + "follow-redirects": "^1.15.6", + "form-data": "^4.0.0", + "proxy-from-env": "^1.1.0" + } + }, + "node_modules/babel-loader": { + "version": "8.2.3", + "resolved": "https://registry.npmjs.org/babel-loader/-/babel-loader-8.2.3.tgz", + "integrity": "sha512-n4Zeta8NC3QAsuyiizu0GkmRcQ6clkV9WFUnUf1iXP//IeSKbWjofW3UHyZVwlOB4y039YQKefawyTn64Zwbuw==", + "dev": true, + "dependencies": { + "find-cache-dir": "^3.3.1", + "loader-utils": "^1.4.0", + "make-dir": "^3.1.0", + "schema-utils": "^2.6.5" + }, + "engines": { + "node": ">= 8.9" + }, + "peerDependencies": { + "@babel/core": "^7.0.0", + "webpack": ">=2" + } + }, + "node_modules/babel-plugin-dynamic-import-node": { + "version": "2.3.3", + "resolved": "https://registry.npmjs.org/babel-plugin-dynamic-import-node/-/babel-plugin-dynamic-import-node-2.3.3.tgz", + "integrity": "sha512-jZVI+s9Zg3IqA/kdi0i6UDCybUI3aSBLnglhYbSSjKlV7yF1F/5LWv8MakQmvYpnbJDS6fcBL2KzHSxNCMtWSQ==", + "dev": true, + "dependencies": { + "object.assign": "^4.1.0" + } + }, + "node_modules/babel-plugin-polyfill-corejs2": { + "version": "0.3.1", + "resolved": "https://registry.npmjs.org/babel-plugin-polyfill-corejs2/-/babel-plugin-polyfill-corejs2-0.3.1.tgz", + "integrity": "sha512-v7/T6EQcNfVLfcN2X8Lulb7DjprieyLWJK/zOWH5DUYcAgex9sP3h25Q+DLsX9TloXe3y1O8l2q2Jv9q8UVB9w==", + "dev": true, + "dependencies": { + "@babel/compat-data": "^7.13.11", + "@babel/helper-define-polyfill-provider": "^0.3.1", + "semver": "^6.1.1" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/babel-plugin-polyfill-corejs3": { + "version": "0.5.2", + "resolved": "https://registry.npmjs.org/babel-plugin-polyfill-corejs3/-/babel-plugin-polyfill-corejs3-0.5.2.tgz", + "integrity": "sha512-G3uJih0XWiID451fpeFaYGVuxHEjzKTHtc9uGFEjR6hHrvNzeS/PX+LLLcetJcytsB5m4j+K3o/EpXJNb/5IEQ==", + "dev": true, + "dependencies": { + "@babel/helper-define-polyfill-provider": "^0.3.1", + "core-js-compat": "^3.21.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/babel-plugin-polyfill-regenerator": { + "version": "0.3.1", + "resolved": "https://registry.npmjs.org/babel-plugin-polyfill-regenerator/-/babel-plugin-polyfill-regenerator-0.3.1.tgz", + "integrity": "sha512-Y2B06tvgHYt1x0yz17jGkGeeMr5FeKUu+ASJ+N6nB5lQ8Dapfg42i0OVrf8PNGJ3zKL4A23snMi1IRwrqqND7A==", + "dev": true, + "dependencies": { + "@babel/helper-define-polyfill-provider": "^0.3.1" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/balanced-match": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz", + "integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==", + "dev": true + }, + "node_modules/base64-js": { + "version": "1.5.1", + "resolved": "https://registry.npmjs.org/base64-js/-/base64-js-1.5.1.tgz", + "integrity": "sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ] + }, + "node_modules/batch": { + "version": "0.6.1", + "resolved": "https://registry.npmjs.org/batch/-/batch-0.6.1.tgz", + "integrity": "sha512-x+VAiMRL6UPkx+kudNvxTl6hB2XNNCG2r+7wixVfIYwu/2HKRXimwQyaumLjMveWvT2Hkd/cAJw+QBMfJ/EKVw==", + "dev": true + }, + "node_modules/big.js": { + "version": "5.2.2", + "resolved": "https://registry.npmjs.org/big.js/-/big.js-5.2.2.tgz", + "integrity": "sha512-vyL2OymJxmarO8gxMr0mhChsO9QGwhynfuu4+MHTAW6czfq9humCB7rKpUjDd9YUiDPU4mzpyupFSvOClAwbmQ==", + "dev": true, + "engines": { + "node": "*" + } + }, + "node_modules/binary-extensions": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.3.0.tgz", + "integrity": "sha512-Ceh+7ox5qe7LJuLHoY0feh3pHuUDHAcRUeyL2VYghZwfpkNIy/+8Ocg0a3UuSoYzavmylwuLWQOf3hl0jjMMIw==", + "dev": true, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/bn.js": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-5.2.1.tgz", + "integrity": "sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ==", + "dev": true + }, + "node_modules/body-parser": { + "version": "1.20.2", + "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.2.tgz", + "integrity": "sha512-ml9pReCu3M61kGlqoTm2umSXTlRTuGTx0bfYj+uIUKKYycG5NtSbeetV3faSU6R7ajOPw0g/J1PvK4qNy7s5bA==", + "dev": true, + "dependencies": { + "bytes": "3.1.2", + "content-type": "~1.0.5", + "debug": "2.6.9", + "depd": "2.0.0", + "destroy": "1.2.0", + "http-errors": "2.0.0", + "iconv-lite": "0.4.24", + "on-finished": "2.4.1", + "qs": "6.11.0", + "raw-body": "2.5.2", + "type-is": "~1.6.18", + "unpipe": "1.0.0" + }, + "engines": { + "node": ">= 0.8", + "npm": "1.2.8000 || >= 1.4.16" + } + }, + "node_modules/body-parser/node_modules/bytes": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/bytes/-/bytes-3.1.2.tgz", + "integrity": "sha512-/Nf7TyzTx6S3yRJObOAV7956r8cr2+Oj8AC5dt8wSP3BQAoeX58NoHyCU8P8zGkNXStjTSi6fzO6F0pBdcYbEg==", + "dev": true, + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/bonjour-service": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/bonjour-service/-/bonjour-service-1.2.1.tgz", + "integrity": "sha512-oSzCS2zV14bh2kji6vNe7vrpJYCHGvcZnlffFQ1MEoX/WOeQ/teD8SYWKR942OI3INjq8OMNJlbPK5LLLUxFDw==", + "dev": true, + "dependencies": { + "fast-deep-equal": "^3.1.3", + "multicast-dns": "^7.2.5" + } + }, + "node_modules/boolbase": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/boolbase/-/boolbase-1.0.0.tgz", + "integrity": "sha512-JZOSA7Mo9sNGB8+UjSgzdLtokWAky1zbztM3WRLCbZ70/3cTANmQmOdR7y2g+J0e2WXywy1yS468tY+IruqEww==", + "dev": true + }, + "node_modules/bootstrap": { + "version": "4.6.1", + "resolved": "https://registry.npmjs.org/bootstrap/-/bootstrap-4.6.1.tgz", + "integrity": "sha512-0dj+VgI9Ecom+rvvpNZ4MUZJz8dcX7WCX+eTID9+/8HgOkv3dsRzi8BGeZJCQU6flWQVYxwTQnEZFrmJSEO7og==", + "dev": true, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/bootstrap" + }, + "peerDependencies": { + "jquery": "1.9.1 - 3", + "popper.js": "^1.16.1" + } + }, + "node_modules/brace-expansion": { + "version": "1.1.11", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", + "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", + "dev": true, + "dependencies": { + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" + } + }, + "node_modules/braces": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.3.tgz", + "integrity": "sha512-yQbXgO/OSZVD2IsiLlro+7Hf6Q18EJrKSEsdoMzKePKXct3gvD8oLcOQdIzGupr5Fj+EDe8gO/lxc1BzfMpxvA==", + "dev": true, + "dependencies": { + "fill-range": "^7.1.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/brorand": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/brorand/-/brorand-1.1.0.tgz", + "integrity": "sha1-EsJe/kCkXjwyPrhnWgoM5XsiNx8=", + "dev": true + }, + "node_modules/browserify-aes": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/browserify-aes/-/browserify-aes-1.2.0.tgz", + "integrity": "sha512-+7CHXqGuspUn/Sl5aO7Ea0xWGAtETPXNSAjHo48JfLdPWcMng33Xe4znFvQweqc/uzk5zSOI3H52CYnjCfb5hA==", + "dev": true, + "dependencies": { + "buffer-xor": "^1.0.3", + "cipher-base": "^1.0.0", + "create-hash": "^1.1.0", + "evp_bytestokey": "^1.0.3", + "inherits": "^2.0.1", + "safe-buffer": "^5.0.1" + } + }, + "node_modules/browserify-cipher": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/browserify-cipher/-/browserify-cipher-1.0.1.tgz", + "integrity": "sha512-sPhkz0ARKbf4rRQt2hTpAHqn47X3llLkUGn+xEJzLjwY8LRs2p0v7ljvI5EyoRO/mexrNunNECisZs+gw2zz1w==", + "dev": true, + "dependencies": { + "browserify-aes": "^1.0.4", + "browserify-des": "^1.0.0", + "evp_bytestokey": "^1.0.0" + } + }, + "node_modules/browserify-des": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/browserify-des/-/browserify-des-1.0.2.tgz", + "integrity": "sha512-BioO1xf3hFwz4kc6iBhI3ieDFompMhrMlnDFC4/0/vd5MokpuAc3R+LYbwTA9A5Yc9pq9UYPqffKpW2ObuwX5A==", + "dev": true, + "dependencies": { + "cipher-base": "^1.0.1", + "des.js": "^1.0.0", + "inherits": "^2.0.1", + "safe-buffer": "^5.1.2" + } + }, + "node_modules/browserify-rsa": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/browserify-rsa/-/browserify-rsa-4.1.0.tgz", + "integrity": "sha512-AdEER0Hkspgno2aR97SAf6vi0y0k8NuOpGnVH3O99rcA5Q6sh8QxcngtHuJ6uXwnfAXNM4Gn1Gb7/MV1+Ymbog==", + "dev": true, + "dependencies": { + "bn.js": "^5.0.0", + "randombytes": "^2.0.1" + } + }, + "node_modules/browserify-sign": { + "version": "4.2.3", + "resolved": "https://registry.npmjs.org/browserify-sign/-/browserify-sign-4.2.3.tgz", + "integrity": "sha512-JWCZW6SKhfhjJxO8Tyiiy+XYB7cqd2S5/+WeYHsKdNKFlCBhKbblba1A/HN/90YwtxKc8tCErjffZl++UNmGiw==", + "dev": true, + "dependencies": { + "bn.js": "^5.2.1", + "browserify-rsa": "^4.1.0", + "create-hash": "^1.2.0", + "create-hmac": "^1.1.7", + "elliptic": "^6.5.5", + "hash-base": "~3.0", + "inherits": "^2.0.4", + "parse-asn1": "^5.1.7", + "readable-stream": "^2.3.8", + "safe-buffer": "^5.2.1" + }, + "engines": { + "node": ">= 0.12" + } + }, + "node_modules/browserify-sign/node_modules/hash-base": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/hash-base/-/hash-base-3.0.4.tgz", + "integrity": "sha512-EeeoJKjTyt868liAlVmcv2ZsUfGHlE3Q+BICOXcZiwN3osr5Q/zFGYmTJpoIzuaSTAwndFy+GqhEwlU4L3j4Ow==", + "dev": true, + "dependencies": { + "inherits": "^2.0.1", + "safe-buffer": "^5.0.1" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/browserify-sign/node_modules/safe-buffer": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", + "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ] + }, + "node_modules/browserify-zlib": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/browserify-zlib/-/browserify-zlib-0.2.0.tgz", + "integrity": "sha512-Z942RysHXmJrhqk88FmKBVq/v5tqmSkDz7p54G/MGyjMnCFFnC79XWNbg+Vta8W6Wb2qtSZTSxIGkJrRpCFEiA==", + "dev": true, + "dependencies": { + "pako": "~1.0.5" + } + }, + "node_modules/browserslist": { + "version": "4.23.1", + "resolved": "https://registry.npmjs.org/browserslist/-/browserslist-4.23.1.tgz", + "integrity": "sha512-TUfofFo/KsK/bWZ9TWQ5O26tsWW4Uhmt8IYklbnUa70udB6P2wA7w7o4PY4muaEPBQaAX+CEnmmIA41NVHtPVw==", + "dev": true, + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/browserslist" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/browserslist" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "dependencies": { + "caniuse-lite": "^1.0.30001629", + "electron-to-chromium": "^1.4.796", + "node-releases": "^2.0.14", + "update-browserslist-db": "^1.0.16" + }, + "bin": { + "browserslist": "cli.js" + }, + "engines": { + "node": "^6 || ^7 || ^8 || ^9 || ^10 || ^11 || ^12 || >=13.7" + } + }, + "node_modules/buffer": { + "version": "4.9.2", + "resolved": "https://registry.npmjs.org/buffer/-/buffer-4.9.2.tgz", + "integrity": "sha512-xq+q3SRMOxGivLhBNaUdC64hDTQwejJ+H0T/NB1XMtTVEwNTrfFF3gAxiyW0Bu/xWEGhjVKgUcMhCrUy2+uCWg==", + "dev": true, + "dependencies": { + "base64-js": "^1.0.2", + "ieee754": "^1.1.4", + "isarray": "^1.0.0" + } + }, + "node_modules/buffer-from": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.2.tgz", + "integrity": "sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ==", + "dev": true + }, + "node_modules/buffer-xor": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/buffer-xor/-/buffer-xor-1.0.3.tgz", + "integrity": "sha1-JuYe0UIvtw3ULm42cp7VHYVf6Nk=", + "dev": true + }, + "node_modules/builtin-status-codes": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/builtin-status-codes/-/builtin-status-codes-3.0.0.tgz", + "integrity": "sha1-hZgoeOIbmOHGZCXgPQF0eI9Wnug=", + "dev": true + }, + "node_modules/bytes": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/bytes/-/bytes-3.0.0.tgz", + "integrity": "sha512-pMhOfFDPiv9t5jjIXkHosWmkSyQbvsgEVNkz0ERHbuLh2T/7j4Mqqpz523Fe8MVY89KC6Sh/QfS2sM+SjgFDcw==", + "dev": true, + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/call-bind": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.7.tgz", + "integrity": "sha512-GHTSNSYICQ7scH7sZ+M2rFopRoLh8t2bLSW6BbgrtLsahOIB5iyAVJf9GjWK3cYTDaMj4XdBpM1cA6pIS0Kv2w==", + "dev": true, + "dependencies": { + "es-define-property": "^1.0.0", + "es-errors": "^1.3.0", + "function-bind": "^1.1.2", + "get-intrinsic": "^1.2.4", + "set-function-length": "^1.2.1" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/callsites": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/callsites/-/callsites-3.1.0.tgz", + "integrity": "sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/camel-case": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/camel-case/-/camel-case-4.1.2.tgz", + "integrity": "sha512-gxGWBrTT1JuMx6R+o5PTXMmUnhnVzLQ9SNutD4YqKtI6ap897t3tKECYla6gCWEkplXnlNybEkZg9GEGxKFCgw==", + "dev": true, + "dependencies": { + "pascal-case": "^3.1.2", + "tslib": "^2.0.3" + } + }, + "node_modules/camelcase": { + "version": "5.3.1", + "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-5.3.1.tgz", + "integrity": "sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/caniuse-api": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/caniuse-api/-/caniuse-api-3.0.0.tgz", + "integrity": "sha512-bsTwuIg/BZZK/vreVTYYbSWoe2F+71P7K5QGEX+pT250DZbfU1MQ5prOKpPR+LL6uWKK3KMwMCAS74QB3Um1uw==", + "dev": true, + "dependencies": { + "browserslist": "^4.0.0", + "caniuse-lite": "^1.0.0", + "lodash.memoize": "^4.1.2", + "lodash.uniq": "^4.5.0" + } + }, + "node_modules/caniuse-lite": { + "version": "1.0.30001636", + "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001636.tgz", + "integrity": "sha512-bMg2vmr8XBsbL6Lr0UHXy/21m84FTxDLWn2FSqMd5PrlbMxwJlQnC2YWYxVgp66PZE+BBNF2jYQUBKCo1FDeZg==", + "dev": true, + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/browserslist" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/caniuse-lite" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ] + }, + "node_modules/chalk": { + "version": "2.4.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz", + "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", + "dev": true, + "dependencies": { + "ansi-styles": "^3.2.1", + "escape-string-regexp": "^1.0.5", + "supports-color": "^5.3.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/charenc": { + "version": "0.0.2", + "resolved": "https://registry.npmjs.org/charenc/-/charenc-0.0.2.tgz", + "integrity": "sha1-wKHS86cJLgN3S/qD8UwPxXkKhmc=", + "dev": true, + "engines": { + "node": "*" + } + }, + "node_modules/chokidar": { + "version": "3.6.0", + "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.6.0.tgz", + "integrity": "sha512-7VT13fmjotKpGipCW9JEQAusEPE+Ei8nl6/g4FBAmIm0GOOLMua9NDDo/DWp0ZAxCr3cPq5ZpBqmPAQgDda2Pw==", + "dev": true, + "dependencies": { + "anymatch": "~3.1.2", + "braces": "~3.0.2", + "glob-parent": "~5.1.2", + "is-binary-path": "~2.1.0", + "is-glob": "~4.0.1", + "normalize-path": "~3.0.0", + "readdirp": "~3.6.0" + }, + "engines": { + "node": ">= 8.10.0" + }, + "funding": { + "url": "https://paulmillr.com/funding/" + }, + "optionalDependencies": { + "fsevents": "~2.3.2" + } + }, + "node_modules/chrome-trace-event": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/chrome-trace-event/-/chrome-trace-event-1.0.3.tgz", + "integrity": "sha512-p3KULyQg4S7NIHixdwbGX+nFHkoBiA4YQmyWtjb8XngSKV124nJmRysgAeujbUVb15vh+RvFUfCPqU7rXk+hZg==", + "dev": true, + "engines": { + "node": ">=6.0" + } + }, + "node_modules/cipher-base": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/cipher-base/-/cipher-base-1.0.4.tgz", + "integrity": "sha512-Kkht5ye6ZGmwv40uUDZztayT2ThLQGfnj/T71N/XzeZeo3nf8foyW7zGTsPYkEya3m5f3cAypH+qe7YOrM1U2Q==", + "dev": true, + "dependencies": { + "inherits": "^2.0.1", + "safe-buffer": "^5.0.1" + } + }, + "node_modules/clean-css": { + "version": "5.3.3", + "resolved": "https://registry.npmjs.org/clean-css/-/clean-css-5.3.3.tgz", + "integrity": "sha512-D5J+kHaVb/wKSFcyyV75uCn8fiY4sV38XJoe4CUyGQ+mOU/fMVYUdH1hJC+CJQ5uY3EnW27SbJYS4X8BiLrAFg==", + "dev": true, + "dependencies": { + "source-map": "~0.6.0" + }, + "engines": { + "node": ">= 10.0" + } + }, + "node_modules/cli-table3": { + "version": "0.6.5", + "resolved": "https://registry.npmjs.org/cli-table3/-/cli-table3-0.6.5.tgz", + "integrity": "sha512-+W/5efTR7y5HRD7gACw9yQjqMVvEMLBHmboM/kPWam+H+Hmyrgjh6YncVKK122YZkXrLudzTuAukUw9FnMf7IQ==", + "dev": true, + "dependencies": { + "string-width": "^4.2.0" + }, + "engines": { + "node": "10.* || >= 12.*" + }, + "optionalDependencies": { + "@colors/colors": "1.5.0" + } + }, + "node_modules/cliui": { + "version": "8.0.1", + "resolved": "https://registry.npmjs.org/cliui/-/cliui-8.0.1.tgz", + "integrity": "sha512-BSeNnyus75C4//NQ9gQt1/csTXyo/8Sb+afLAkzAptFuMsod9HFokGNudZpi/oQV73hnVK+sR+5PVRMd+Dr7YQ==", + "dev": true, + "dependencies": { + "string-width": "^4.2.0", + "strip-ansi": "^6.0.1", + "wrap-ansi": "^7.0.0" + }, + "engines": { + "node": ">=12" + } + }, + "node_modules/clone-deep": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/clone-deep/-/clone-deep-4.0.1.tgz", + "integrity": "sha512-neHB9xuzh/wk0dIHweyAXv2aPGZIVk3pLMe+/RNzINf17fe0OG96QroktYAUm7SM1PBnzTabaLboqqxDyMU+SQ==", + "dev": true, + "dependencies": { + "is-plain-object": "^2.0.4", + "kind-of": "^6.0.2", + "shallow-clone": "^3.0.0" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/clone-deep/node_modules/kind-of": { + "version": "6.0.3", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-6.0.3.tgz", + "integrity": "sha512-dcS1ul+9tmeD95T+x28/ehLgd9mENa3LsvDTtzm3vyBEO7RPptvAD+t44WVXaUjTBRcrpFeFlC8WCruUR456hw==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/collect.js": { + "version": "4.31.3", + "resolved": "https://registry.npmjs.org/collect.js/-/collect.js-4.31.3.tgz", + "integrity": "sha512-pHXhGzo5qftTTlEj88MCRXN8YuhARhmEnCOmc7wzBlI+5fVVC5VZ9Z/Z5KEDuM90Fgwv025Fc2Gk4VpFKMrzQA==", + "dev": true + }, + "node_modules/color-convert": { + "version": "1.9.3", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", + "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==", + "dev": true, + "dependencies": { + "color-name": "1.1.3" + } + }, + "node_modules/color-name": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", + "integrity": "sha1-p9BVi9icQveV3UIyj3QIMcpTvCU=", + "dev": true + }, + "node_modules/colord": { + "version": "2.9.3", + "resolved": "https://registry.npmjs.org/colord/-/colord-2.9.3.tgz", + "integrity": "sha512-jeC1axXpnb0/2nn/Y1LPuLdgXBLH7aDcHu4KEKfqw3CUhX7ZpfBSlPKyqXE6btIgEzfWtrX3/tyBCaCvXvMkOw==", + "dev": true + }, + "node_modules/colorette": { + "version": "2.0.20", + "resolved": "https://registry.npmjs.org/colorette/-/colorette-2.0.20.tgz", + "integrity": "sha512-IfEDxwoWIjkeXL1eXcDiow4UbKjhLdq6/EuSVR9GMN7KVH3r9gQ83e73hsz1Nd1T3ijd5xv1wcWRYO+D6kCI2w==", + "dev": true + }, + "node_modules/combined-stream": { + "version": "1.0.8", + "resolved": "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz", + "integrity": "sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==", + "dev": true, + "dependencies": { + "delayed-stream": "~1.0.0" + }, + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/commander": { + "version": "2.20.3", + "resolved": "https://registry.npmjs.org/commander/-/commander-2.20.3.tgz", + "integrity": "sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ==", + "dev": true + }, + "node_modules/commondir": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/commondir/-/commondir-1.0.1.tgz", + "integrity": "sha1-3dgA2gxmEnOTzKWVDqloo6rxJTs=", + "dev": true + }, + "node_modules/compose-function": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/compose-function/-/compose-function-3.0.3.tgz", + "integrity": "sha1-ntZ18TzFRQHTCVCkhv9qe6OrGF8=", + "dev": true, + "dependencies": { + "arity-n": "^1.0.4" + } + }, + "node_modules/compressible": { + "version": "2.0.18", + "resolved": "https://registry.npmjs.org/compressible/-/compressible-2.0.18.tgz", + "integrity": "sha512-AF3r7P5dWxL8MxyITRMlORQNaOA2IkAFaTr4k7BUumjPtRpGDTZpl0Pb1XCO6JeDCBdp126Cgs9sMxqSjgYyRg==", + "dev": true, + "dependencies": { + "mime-db": ">= 1.43.0 < 2" + }, + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/compression": { + "version": "1.7.4", + "resolved": "https://registry.npmjs.org/compression/-/compression-1.7.4.tgz", + "integrity": "sha512-jaSIDzP9pZVS4ZfQ+TzvtiWhdpFhE2RDHz8QJkpX9SIpLq88VueF5jJw6t+6CUQcAoA6t+x89MLrWAqpfDE8iQ==", + "dev": true, + "dependencies": { + "accepts": "~1.3.5", + "bytes": "3.0.0", + "compressible": "~2.0.16", + "debug": "2.6.9", + "on-headers": "~1.0.2", + "safe-buffer": "5.1.2", + "vary": "~1.1.2" + }, + "engines": { + "node": ">= 0.8.0" + } + }, + "node_modules/concat": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/concat/-/concat-1.0.3.tgz", + "integrity": "sha1-QPM1MInWVGdpXLGIa0Xt1jfYzKg=", + "dev": true, + "dependencies": { + "commander": "^2.9.0" + }, + "bin": { + "concat": "bin/concat" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/concat-map": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", + "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=", + "dev": true + }, + "node_modules/connect-history-api-fallback": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/connect-history-api-fallback/-/connect-history-api-fallback-2.0.0.tgz", + "integrity": "sha512-U73+6lQFmfiNPrYbXqr6kZ1i1wiRqXnp2nhMsINseWXO8lDau0LGEffJ8kQi4EjLZympVgRdvqjAgiZ1tgzDDA==", + "dev": true, + "engines": { + "node": ">=0.8" + } + }, + "node_modules/consola": { + "version": "2.15.3", + "resolved": "https://registry.npmjs.org/consola/-/consola-2.15.3.tgz", + "integrity": "sha512-9vAdYbHj6x2fLKC4+oPH0kFzY/orMZyG2Aj+kNylHxKGJ/Ed4dpNyAQYwJOdqO4zdM7XpVHmyejQDcQHrnuXbw==", + "dev": true + }, + "node_modules/console-browserify": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/console-browserify/-/console-browserify-1.2.0.tgz", + "integrity": "sha512-ZMkYO/LkF17QvCPqM0gxw8yUzigAOZOSWSHg91FH6orS7vcEj5dVZTidN2fQ14yBSdg97RqhSNwLUXInd52OTA==", + "dev": true + }, + "node_modules/constants-browserify": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/constants-browserify/-/constants-browserify-1.0.0.tgz", + "integrity": "sha1-wguW2MYXdIqvHBYCF2DNJ/y4y3U=", + "dev": true + }, + "node_modules/content-disposition": { + "version": "0.5.4", + "resolved": "https://registry.npmjs.org/content-disposition/-/content-disposition-0.5.4.tgz", + "integrity": "sha512-FveZTNuGw04cxlAiWbzi6zTAL/lhehaWbTtgluJh4/E95DqMwTmha3KZN1aAWA8cFIhHzMZUvLevkw5Rqk+tSQ==", + "dev": true, + "dependencies": { + "safe-buffer": "5.2.1" + }, + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/content-disposition/node_modules/safe-buffer": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", + "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ] + }, + "node_modules/content-type": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/content-type/-/content-type-1.0.5.tgz", + "integrity": "sha512-nTjqfcBFEipKdXCv4YDQWCfmcLZKm81ldF0pAopTvyrFGVbcR6P/VAAd5G7N+0tTr8QqiU0tFadD6FK4NtJwOA==", + "dev": true, + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/convert-source-map": { + "version": "1.8.0", + "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-1.8.0.tgz", + "integrity": "sha512-+OQdjP49zViI/6i7nIJpA8rAl4sV/JdPfU9nZs3VqOwGIgizICvuN2ru6fMd+4llL0tar18UYJXfZ/TWtmhUjA==", + "dev": true, + "dependencies": { + "safe-buffer": "~5.1.1" + } + }, + "node_modules/cookie": { + "version": "0.6.0", + "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.6.0.tgz", + "integrity": "sha512-U71cyTamuh1CRNCfpGY6to28lxvNwPG4Guz/EVjgf3Jmzv0vlDp1atT9eS5dDjMYHucpHbWns6Lwf3BKz6svdw==", + "dev": true, + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/cookie-signature": { + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/cookie-signature/-/cookie-signature-1.0.6.tgz", + "integrity": "sha512-QADzlaHc8icV8I7vbaJXJwod9HWYp8uCqf1xa4OfNu1T7JVxQIrUgOWtHdNDtPiywmFbiS12VjotIXLrKM3orQ==", + "dev": true + }, + "node_modules/core-js-compat": { + "version": "3.37.1", + "resolved": "https://registry.npmjs.org/core-js-compat/-/core-js-compat-3.37.1.tgz", + "integrity": "sha512-9TNiImhKvQqSUkOvk/mMRZzOANTiEVC7WaBNhHcKM7x+/5E1l5NvsysR19zuDQScE8k+kfQXWRN3AtS/eOSHpg==", + "dev": true, + "dependencies": { + "browserslist": "^4.23.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/core-js" + } + }, + "node_modules/core-util-is": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.3.tgz", + "integrity": "sha512-ZQBvi1DcpJ4GDqanjucZ2Hj3wEO5pZDS89BWbkcrvdxksJorwUDDZamX9ldFkp9aw2lmBDLgkObEA4DWNJ9FYQ==", + "dev": true + }, + "node_modules/cosmiconfig": { + "version": "7.1.0", + "resolved": "https://registry.npmjs.org/cosmiconfig/-/cosmiconfig-7.1.0.tgz", + "integrity": "sha512-AdmX6xUzdNASswsFtmwSt7Vj8po9IuqXm0UXz7QKPuEUmPB4XyjGfaAr2PSuELMwkRMVH1EpIkX5bTZGRB3eCA==", + "dev": true, + "dependencies": { + "@types/parse-json": "^4.0.0", + "import-fresh": "^3.2.1", + "parse-json": "^5.0.0", + "path-type": "^4.0.0", + "yaml": "^1.10.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/create-ecdh": { + "version": "4.0.4", + "resolved": "https://registry.npmjs.org/create-ecdh/-/create-ecdh-4.0.4.tgz", + "integrity": "sha512-mf+TCx8wWc9VpuxfP2ht0iSISLZnt0JgWlrOKZiNqyUZWnjIaCIVNQArMHnCZKfEYRg6IM7A+NeJoN8gf/Ws0A==", + "dev": true, + "dependencies": { + "bn.js": "^4.1.0", + "elliptic": "^6.5.3" + } + }, + "node_modules/create-ecdh/node_modules/bn.js": { + "version": "4.12.0", + "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-4.12.0.tgz", + "integrity": "sha512-c98Bf3tPniI+scsdk237ku1Dc3ujXQTSgyiPUDEOe7tRkhrqridvh8klBv0HCEso1OLOYcHuCv/cS6DNxKH+ZA==", + "dev": true + }, + "node_modules/create-hash": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/create-hash/-/create-hash-1.2.0.tgz", + "integrity": "sha512-z00bCGNHDG8mHAkP7CtT1qVu+bFQUPjYq/4Iv3C3kWjTFV10zIjfSoeqXo9Asws8gwSHDGj/hl2u4OGIjapeCg==", + "dev": true, + "dependencies": { + "cipher-base": "^1.0.1", + "inherits": "^2.0.1", + "md5.js": "^1.3.4", + "ripemd160": "^2.0.1", + "sha.js": "^2.4.0" + } + }, + "node_modules/create-hmac": { + "version": "1.1.7", + "resolved": "https://registry.npmjs.org/create-hmac/-/create-hmac-1.1.7.tgz", + "integrity": "sha512-MJG9liiZ+ogc4TzUwuvbER1JRdgvUFSB5+VR/g5h82fGaIRWMWddtKBHi7/sVhfjQZ6SehlyhvQYrcYkaUIpLg==", + "dev": true, + "dependencies": { + "cipher-base": "^1.0.3", + "create-hash": "^1.1.0", + "inherits": "^2.0.1", + "ripemd160": "^2.0.0", + "safe-buffer": "^5.0.1", + "sha.js": "^2.4.8" + } + }, + "node_modules/cross-env": { + "version": "7.0.3", + "resolved": "https://registry.npmjs.org/cross-env/-/cross-env-7.0.3.tgz", + "integrity": "sha512-+/HKd6EgcQCJGh2PSjZuUitQBQynKor4wrFbRg4DtAgS1aWO+gU52xpH7M9ScGgXSYmAVS9bIJ8EzuaGw0oNAw==", + "dev": true, + "dependencies": { + "cross-spawn": "^7.0.1" + }, + "bin": { + "cross-env": "src/bin/cross-env.js", + "cross-env-shell": "src/bin/cross-env-shell.js" + }, + "engines": { + "node": ">=10.14", + "npm": ">=6", + "yarn": ">=1" + } + }, + "node_modules/cross-spawn": { + "version": "7.0.3", + "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.3.tgz", + "integrity": "sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w==", + "dev": true, + "dependencies": { + "path-key": "^3.1.0", + "shebang-command": "^2.0.0", + "which": "^2.0.1" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/crypt": { + "version": "0.0.2", + "resolved": "https://registry.npmjs.org/crypt/-/crypt-0.0.2.tgz", + "integrity": "sha1-iNf/fsDfuG9xPch7u0LQRNPmxBs=", + "dev": true, + "engines": { + "node": "*" + } + }, + "node_modules/crypto-browserify": { + "version": "3.12.0", + "resolved": "https://registry.npmjs.org/crypto-browserify/-/crypto-browserify-3.12.0.tgz", + "integrity": "sha512-fz4spIh+znjO2VjL+IdhEpRJ3YN6sMzITSBijk6FK2UvTqruSQW+/cCZTSNsMiZNvUeq0CqurF+dAbyiGOY6Wg==", + "dev": true, + "dependencies": { + "browserify-cipher": "^1.0.0", + "browserify-sign": "^4.0.0", + "create-ecdh": "^4.0.0", + "create-hash": "^1.1.0", + "create-hmac": "^1.1.0", + "diffie-hellman": "^5.0.0", + "inherits": "^2.0.1", + "pbkdf2": "^3.0.3", + "public-encrypt": "^4.0.0", + "randombytes": "^2.0.0", + "randomfill": "^1.0.3" + }, + "engines": { + "node": "*" + } + }, + "node_modules/css": { + "version": "2.2.4", + "resolved": "https://registry.npmjs.org/css/-/css-2.2.4.tgz", + "integrity": "sha512-oUnjmWpy0niI3x/mPL8dVEI1l7MnG3+HHyRPHf+YFSbK+svOhXpmSOcDURUh2aOCgl2grzrOPt1nHLuCVFULLw==", + "dev": true, + "dependencies": { + "inherits": "^2.0.3", + "source-map": "^0.6.1", + "source-map-resolve": "^0.5.2", + "urix": "^0.1.0" + } + }, + "node_modules/css-declaration-sorter": { + "version": "6.4.1", + "resolved": "https://registry.npmjs.org/css-declaration-sorter/-/css-declaration-sorter-6.4.1.tgz", + "integrity": "sha512-rtdthzxKuyq6IzqX6jEcIzQF/YqccluefyCYheovBOLhFT/drQA9zj/UbRAa9J7C0o6EG6u3E6g+vKkay7/k3g==", + "dev": true, + "engines": { + "node": "^10 || ^12 || >=14" + }, + "peerDependencies": { + "postcss": "^8.0.9" + } + }, + "node_modules/css-loader": { + "version": "5.2.7", + "resolved": "https://registry.npmjs.org/css-loader/-/css-loader-5.2.7.tgz", + "integrity": "sha512-Q7mOvpBNBG7YrVGMxRxcBJZFL75o+cH2abNASdibkj/fffYD8qWbInZrD0S9ccI6vZclF3DsHE7njGlLtaHbhg==", + "dev": true, + "dependencies": { + "icss-utils": "^5.1.0", + "loader-utils": "^2.0.0", + "postcss": "^8.2.15", + "postcss-modules-extract-imports": "^3.0.0", + "postcss-modules-local-by-default": "^4.0.0", + "postcss-modules-scope": "^3.0.0", + "postcss-modules-values": "^4.0.0", + "postcss-value-parser": "^4.1.0", + "schema-utils": "^3.0.0", + "semver": "^7.3.5" + }, + "engines": { + "node": ">= 10.13.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/webpack" + }, + "peerDependencies": { + "webpack": "^4.27.0 || ^5.0.0" + } + }, + "node_modules/css-loader/node_modules/loader-utils": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/loader-utils/-/loader-utils-2.0.4.tgz", + "integrity": "sha512-xXqpXoINfFhgua9xiqD8fPFHgkoq1mmmpE92WlDbm9rNRd/EbRb+Gqf908T2DMfuHjjJlksiK2RbHVOdD/MqSw==", + "dev": true, + "dependencies": { + "big.js": "^5.2.2", + "emojis-list": "^3.0.0", + "json5": "^2.1.2" + }, + "engines": { + "node": ">=8.9.0" + } + }, + "node_modules/css-loader/node_modules/schema-utils": { + "version": "3.3.0", + "resolved": "https://registry.npmjs.org/schema-utils/-/schema-utils-3.3.0.tgz", + "integrity": "sha512-pN/yOAvcC+5rQ5nERGuwrjLlYvLTbCibnZ1I7B1LaiAz9BRBlE9GMgE/eqV30P7aJQUf7Ddimy/RsbYO/GrVGg==", + "dev": true, + "dependencies": { + "@types/json-schema": "^7.0.8", + "ajv": "^6.12.5", + "ajv-keywords": "^3.5.2" + }, + "engines": { + "node": ">= 10.13.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/webpack" + } + }, + "node_modules/css-loader/node_modules/semver": { + "version": "7.6.2", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.6.2.tgz", + "integrity": "sha512-FNAIBWCx9qcRhoHcgcJ0gvU7SN1lYU2ZXuSfl04bSC5OpvDHFyJCjdNHomPXxjQlCBU67YW64PzY7/VIEH7F2w==", + "dev": true, + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/css-select": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/css-select/-/css-select-4.3.0.tgz", + "integrity": "sha512-wPpOYtnsVontu2mODhA19JrqWxNsfdatRKd64kmpRbQgh1KtItko5sTnEpPdpSaJszTOhEMlF/RPz28qj4HqhQ==", + "dev": true, + "dependencies": { + "boolbase": "^1.0.0", + "css-what": "^6.0.1", + "domhandler": "^4.3.1", + "domutils": "^2.8.0", + "nth-check": "^2.0.1" + }, + "funding": { + "url": "https://github.com/sponsors/fb55" + } + }, + "node_modules/css-select/node_modules/domhandler": { + "version": "4.3.1", + "resolved": "https://registry.npmjs.org/domhandler/-/domhandler-4.3.1.tgz", + "integrity": "sha512-GrwoxYN+uWlzO8uhUXRl0P+kHE4GtVPfYzVLcUxPL7KNdHKj66vvlhiweIHqYYXWlw+T8iLMp42Lm67ghw4WMQ==", + "dev": true, + "dependencies": { + "domelementtype": "^2.2.0" + }, + "engines": { + "node": ">= 4" + }, + "funding": { + "url": "https://github.com/fb55/domhandler?sponsor=1" + } + }, + "node_modules/css-tree": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/css-tree/-/css-tree-1.1.3.tgz", + "integrity": "sha512-tRpdppF7TRazZrjJ6v3stzv93qxRcSsFmW6cX0Zm2NVKpxE1WV1HblnghVv9TreireHkqI/VDEsfolRF1p6y7Q==", + "dev": true, + "dependencies": { + "mdn-data": "2.0.14", + "source-map": "^0.6.1" + }, + "engines": { + "node": ">=8.0.0" + } + }, + "node_modules/css-what": { + "version": "6.1.0", + "resolved": "https://registry.npmjs.org/css-what/-/css-what-6.1.0.tgz", + "integrity": "sha512-HTUrgRJ7r4dsZKU6GjmpfRK1O76h97Z8MfS1G0FozR+oF2kG6Vfe8JE6zwrkbxigziPHinCJ+gCPjA9EaBDtRw==", + "dev": true, + "engines": { + "node": ">= 6" + }, + "funding": { + "url": "https://github.com/sponsors/fb55" + } + }, + "node_modules/cssesc": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/cssesc/-/cssesc-3.0.0.tgz", + "integrity": "sha512-/Tb/JcjK111nNScGob5MNtsntNM1aCNUDipB/TkwZFhyDrrE47SOx/18wF2bbjgc3ZzCSKW1T5nt5EbFoAz/Vg==", + "dev": true, + "bin": { + "cssesc": "bin/cssesc" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/cssnano": { + "version": "5.1.15", + "resolved": "https://registry.npmjs.org/cssnano/-/cssnano-5.1.15.tgz", + "integrity": "sha512-j+BKgDcLDQA+eDifLx0EO4XSA56b7uut3BQFH+wbSaSTuGLuiyTa/wbRYthUXX8LC9mLg+WWKe8h+qJuwTAbHw==", + "dev": true, + "dependencies": { + "cssnano-preset-default": "^5.2.14", + "lilconfig": "^2.0.3", + "yaml": "^1.10.2" + }, + "engines": { + "node": "^10 || ^12 || >=14.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/cssnano" + }, + "peerDependencies": { + "postcss": "^8.2.15" + } + }, + "node_modules/cssnano-preset-default": { + "version": "5.2.14", + "resolved": "https://registry.npmjs.org/cssnano-preset-default/-/cssnano-preset-default-5.2.14.tgz", + "integrity": "sha512-t0SFesj/ZV2OTylqQVOrFgEh5uanxbO6ZAdeCrNsUQ6fVuXwYTxJPNAGvGTxHbD68ldIJNec7PyYZDBrfDQ+6A==", + "dev": true, + "dependencies": { + "css-declaration-sorter": "^6.3.1", + "cssnano-utils": "^3.1.0", + "postcss-calc": "^8.2.3", + "postcss-colormin": "^5.3.1", + "postcss-convert-values": "^5.1.3", + "postcss-discard-comments": "^5.1.2", + "postcss-discard-duplicates": "^5.1.0", + "postcss-discard-empty": "^5.1.1", + "postcss-discard-overridden": "^5.1.0", + "postcss-merge-longhand": "^5.1.7", + "postcss-merge-rules": "^5.1.4", + "postcss-minify-font-values": "^5.1.0", + "postcss-minify-gradients": "^5.1.1", + "postcss-minify-params": "^5.1.4", + "postcss-minify-selectors": "^5.2.1", + "postcss-normalize-charset": "^5.1.0", + "postcss-normalize-display-values": "^5.1.0", + "postcss-normalize-positions": "^5.1.1", + "postcss-normalize-repeat-style": "^5.1.1", + "postcss-normalize-string": "^5.1.0", + "postcss-normalize-timing-functions": "^5.1.0", + "postcss-normalize-unicode": "^5.1.1", + "postcss-normalize-url": "^5.1.0", + "postcss-normalize-whitespace": "^5.1.1", + "postcss-ordered-values": "^5.1.3", + "postcss-reduce-initial": "^5.1.2", + "postcss-reduce-transforms": "^5.1.0", + "postcss-svgo": "^5.1.0", + "postcss-unique-selectors": "^5.1.1" + }, + "engines": { + "node": "^10 || ^12 || >=14.0" + }, + "peerDependencies": { + "postcss": "^8.2.15" + } + }, + "node_modules/cssnano-utils": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/cssnano-utils/-/cssnano-utils-3.1.0.tgz", + "integrity": "sha512-JQNR19/YZhz4psLX/rQ9M83e3z2Wf/HdJbryzte4a3NSuafyp9w/I4U+hx5C2S9g41qlstH7DEWnZaaj83OuEA==", + "dev": true, + "engines": { + "node": "^10 || ^12 || >=14.0" + }, + "peerDependencies": { + "postcss": "^8.2.15" + } + }, + "node_modules/csso": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/csso/-/csso-4.2.0.tgz", + "integrity": "sha512-wvlcdIbf6pwKEk7vHj8/Bkc0B4ylXZruLvOgs9doS5eOsOpuodOV2zJChSpkp+pRpYQLQMeF04nr3Z68Sta9jA==", + "dev": true, + "dependencies": { + "css-tree": "^1.1.2" + }, + "engines": { + "node": ">=8.0.0" + } + }, + "node_modules/d": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/d/-/d-1.0.1.tgz", + "integrity": "sha512-m62ShEObQ39CfralilEQRjH6oAMtNCV1xJyEx5LpRYUVN+EviphDgUc/F3hnYbADmkiNs67Y+3ylmlG7Lnu+FA==", + "dev": true, + "dependencies": { + "es5-ext": "^0.10.50", + "type": "^1.0.1" + } + }, + "node_modules/de-indent": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/de-indent/-/de-indent-1.0.2.tgz", + "integrity": "sha1-sgOOhG3DO6pXlhKNCAS0VbjB4h0=", + "dev": true + }, + "node_modules/debug": { + "version": "2.6.9", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", + "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", + "dev": true, + "dependencies": { + "ms": "2.0.0" + } + }, + "node_modules/decode-uri-component": { + "version": "0.2.2", + "resolved": "https://registry.npmjs.org/decode-uri-component/-/decode-uri-component-0.2.2.tgz", + "integrity": "sha512-FqUYQ+8o158GyGTrMFJms9qh3CqTKvAqgqsTnkLI8sKu0028orqBhxNMFkFen0zGyg6epACD32pjVk58ngIErQ==", + "dev": true, + "engines": { + "node": ">=0.10" + } + }, + "node_modules/default-gateway": { + "version": "6.0.3", + "resolved": "https://registry.npmjs.org/default-gateway/-/default-gateway-6.0.3.tgz", + "integrity": "sha512-fwSOJsbbNzZ/CUFpqFBqYfYNLj1NbMPm8MMCIzHjC83iSJRBEGmDUxU+WP661BaBQImeC2yHwXtz+P/O9o+XEg==", + "dev": true, + "dependencies": { + "execa": "^5.0.0" + }, + "engines": { + "node": ">= 10" + } + }, + "node_modules/define-data-property": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/define-data-property/-/define-data-property-1.1.4.tgz", + "integrity": "sha512-rBMvIzlpA8v6E+SJZoo++HAYqsLrkg7MSfIinMPFhmkorw7X+dOXVJQs+QT69zGkzMyfDnIMN2Wid1+NbL3T+A==", + "dev": true, + "dependencies": { + "es-define-property": "^1.0.0", + "es-errors": "^1.3.0", + "gopd": "^1.0.1" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/define-lazy-prop": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/define-lazy-prop/-/define-lazy-prop-2.0.0.tgz", + "integrity": "sha512-Ds09qNh8yw3khSjiJjiUInaGX9xlqZDY7JVryGxdxV7NPeuqQfplOpQ66yJFZut3jLa5zOwkXw1g9EI2uKh4Og==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/define-properties": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.1.3.tgz", + "integrity": "sha512-3MqfYKj2lLzdMSf8ZIZE/V+Zuy+BgD6f164e8K2w7dgnpKArBDerGYpM46IYYcjnkdPNMjPk9A6VFB8+3SKlXQ==", + "dev": true, + "dependencies": { + "object-keys": "^1.0.12" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/delayed-stream": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz", + "integrity": "sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ==", + "dev": true, + "engines": { + "node": ">=0.4.0" + } + }, + "node_modules/depd": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/depd/-/depd-2.0.0.tgz", + "integrity": "sha512-g7nH6P6dyDioJogAAGprGpCtVImJhpPk/roCzdb3fIh61/s/nPsfR6onyMwkCAR/OlC3yBC0lESvUoQEAssIrw==", + "dev": true, + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/des.js": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/des.js/-/des.js-1.0.1.tgz", + "integrity": "sha512-Q0I4pfFrv2VPd34/vfLrFOoRmlYj3OV50i7fskps1jZWK1kApMWWT9G6RRUeYedLcBDIhnSDaUvJMb3AhUlaEA==", + "dev": true, + "dependencies": { + "inherits": "^2.0.1", + "minimalistic-assert": "^1.0.0" + } + }, + "node_modules/destroy": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/destroy/-/destroy-1.2.0.tgz", + "integrity": "sha512-2sJGJTaXIIaR1w4iJSNoN0hnMY7Gpc/n8D4qSCJw8QqFWXf7cuAgnEHxBpweaVcPevC2l3KpjYCx3NypQQgaJg==", + "dev": true, + "engines": { + "node": ">= 0.8", + "npm": "1.2.8000 || >= 1.4.16" + } + }, + "node_modules/detect-node": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/detect-node/-/detect-node-2.1.0.tgz", + "integrity": "sha512-T0NIuQpnTvFDATNuHN5roPwSBG83rFsuO+MXXH9/3N1eFbn4wcPjttvjMLEPWJ0RGUYgQE7cGgS3tNxbqCGM7g==", + "dev": true + }, + "node_modules/diffie-hellman": { + "version": "5.0.3", + "resolved": "https://registry.npmjs.org/diffie-hellman/-/diffie-hellman-5.0.3.tgz", + "integrity": "sha512-kqag/Nl+f3GwyK25fhUMYj81BUOrZ9IuJsjIcDE5icNM9FJHAVm3VcUDxdLPoQtTuUylWm6ZIknYJwwaPxsUzg==", + "dev": true, + "dependencies": { + "bn.js": "^4.1.0", + "miller-rabin": "^4.0.0", + "randombytes": "^2.0.0" + } + }, + "node_modules/diffie-hellman/node_modules/bn.js": { + "version": "4.12.0", + "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-4.12.0.tgz", + "integrity": "sha512-c98Bf3tPniI+scsdk237ku1Dc3ujXQTSgyiPUDEOe7tRkhrqridvh8klBv0HCEso1OLOYcHuCv/cS6DNxKH+ZA==", + "dev": true + }, + "node_modules/dir-glob": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/dir-glob/-/dir-glob-3.0.1.tgz", + "integrity": "sha512-WkrWp9GR4KXfKGYzOLmTuGVi1UWFfws377n9cc55/tb6DuqyF6pcQ5AbiHEshaDpY9v6oaSr2XCDidGmMwdzIA==", + "dev": true, + "dependencies": { + "path-type": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/dns-packet": { + "version": "5.6.1", + "resolved": "https://registry.npmjs.org/dns-packet/-/dns-packet-5.6.1.tgz", + "integrity": "sha512-l4gcSouhcgIKRvyy99RNVOgxXiicE+2jZoNmaNmZ6JXiGajBOJAesk1OBlJuM5k2c+eudGdLxDqXuPCKIj6kpw==", + "dev": true, + "dependencies": { + "@leichtgewicht/ip-codec": "^2.0.1" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/dom-serializer": { + "version": "1.4.1", + "resolved": "https://registry.npmjs.org/dom-serializer/-/dom-serializer-1.4.1.tgz", + "integrity": "sha512-VHwB3KfrcOOkelEG2ZOfxqLZdfkil8PtJi4P8N2MMXucZq2yLp75ClViUlOVwyoHEDjYU433Aq+5zWP61+RGag==", + "dev": true, + "dependencies": { + "domelementtype": "^2.0.1", + "domhandler": "^4.2.0", + "entities": "^2.0.0" + }, + "funding": { + "url": "https://github.com/cheeriojs/dom-serializer?sponsor=1" + } + }, + "node_modules/dom-serializer/node_modules/domhandler": { + "version": "4.3.1", + "resolved": "https://registry.npmjs.org/domhandler/-/domhandler-4.3.1.tgz", + "integrity": "sha512-GrwoxYN+uWlzO8uhUXRl0P+kHE4GtVPfYzVLcUxPL7KNdHKj66vvlhiweIHqYYXWlw+T8iLMp42Lm67ghw4WMQ==", + "dev": true, + "dependencies": { + "domelementtype": "^2.2.0" + }, + "engines": { + "node": ">= 4" + }, + "funding": { + "url": "https://github.com/fb55/domhandler?sponsor=1" + } + }, + "node_modules/domain-browser": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/domain-browser/-/domain-browser-1.2.0.tgz", + "integrity": "sha512-jnjyiM6eRyZl2H+W8Q/zLMA481hzi0eszAaBUzIVnmYVDBbnLxVNnfu1HgEBvCbL+71FrxMl3E6lpKH7Ge3OXA==", + "dev": true, + "engines": { + "node": ">=0.4", + "npm": ">=1.2" + } + }, + "node_modules/domelementtype": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/domelementtype/-/domelementtype-2.3.0.tgz", + "integrity": "sha512-OLETBj6w0OsagBwdXnPdN0cnMfF9opN69co+7ZrbfPGrdpPVNBUj02spi6B1N7wChLQiPn4CSH/zJvXw56gmHw==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/fb55" + } + ] + }, + "node_modules/domhandler": { + "version": "3.3.0", + "resolved": "https://registry.npmjs.org/domhandler/-/domhandler-3.3.0.tgz", + "integrity": "sha512-J1C5rIANUbuYK+FuFL98650rihynUOEzRLxW+90bKZRWB6A1X1Tf82GxR1qAWLyfNPRvjqfip3Q5tdYlmAa9lA==", + "dev": true, + "dependencies": { + "domelementtype": "^2.0.1" + }, + "engines": { + "node": ">= 4" + }, + "funding": { + "url": "https://github.com/fb55/domhandler?sponsor=1" + } + }, + "node_modules/domutils": { + "version": "2.8.0", + "resolved": "https://registry.npmjs.org/domutils/-/domutils-2.8.0.tgz", + "integrity": "sha512-w96Cjofp72M5IIhpjgobBimYEfoPjx1Vx0BSX9P30WBdZW2WIKU0T1Bd0kz2eNZ9ikjKgHbEyKx8BB6H1L3h3A==", + "dev": true, + "dependencies": { + "dom-serializer": "^1.0.1", + "domelementtype": "^2.2.0", + "domhandler": "^4.2.0" + }, + "funding": { + "url": "https://github.com/fb55/domutils?sponsor=1" + } + }, + "node_modules/domutils/node_modules/domhandler": { + "version": "4.3.1", + "resolved": "https://registry.npmjs.org/domhandler/-/domhandler-4.3.1.tgz", + "integrity": "sha512-GrwoxYN+uWlzO8uhUXRl0P+kHE4GtVPfYzVLcUxPL7KNdHKj66vvlhiweIHqYYXWlw+T8iLMp42Lm67ghw4WMQ==", + "dev": true, + "dependencies": { + "domelementtype": "^2.2.0" + }, + "engines": { + "node": ">= 4" + }, + "funding": { + "url": "https://github.com/fb55/domhandler?sponsor=1" + } + }, + "node_modules/dot-case": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/dot-case/-/dot-case-3.0.4.tgz", + "integrity": "sha512-Kv5nKlh6yRrdrGvxeJ2e5y2eRUpkUosIW4A2AS38zwSz27zu7ufDwQPi5Jhs3XAlGNetl3bmnGhQsMtkKJnj3w==", + "dev": true, + "dependencies": { + "no-case": "^3.0.4", + "tslib": "^2.0.3" + } + }, + "node_modules/dotenv": { + "version": "10.0.0", + "resolved": "https://registry.npmjs.org/dotenv/-/dotenv-10.0.0.tgz", + "integrity": "sha512-rlBi9d8jpv9Sf1klPjNfFAuWDjKLwTIJJ/VxtoTwIR6hnZxcEOQCZg2oIL3MWBYw5GpUDKOEnND7LXTbIpQ03Q==", + "dev": true, + "engines": { + "node": ">=10" + } + }, + "node_modules/dotenv-expand": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/dotenv-expand/-/dotenv-expand-5.1.0.tgz", + "integrity": "sha512-YXQl1DSa4/PQyRfgrv6aoNjhasp/p4qs9FjJ4q4cQk+8m4r6k4ZSiEyytKG8f8W9gi8WsQtIObNmKd+tMzNTmA==", + "dev": true + }, + "node_modules/ee-first": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/ee-first/-/ee-first-1.1.1.tgz", + "integrity": "sha512-WMwm9LhRUo+WUaRN+vRuETqG89IgZphVSNkdFgeb6sS/E4OrDIN7t48CAewSHXc6C8lefD8KKfr5vY61brQlow==", + "dev": true + }, + "node_modules/electron-to-chromium": { + "version": "1.4.803", + "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.4.803.tgz", + "integrity": "sha512-61H9mLzGOCLLVsnLiRzCbc63uldP0AniRYPV3hbGVtONA1pI7qSGILdbofR7A8TMbOypDocEAjH/e+9k1QIe3g==", + "dev": true + }, + "node_modules/elliptic": { + "version": "6.5.5", + "resolved": "https://registry.npmjs.org/elliptic/-/elliptic-6.5.5.tgz", + "integrity": "sha512-7EjbcmUm17NQFu4Pmgmq2olYMj8nwMnpcddByChSUjArp8F5DQWcIcpriwO4ZToLNAJig0yiyjswfyGNje/ixw==", + "dev": true, + "dependencies": { + "bn.js": "^4.11.9", + "brorand": "^1.1.0", + "hash.js": "^1.0.0", + "hmac-drbg": "^1.0.1", + "inherits": "^2.0.4", + "minimalistic-assert": "^1.0.1", + "minimalistic-crypto-utils": "^1.0.1" + } + }, + "node_modules/elliptic/node_modules/bn.js": { + "version": "4.12.0", + "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-4.12.0.tgz", + "integrity": "sha512-c98Bf3tPniI+scsdk237ku1Dc3ujXQTSgyiPUDEOe7tRkhrqridvh8klBv0HCEso1OLOYcHuCv/cS6DNxKH+ZA==", + "dev": true + }, + "node_modules/emoji-regex": { + "version": "8.0.0", + "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz", + "integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==", + "dev": true + }, + "node_modules/emojis-list": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/emojis-list/-/emojis-list-3.0.0.tgz", + "integrity": "sha512-/kyM18EfinwXZbno9FyUGeFh87KC8HRQBQGildHZbEuRyWFOmv1U10o9BBp8XVZDVNNuQKyIGIu5ZYAAXJ0V2Q==", + "dev": true, + "engines": { + "node": ">= 4" + } + }, + "node_modules/encodeurl": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-1.0.2.tgz", + "integrity": "sha512-TPJXq8JqFaVYm2CWmPvnP2Iyo4ZSM7/QKcSmuMLDObfpH5fi7RUGmd/rTDf+rut/saiDiQEeVTNgAmJEdAOx0w==", + "dev": true, + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/enhanced-resolve": { + "version": "5.17.0", + "resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-5.17.0.tgz", + "integrity": "sha512-dwDPwZL0dmye8Txp2gzFmA6sxALaSvdRDjPH0viLcKrtlOL3tw62nWWweVD1SdILDTJrbrL6tdWVN58Wo6U3eA==", + "dev": true, + "dependencies": { + "graceful-fs": "^4.2.4", + "tapable": "^2.2.0" + }, + "engines": { + "node": ">=10.13.0" + } + }, + "node_modules/entities": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/entities/-/entities-2.2.0.tgz", + "integrity": "sha512-p92if5Nz619I0w+akJrLZH0MX0Pb5DX39XOwQTtXSdQQOaYH03S1uIQp4mhOZtAXrxq4ViO67YTiLBo2638o9A==", + "dev": true, + "funding": { + "url": "https://github.com/fb55/entities?sponsor=1" + } + }, + "node_modules/envinfo": { + "version": "7.13.0", + "resolved": "https://registry.npmjs.org/envinfo/-/envinfo-7.13.0.tgz", + "integrity": "sha512-cvcaMr7KqXVh4nyzGTVqTum+gAiL265x5jUWQIDLq//zOGbW+gSW/C+OWLleY/rs9Qole6AZLMXPbtIFQbqu+Q==", + "dev": true, + "bin": { + "envinfo": "dist/cli.js" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/error-ex": { + "version": "1.3.2", + "resolved": "https://registry.npmjs.org/error-ex/-/error-ex-1.3.2.tgz", + "integrity": "sha512-7dFHNmqeFSEt2ZBsCriorKnn3Z2pj+fd9kmI6QoWw4//DL+icEBfc0U7qJCisqrTsKTjw4fNFy2pW9OqStD84g==", + "dev": true, + "dependencies": { + "is-arrayish": "^0.2.1" + } + }, + "node_modules/es-define-property": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/es-define-property/-/es-define-property-1.0.0.tgz", + "integrity": "sha512-jxayLKShrEqqzJ0eumQbVhTYQM27CfT1T35+gCgDFoL82JLsXqTJ76zv6A0YLOgEnLUMvLzsDsGIrl8NFpT2gQ==", + "dev": true, + "dependencies": { + "get-intrinsic": "^1.2.4" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/es-errors": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/es-errors/-/es-errors-1.3.0.tgz", + "integrity": "sha512-Zf5H2Kxt2xjTvbJvP2ZWLEICxA6j+hAmMzIlypy4xcBg1vKVnx89Wy0GbS+kf5cwCVFFzdCFh2XSCFNULS6csw==", + "dev": true, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/es-module-lexer": { + "version": "1.5.3", + "resolved": "https://registry.npmjs.org/es-module-lexer/-/es-module-lexer-1.5.3.tgz", + "integrity": "sha512-i1gCgmR9dCl6Vil6UKPI/trA69s08g/syhiDK9TG0Nf1RJjjFI+AzoWW7sPufzkgYAn861skuCwJa0pIIHYxvg==", + "dev": true + }, + "node_modules/es5-ext": { + "version": "0.10.64", + "resolved": "https://registry.npmjs.org/es5-ext/-/es5-ext-0.10.64.tgz", + "integrity": "sha512-p2snDhiLaXe6dahss1LddxqEm+SkuDvV8dnIQG0MWjyHpcMNfXKPE+/Cc0y+PhxJX3A4xGNeFCj5oc0BUh6deg==", + "dev": true, + "hasInstallScript": true, + "dependencies": { + "es6-iterator": "^2.0.3", + "es6-symbol": "^3.1.3", + "esniff": "^2.0.1", + "next-tick": "^1.1.0" + }, + "engines": { + "node": ">=0.10" + } + }, + "node_modules/es6-iterator": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/es6-iterator/-/es6-iterator-2.0.3.tgz", + "integrity": "sha1-p96IkUGgWpSwhUQDstCg+/qY87c=", + "dev": true, + "dependencies": { + "d": "1", + "es5-ext": "^0.10.35", + "es6-symbol": "^3.1.1" + } + }, + "node_modules/es6-symbol": { + "version": "3.1.3", + "resolved": "https://registry.npmjs.org/es6-symbol/-/es6-symbol-3.1.3.tgz", + "integrity": "sha512-NJ6Yn3FuDinBaBRWl/q5X/s4koRHBrgKAu+yGI6JCBeiu3qrcbJhwT2GeR/EXVfylRk8dpQVJoLEFhK+Mu31NA==", + "dev": true, + "dependencies": { + "d": "^1.0.1", + "ext": "^1.1.2" + } + }, + "node_modules/escalade": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/escalade/-/escalade-3.1.2.tgz", + "integrity": "sha512-ErCHMCae19vR8vQGe50xIsVomy19rg6gFu3+r3jkEO46suLMWBksvVyoGgQV+jOfl84ZSOSlmv6Gxa89PmTGmA==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/escape-html": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/escape-html/-/escape-html-1.0.3.tgz", + "integrity": "sha512-NiSupZ4OeuGwr68lGIeym/ksIZMJodUGOSCZ/FSnTxcrekbvqrgdUxlJOMpijaKZVjAJrWrGs/6Jy8OMuyj9ow==", + "dev": true + }, + "node_modules/escape-string-regexp": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz", + "integrity": "sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ=", + "dev": true, + "engines": { + "node": ">=0.8.0" + } + }, + "node_modules/eslint-scope": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-5.1.1.tgz", + "integrity": "sha512-2NxwbF/hZ0KpepYN0cNbo+FN6XoK7GaHlQhgx/hIZl6Va0bF45RQOOwhLIy8lQDbuCiadSLCBnH2CFYquit5bw==", + "dev": true, + "dependencies": { + "esrecurse": "^4.3.0", + "estraverse": "^4.1.1" + }, + "engines": { + "node": ">=8.0.0" + } + }, + "node_modules/esniff": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/esniff/-/esniff-2.0.1.tgz", + "integrity": "sha512-kTUIGKQ/mDPFoJ0oVfcmyJn4iBDRptjNVIzwIFR7tqWXdVI9xfA2RMwY/gbSpJG3lkdWNEjLap/NqVHZiJsdfg==", + "dev": true, + "dependencies": { + "d": "^1.0.1", + "es5-ext": "^0.10.62", + "event-emitter": "^0.3.5", + "type": "^2.7.2" + }, + "engines": { + "node": ">=0.10" + } + }, + "node_modules/esniff/node_modules/type": { + "version": "2.7.3", + "resolved": "https://registry.npmjs.org/type/-/type-2.7.3.tgz", + "integrity": "sha512-8j+1QmAbPvLZow5Qpi6NCaN8FB60p/6x8/vfNqOk/hC+HuvFZhL4+WfekuhQLiqFZXOgQdrs3B+XxEmCc6b3FQ==", + "dev": true + }, + "node_modules/esrecurse": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/esrecurse/-/esrecurse-4.3.0.tgz", + "integrity": "sha512-KmfKL3b6G+RXvP8N1vr3Tq1kL/oCFgn2NYXEtqP8/L3pKapUA4G8cFVaoF3SU323CD4XypR/ffioHmkti6/Tag==", + "dev": true, + "dependencies": { + "estraverse": "^5.2.0" + }, + "engines": { + "node": ">=4.0" + } + }, + "node_modules/esrecurse/node_modules/estraverse": { + "version": "5.3.0", + "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-5.3.0.tgz", + "integrity": "sha512-MMdARuVEQziNTeJD8DgMqmhwR11BRQ/cBP+pLtYdSTnf3MIO8fFeiINEbX36ZdNlfU/7A9f3gUw49B3oQsvwBA==", + "dev": true, + "engines": { + "node": ">=4.0" + } + }, + "node_modules/estraverse": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-4.3.0.tgz", + "integrity": "sha512-39nnKffWz8xN1BU/2c79n9nB9HDzo0niYUqx6xyqUnyoAnQyyWpOTdZEeiCch8BBu515t4wp9ZmgVfVhn9EBpw==", + "dev": true, + "engines": { + "node": ">=4.0" + } + }, + "node_modules/esutils": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/esutils/-/esutils-2.0.3.tgz", + "integrity": "sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/etag": { + "version": "1.8.1", + "resolved": "https://registry.npmjs.org/etag/-/etag-1.8.1.tgz", + "integrity": "sha512-aIL5Fx7mawVa300al2BnEE4iNvo1qETxLrPI/o05L7z6go7fCw1J6EQmbK4FmJ2AS7kgVF/KEZWufBfdClMcPg==", + "dev": true, + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/event-emitter": { + "version": "0.3.5", + "resolved": "https://registry.npmjs.org/event-emitter/-/event-emitter-0.3.5.tgz", + "integrity": "sha512-D9rRn9y7kLPnJ+hMq7S/nhvoKwwvVJahBi2BPmx3bvbsEdK3W9ii8cBSGjP+72/LnM4n6fo3+dkCX5FeTQruXA==", + "dev": true, + "dependencies": { + "d": "1", + "es5-ext": "~0.10.14" + } + }, + "node_modules/eventemitter3": { + "version": "4.0.7", + "resolved": "https://registry.npmjs.org/eventemitter3/-/eventemitter3-4.0.7.tgz", + "integrity": "sha512-8guHBZCwKnFhYdHr2ysuRWErTwhoN2X8XELRlrRwpmfeY2jjuUN4taQMsULKUVo1K4DvZl+0pgfyoysHxvmvEw==", + "dev": true + }, + "node_modules/events": { + "version": "3.3.0", + "resolved": "https://registry.npmjs.org/events/-/events-3.3.0.tgz", + "integrity": "sha512-mQw+2fkQbALzQ7V0MY0IqdnXNOeTtP4r0lN9z7AAawCXgqea7bDii20AYrIBrFd/Hx0M2Ocz6S111CaFkUcb0Q==", + "dev": true, + "engines": { + "node": ">=0.8.x" + } + }, + "node_modules/evp_bytestokey": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/evp_bytestokey/-/evp_bytestokey-1.0.3.tgz", + "integrity": "sha512-/f2Go4TognH/KvCISP7OUsHn85hT9nUkxxA9BEWxFn+Oj9o8ZNLm/40hdlgSLyuOimsrTKLUMEorQexp/aPQeA==", + "dev": true, + "dependencies": { + "md5.js": "^1.3.4", + "safe-buffer": "^5.1.1" + } + }, + "node_modules/execa": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/execa/-/execa-5.1.1.tgz", + "integrity": "sha512-8uSpZZocAZRBAPIEINJj3Lo9HyGitllczc27Eh5YYojjMFMn8yHMDMaUHE2Jqfq05D/wucwI4JGURyXt1vchyg==", + "dev": true, + "dependencies": { + "cross-spawn": "^7.0.3", + "get-stream": "^6.0.0", + "human-signals": "^2.1.0", + "is-stream": "^2.0.0", + "merge-stream": "^2.0.0", + "npm-run-path": "^4.0.1", + "onetime": "^5.1.2", + "signal-exit": "^3.0.3", + "strip-final-newline": "^2.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sindresorhus/execa?sponsor=1" + } + }, + "node_modules/express": { + "version": "4.19.2", + "resolved": "https://registry.npmjs.org/express/-/express-4.19.2.tgz", + "integrity": "sha512-5T6nhjsT+EOMzuck8JjBHARTHfMht0POzlA60WV2pMD3gyXw2LZnZ+ueGdNxG+0calOJcWKbpFcuzLZ91YWq9Q==", + "dev": true, + "dependencies": { + "accepts": "~1.3.8", + "array-flatten": "1.1.1", + "body-parser": "1.20.2", + "content-disposition": "0.5.4", + "content-type": "~1.0.4", + "cookie": "0.6.0", + "cookie-signature": "1.0.6", + "debug": "2.6.9", + "depd": "2.0.0", + "encodeurl": "~1.0.2", + "escape-html": "~1.0.3", + "etag": "~1.8.1", + "finalhandler": "1.2.0", + "fresh": "0.5.2", + "http-errors": "2.0.0", + "merge-descriptors": "1.0.1", + "methods": "~1.1.2", + "on-finished": "2.4.1", + "parseurl": "~1.3.3", + "path-to-regexp": "0.1.7", + "proxy-addr": "~2.0.7", + "qs": "6.11.0", + "range-parser": "~1.2.1", + "safe-buffer": "5.2.1", + "send": "0.18.0", + "serve-static": "1.15.0", + "setprototypeof": "1.2.0", + "statuses": "2.0.1", + "type-is": "~1.6.18", + "utils-merge": "1.0.1", + "vary": "~1.1.2" + }, + "engines": { + "node": ">= 0.10.0" + } + }, + "node_modules/express/node_modules/safe-buffer": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", + "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ] + }, + "node_modules/ext": { + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/ext/-/ext-1.6.0.tgz", + "integrity": "sha512-sdBImtzkq2HpkdRLtlLWDa6w4DX22ijZLKx8BMPUuKe1c5lbN6xwQDQCxSfxBQnHZ13ls/FH0MQZx/q/gr6FQg==", + "dev": true, + "dependencies": { + "type": "^2.5.0" + } + }, + "node_modules/ext/node_modules/type": { + "version": "2.6.0", + "resolved": "https://registry.npmjs.org/type/-/type-2.6.0.tgz", + "integrity": "sha512-eiDBDOmkih5pMbo9OqsqPRGMljLodLcwd5XD5JbtNB0o89xZAwynY9EdCDsJU7LtcVCClu9DvM7/0Ep1hYX3EQ==", + "dev": true + }, + "node_modules/fast-deep-equal": { + "version": "3.1.3", + "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz", + "integrity": "sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==", + "dev": true + }, + "node_modules/fast-glob": { + "version": "3.3.2", + "resolved": "https://registry.npmjs.org/fast-glob/-/fast-glob-3.3.2.tgz", + "integrity": "sha512-oX2ruAFQwf/Orj8m737Y5adxDQO0LAB7/S5MnxCdTNDd4p6BsyIVsv9JQsATbTSq8KHRpLwIHbVlUNatxd+1Ow==", + "dev": true, + "dependencies": { + "@nodelib/fs.stat": "^2.0.2", + "@nodelib/fs.walk": "^1.2.3", + "glob-parent": "^5.1.2", + "merge2": "^1.3.0", + "micromatch": "^4.0.4" + }, + "engines": { + "node": ">=8.6.0" + } + }, + "node_modules/fast-json-stable-stringify": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/fast-json-stable-stringify/-/fast-json-stable-stringify-2.1.0.tgz", + "integrity": "sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw==", + "dev": true + }, + "node_modules/fastest-levenshtein": { + "version": "1.0.16", + "resolved": "https://registry.npmjs.org/fastest-levenshtein/-/fastest-levenshtein-1.0.16.tgz", + "integrity": "sha512-eRnCtTTtGZFpQCwhJiUOuxPQWRXVKYDn0b2PeHfXL6/Zi53SLAzAHfVhVWK2AryC/WH05kGfxhFIPvTF0SXQzg==", + "dev": true, + "engines": { + "node": ">= 4.9.1" + } + }, + "node_modules/fastq": { + "version": "1.17.1", + "resolved": "https://registry.npmjs.org/fastq/-/fastq-1.17.1.tgz", + "integrity": "sha512-sRVD3lWVIXWg6By68ZN7vho9a1pQcN/WBFaAAsDDFzlJjvoGx0P8z7V1t72grFJfJhu3YPZBuu25f7Kaw2jN1w==", + "dev": true, + "dependencies": { + "reusify": "^1.0.4" + } + }, + "node_modules/faye-websocket": { + "version": "0.11.4", + "resolved": "https://registry.npmjs.org/faye-websocket/-/faye-websocket-0.11.4.tgz", + "integrity": "sha512-CzbClwlXAuiRQAlUyfqPgvPoNKTckTPGfwZV4ZdAhVcP2lh9KUxJg2b5GkE7XbjKQ3YJnQ9z6D9ntLAlB+tP8g==", + "dev": true, + "dependencies": { + "websocket-driver": ">=0.5.1" + }, + "engines": { + "node": ">=0.8.0" + } + }, + "node_modules/file-loader": { + "version": "6.2.0", + "resolved": "https://registry.npmjs.org/file-loader/-/file-loader-6.2.0.tgz", + "integrity": "sha512-qo3glqyTa61Ytg4u73GultjHGjdRyig3tG6lPtyX/jOEJvHif9uB0/OCI2Kif6ctF3caQTW2G5gym21oAsI4pw==", + "dev": true, + "dependencies": { + "loader-utils": "^2.0.0", + "schema-utils": "^3.0.0" + }, + "engines": { + "node": ">= 10.13.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/webpack" + }, + "peerDependencies": { + "webpack": "^4.0.0 || ^5.0.0" + } + }, + "node_modules/file-loader/node_modules/loader-utils": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/loader-utils/-/loader-utils-2.0.4.tgz", + "integrity": "sha512-xXqpXoINfFhgua9xiqD8fPFHgkoq1mmmpE92WlDbm9rNRd/EbRb+Gqf908T2DMfuHjjJlksiK2RbHVOdD/MqSw==", + "dev": true, + "dependencies": { + "big.js": "^5.2.2", + "emojis-list": "^3.0.0", + "json5": "^2.1.2" + }, + "engines": { + "node": ">=8.9.0" + } + }, + "node_modules/file-loader/node_modules/schema-utils": { + "version": "3.3.0", + "resolved": "https://registry.npmjs.org/schema-utils/-/schema-utils-3.3.0.tgz", + "integrity": "sha512-pN/yOAvcC+5rQ5nERGuwrjLlYvLTbCibnZ1I7B1LaiAz9BRBlE9GMgE/eqV30P7aJQUf7Ddimy/RsbYO/GrVGg==", + "dev": true, + "dependencies": { + "@types/json-schema": "^7.0.8", + "ajv": "^6.12.5", + "ajv-keywords": "^3.5.2" + }, + "engines": { + "node": ">= 10.13.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/webpack" + } + }, + "node_modules/file-type": { + "version": "12.4.2", + "resolved": "https://registry.npmjs.org/file-type/-/file-type-12.4.2.tgz", + "integrity": "sha512-UssQP5ZgIOKelfsaB5CuGAL+Y+q7EmONuiwF3N5HAH0t27rvrttgi6Ra9k/+DVaY9UF6+ybxu5pOXLUdA8N7Vg==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/fill-range": { + "version": "7.1.1", + "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.1.1.tgz", + "integrity": "sha512-YsGpe3WHLK8ZYi4tWDg2Jy3ebRz2rXowDxnld4bkQB00cc/1Zw9AWnC0i9ztDJitivtQvaI9KaLyKrc+hBW0yg==", + "dev": true, + "dependencies": { + "to-regex-range": "^5.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/finalhandler": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/finalhandler/-/finalhandler-1.2.0.tgz", + "integrity": "sha512-5uXcUVftlQMFnWC9qu/svkWv3GTd2PfUhK/3PLkYNAe7FbqJMt3515HaxE6eRL74GdsriiwujiawdaB1BpEISg==", + "dev": true, + "dependencies": { + "debug": "2.6.9", + "encodeurl": "~1.0.2", + "escape-html": "~1.0.3", + "on-finished": "2.4.1", + "parseurl": "~1.3.3", + "statuses": "2.0.1", + "unpipe": "~1.0.0" + }, + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/find-cache-dir": { + "version": "3.3.2", + "resolved": "https://registry.npmjs.org/find-cache-dir/-/find-cache-dir-3.3.2.tgz", + "integrity": "sha512-wXZV5emFEjrridIgED11OoUKLxiYjAcqot/NJdAkOhlJ+vGzwhOAfcG5OX1jP+S0PcjEn8bdMJv+g2jwQ3Onig==", + "dev": true, + "dependencies": { + "commondir": "^1.0.1", + "make-dir": "^3.0.2", + "pkg-dir": "^4.1.0" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/avajs/find-cache-dir?sponsor=1" + } + }, + "node_modules/find-up": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/find-up/-/find-up-4.1.0.tgz", + "integrity": "sha512-PpOwAdQ/YlXQ2vj8a3h8IipDuYRi3wceVQQGYWxNINccq40Anw7BlsEXCMbt1Zt+OLA6Fq9suIpIWD0OsnISlw==", + "dev": true, + "dependencies": { + "locate-path": "^5.0.0", + "path-exists": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/flat": { + "version": "5.0.2", + "resolved": "https://registry.npmjs.org/flat/-/flat-5.0.2.tgz", + "integrity": "sha512-b6suED+5/3rTpUBdG1gupIl8MPFCAMA0QXwmljLhvCUKcUvdE4gWky9zpuGCcXHOsz4J9wPGNWq6OKpmIzz3hQ==", + "dev": true, + "bin": { + "flat": "cli.js" + } + }, + "node_modules/follow-redirects": { + "version": "1.15.6", + "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.15.6.tgz", + "integrity": "sha512-wWN62YITEaOpSK584EZXJafH1AGpO8RVgElfkuXbTOrPX4fIfOyEpW/CsiNd8JdYrAoOvafRTOEnvsO++qCqFA==", + "dev": true, + "funding": [ + { + "type": "individual", + "url": "https://github.com/sponsors/RubenVerborgh" + } + ], + "engines": { + "node": ">=4.0" + }, + "peerDependenciesMeta": { + "debug": { + "optional": true + } + } + }, + "node_modules/form-data": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/form-data/-/form-data-4.0.0.tgz", + "integrity": "sha512-ETEklSGi5t0QMZuiXoA/Q6vcnxcLQP5vdugSpuAyi6SVGi2clPPp+xgEhuMaHC+zGgn31Kd235W35f7Hykkaww==", + "dev": true, + "dependencies": { + "asynckit": "^0.4.0", + "combined-stream": "^1.0.8", + "mime-types": "^2.1.12" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/forwarded": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/forwarded/-/forwarded-0.2.0.tgz", + "integrity": "sha512-buRG0fpBtRHSTCOASe6hD258tEubFoRLb4ZNA6NxMVHNw2gOcwHo9wyablzMzOA5z9xA9L1KNjk/Nt6MT9aYow==", + "dev": true, + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/fraction.js": { + "version": "4.3.7", + "resolved": "https://registry.npmjs.org/fraction.js/-/fraction.js-4.3.7.tgz", + "integrity": "sha512-ZsDfxO51wGAXREY55a7la9LScWpwv9RxIrYABrlvOFBlH/ShPnrtsXeuUIfXKKOVicNxQ+o8JTbJvjS4M89yew==", + "dev": true, + "engines": { + "node": "*" + }, + "funding": { + "type": "patreon", + "url": "https://github.com/sponsors/rawify" + } + }, + "node_modules/fresh": { + "version": "0.5.2", + "resolved": "https://registry.npmjs.org/fresh/-/fresh-0.5.2.tgz", + "integrity": "sha512-zJ2mQYM18rEFOudeV4GShTGIQ7RbzA7ozbU9I/XBpm7kqgMywgmylMwXHxZJmkVoYkna9d2pVXVXPdYTP9ej8Q==", + "dev": true, + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/fs-extra": { + "version": "10.1.0", + "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-10.1.0.tgz", + "integrity": "sha512-oRXApq54ETRj4eMiFzGnHWGy+zo5raudjuxN0b8H7s/RU2oW0Wvsx9O0ACRN/kRq9E8Vu/ReskGB5o3ji+FzHQ==", + "dev": true, + "dependencies": { + "graceful-fs": "^4.2.0", + "jsonfile": "^6.0.1", + "universalify": "^2.0.0" + }, + "engines": { + "node": ">=12" + } + }, + "node_modules/fs-monkey": { + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/fs-monkey/-/fs-monkey-1.0.6.tgz", + "integrity": "sha512-b1FMfwetIKymC0eioW7mTywihSQE4oLzQn1dB6rZB5fx/3NpNEdAWeCSMB+60/AeT0TCXsxzAlcYVEFCTAksWg==", + "dev": true + }, + "node_modules/fs.realpath": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", + "integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=", + "dev": true + }, + "node_modules/fsevents": { + "version": "2.3.3", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz", + "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==", + "dev": true, + "hasInstallScript": true, + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": "^8.16.0 || ^10.6.0 || >=11.0.0" + } + }, + "node_modules/function-bind": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.2.tgz", + "integrity": "sha512-7XHNxH7qX9xG5mIwxkhumTox/MIRNcOgDrxWsMt2pAr23WHp6MrRlN7FBSFpCpr+oVO0F744iUgR82nJMfG2SA==", + "dev": true, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/gensync": { + "version": "1.0.0-beta.2", + "resolved": "https://registry.npmjs.org/gensync/-/gensync-1.0.0-beta.2.tgz", + "integrity": "sha512-3hN7NaskYvMDLQY55gnW3NQ+mesEAepTqlg+VEbj7zzqEMBVNhzcGYYeqFo/TlYz6eQiFcp1HcsCZO+nGgS8zg==", + "dev": true, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/get-caller-file": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz", + "integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==", + "dev": true, + "engines": { + "node": "6.* || 8.* || >= 10.*" + } + }, + "node_modules/get-intrinsic": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.2.4.tgz", + "integrity": "sha512-5uYhsJH8VJBTv7oslg4BznJYhDoRI6waYCxMmCdnTrcCrHA/fCFKoTFz2JKKE0HdDFUF7/oQuhzumXJK7paBRQ==", + "dev": true, + "dependencies": { + "es-errors": "^1.3.0", + "function-bind": "^1.1.2", + "has-proto": "^1.0.1", + "has-symbols": "^1.0.3", + "hasown": "^2.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/get-stream": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-6.0.1.tgz", + "integrity": "sha512-ts6Wi+2j3jQjqi70w5AlN8DFnkSwC+MqmxEzdEALB2qXZYV3X/b1CTfgPLGJNMeAWxdPfU8FO1ms3NUfaHCPYg==", + "dev": true, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/glob": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.0.tgz", + "integrity": "sha512-lmLf6gtyrPq8tTjSmrO94wBeQbFR3HbLHbuyD69wuyQkImp2hWqMGB47OX65FBkPffO641IP9jWa1z4ivqG26Q==", + "dev": true, + "dependencies": { + "fs.realpath": "^1.0.0", + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "^3.0.4", + "once": "^1.3.0", + "path-is-absolute": "^1.0.0" + }, + "engines": { + "node": "*" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, + "node_modules/glob-parent": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz", + "integrity": "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==", + "dev": true, + "dependencies": { + "is-glob": "^4.0.1" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/glob-to-regexp": { + "version": "0.4.1", + "resolved": "https://registry.npmjs.org/glob-to-regexp/-/glob-to-regexp-0.4.1.tgz", + "integrity": "sha512-lkX1HJXwyMcprw/5YUZc2s7DrpAiHB21/V+E1rHUrVNokkvB6bqMzT0VfV6/86ZNabt1k14YOIaT7nDvOX3Iiw==", + "dev": true + }, + "node_modules/globals": { + "version": "11.12.0", + "resolved": "https://registry.npmjs.org/globals/-/globals-11.12.0.tgz", + "integrity": "sha512-WOBp/EEGUiIsJSp7wcv/y6MO+lV9UoncWqxuFfm8eBwzWNgyfBd6Gz+IeKQ9jCmyhoH99g15M3T+QaVHFjizVA==", + "dev": true, + "engines": { + "node": ">=4" + } + }, + "node_modules/globby": { + "version": "10.0.2", + "resolved": "https://registry.npmjs.org/globby/-/globby-10.0.2.tgz", + "integrity": "sha512-7dUi7RvCoT/xast/o/dLN53oqND4yk0nsHkhRgn9w65C4PofCLOoJ39iSOg+qVDdWQPIEj+eszMHQ+aLVwwQSg==", + "dev": true, + "dependencies": { + "@types/glob": "^7.1.1", + "array-union": "^2.1.0", + "dir-glob": "^3.0.1", + "fast-glob": "^3.0.3", + "glob": "^7.1.3", + "ignore": "^5.1.1", + "merge2": "^1.2.3", + "slash": "^3.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/gopd": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/gopd/-/gopd-1.0.1.tgz", + "integrity": "sha512-d65bNlIadxvpb/A2abVdlqKqV563juRnZ1Wtk6s1sIR8uNsXR70xqIzVqxVf1eTqDunwT2MkczEeaezCKTZhwA==", + "dev": true, + "dependencies": { + "get-intrinsic": "^1.1.3" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/graceful-fs": { + "version": "4.2.11", + "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz", + "integrity": "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==", + "dev": true + }, + "node_modules/growly": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/growly/-/growly-1.3.0.tgz", + "integrity": "sha1-8QdIy+dq+WS3yWyTxrzCivEgwIE=", + "dev": true + }, + "node_modules/handle-thing": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/handle-thing/-/handle-thing-2.0.1.tgz", + "integrity": "sha512-9Qn4yBxelxoh2Ow62nP+Ka/kMnOXRi8BXnRaUwezLNhqelnN49xKz4F/dPP8OYLxLxq6JDtZb2i9XznUQbNPTg==", + "dev": true + }, + "node_modules/has": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz", + "integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==", + "dev": true, + "dependencies": { + "function-bind": "^1.1.1" + }, + "engines": { + "node": ">= 0.4.0" + } + }, + "node_modules/has-flag": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz", + "integrity": "sha1-tdRU3CGZriJWmfNGfloH87lVuv0=", + "dev": true, + "engines": { + "node": ">=4" + } + }, + "node_modules/has-property-descriptors": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/has-property-descriptors/-/has-property-descriptors-1.0.2.tgz", + "integrity": "sha512-55JNKuIW+vq4Ke1BjOTjM2YctQIvCT7GFzHwmfZPGo5wnrgkid0YQtnAleFSqumZm4az3n2BS+erby5ipJdgrg==", + "dev": true, + "dependencies": { + "es-define-property": "^1.0.0" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/has-proto": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has-proto/-/has-proto-1.0.3.tgz", + "integrity": "sha512-SJ1amZAJUiZS+PhsVLf5tGydlaVB8EdFpaSO4gmiUKUOxk8qzn5AIy4ZeJUmh22znIdk/uMAUT2pl3FxzVUH+Q==", + "dev": true, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/has-symbols": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.3.tgz", + "integrity": "sha512-l3LCuF6MgDNwTDKkdYGEihYjt5pRPbEg46rtlmnSPlUbgmB8LOIrKJbYYFBSbnPaJexMKtiPO8hmeRjRz2Td+A==", + "dev": true, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/hash-base": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/hash-base/-/hash-base-3.1.0.tgz", + "integrity": "sha512-1nmYp/rhMDiE7AYkDw+lLwlAzz0AntGIe51F3RfFfEqyQ3feY2eI/NcwC6umIQVOASPMsWJLJScWKSSvzL9IVA==", + "dev": true, + "dependencies": { + "inherits": "^2.0.4", + "readable-stream": "^3.6.0", + "safe-buffer": "^5.2.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/hash-base/node_modules/readable-stream": { + "version": "3.6.0", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.0.tgz", + "integrity": "sha512-BViHy7LKeTz4oNnkcLJ+lVSL6vpiFeX6/d3oSH8zCW7UxP2onchk+vTGB143xuFjHS3deTgkKoXXymXqymiIdA==", + "dev": true, + "dependencies": { + "inherits": "^2.0.3", + "string_decoder": "^1.1.1", + "util-deprecate": "^1.0.1" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/hash-base/node_modules/safe-buffer": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", + "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ] + }, + "node_modules/hash-sum": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/hash-sum/-/hash-sum-1.0.2.tgz", + "integrity": "sha512-fUs4B4L+mlt8/XAtSOGMUO1TXmAelItBPtJG7CyHJfYTdDjwisntGO2JQz7oUsatOY9o68+57eziUVNw/mRHmA==", + "dev": true + }, + "node_modules/hash.js": { + "version": "1.1.7", + "resolved": "https://registry.npmjs.org/hash.js/-/hash.js-1.1.7.tgz", + "integrity": "sha512-taOaskGt4z4SOANNseOviYDvjEJinIkRgmp7LbKP2YTTmVxWBl87s/uzK9r+44BclBSp2X7K1hqeNfz9JbBeXA==", + "dev": true, + "dependencies": { + "inherits": "^2.0.3", + "minimalistic-assert": "^1.0.1" + } + }, + "node_modules/hasown": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/hasown/-/hasown-2.0.2.tgz", + "integrity": "sha512-0hJU9SCPvmMzIBdZFqNPXWa6dqh7WdH0cII9y+CyS8rG3nL48Bclra9HmKhVVUHyPWNH5Y7xDwAB7bfgSjkUMQ==", + "dev": true, + "dependencies": { + "function-bind": "^1.1.2" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/he": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/he/-/he-1.2.0.tgz", + "integrity": "sha512-F/1DnUGPopORZi0ni+CvrCgHQ5FyEAHRLSApuYWMmrbSwoN2Mn/7k+Gl38gJnR7yyDZk6WLXwiGod1JOWNDKGw==", + "dev": true, + "bin": { + "he": "bin/he" + } + }, + "node_modules/hmac-drbg": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/hmac-drbg/-/hmac-drbg-1.0.1.tgz", + "integrity": "sha1-0nRXAQJabHdabFRXk+1QL8DGSaE=", + "dev": true, + "dependencies": { + "hash.js": "^1.0.3", + "minimalistic-assert": "^1.0.0", + "minimalistic-crypto-utils": "^1.0.1" + } + }, + "node_modules/hpack.js": { + "version": "2.1.6", + "resolved": "https://registry.npmjs.org/hpack.js/-/hpack.js-2.1.6.tgz", + "integrity": "sha512-zJxVehUdMGIKsRaNt7apO2Gqp0BdqW5yaiGHXXmbpvxgBYVZnAql+BJb4RO5ad2MgpbZKn5G6nMnegrH1FcNYQ==", + "dev": true, + "dependencies": { + "inherits": "^2.0.1", + "obuf": "^1.0.0", + "readable-stream": "^2.0.1", + "wbuf": "^1.1.0" + } + }, + "node_modules/html-entities": { + "version": "2.5.2", + "resolved": "https://registry.npmjs.org/html-entities/-/html-entities-2.5.2.tgz", + "integrity": "sha512-K//PSRMQk4FZ78Kyau+mZurHn3FH0Vwr+H36eE0rPbeYkRRi9YxceYPhuN60UwWorxyKHhqoAJl2OFKa4BVtaA==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/mdevils" + }, + { + "type": "patreon", + "url": "https://patreon.com/mdevils" + } + ] + }, + "node_modules/html-loader": { + "version": "1.3.2", + "resolved": "https://registry.npmjs.org/html-loader/-/html-loader-1.3.2.tgz", + "integrity": "sha512-DEkUwSd0sijK5PF3kRWspYi56XP7bTNkyg5YWSzBdjaSDmvCufep5c4Vpb3PBf6lUL0YPtLwBfy9fL0t5hBAGA==", + "dev": true, + "dependencies": { + "html-minifier-terser": "^5.1.1", + "htmlparser2": "^4.1.0", + "loader-utils": "^2.0.0", + "schema-utils": "^3.0.0" + }, + "engines": { + "node": ">= 10.13.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/webpack" + }, + "peerDependencies": { + "webpack": "^4.0.0 || ^5.0.0" + } + }, + "node_modules/html-loader/node_modules/loader-utils": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/loader-utils/-/loader-utils-2.0.4.tgz", + "integrity": "sha512-xXqpXoINfFhgua9xiqD8fPFHgkoq1mmmpE92WlDbm9rNRd/EbRb+Gqf908T2DMfuHjjJlksiK2RbHVOdD/MqSw==", + "dev": true, + "dependencies": { + "big.js": "^5.2.2", + "emojis-list": "^3.0.0", + "json5": "^2.1.2" + }, + "engines": { + "node": ">=8.9.0" + } + }, + "node_modules/html-loader/node_modules/schema-utils": { + "version": "3.3.0", + "resolved": "https://registry.npmjs.org/schema-utils/-/schema-utils-3.3.0.tgz", + "integrity": "sha512-pN/yOAvcC+5rQ5nERGuwrjLlYvLTbCibnZ1I7B1LaiAz9BRBlE9GMgE/eqV30P7aJQUf7Ddimy/RsbYO/GrVGg==", + "dev": true, + "dependencies": { + "@types/json-schema": "^7.0.8", + "ajv": "^6.12.5", + "ajv-keywords": "^3.5.2" + }, + "engines": { + "node": ">= 10.13.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/webpack" + } + }, + "node_modules/html-minifier-terser": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/html-minifier-terser/-/html-minifier-terser-5.1.1.tgz", + "integrity": "sha512-ZPr5MNObqnV/T9akshPKbVgyOqLmy+Bxo7juKCfTfnjNniTAMdy4hz21YQqoofMBJD2kdREaqPPdThoR78Tgxg==", + "dev": true, + "dependencies": { + "camel-case": "^4.1.1", + "clean-css": "^4.2.3", + "commander": "^4.1.1", + "he": "^1.2.0", + "param-case": "^3.0.3", + "relateurl": "^0.2.7", + "terser": "^4.6.3" + }, + "bin": { + "html-minifier-terser": "cli.js" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/html-minifier-terser/node_modules/clean-css": { + "version": "4.2.4", + "resolved": "https://registry.npmjs.org/clean-css/-/clean-css-4.2.4.tgz", + "integrity": "sha512-EJUDT7nDVFDvaQgAo2G/PJvxmp1o/c6iXLbswsBbUFXi1Nr+AjA2cKmfbKDMjMvzEe75g3P6JkaDDAKk96A85A==", + "dev": true, + "dependencies": { + "source-map": "~0.6.0" + }, + "engines": { + "node": ">= 4.0" + } + }, + "node_modules/html-minifier-terser/node_modules/commander": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/commander/-/commander-4.1.1.tgz", + "integrity": "sha512-NOKm8xhkzAjzFx8B2v5OAHT+u5pRQc2UCa2Vq9jYL/31o2wi9mxBA7LIFs3sV5VSC49z6pEhfbMULvShKj26WA==", + "dev": true, + "engines": { + "node": ">= 6" + } + }, + "node_modules/html-minifier-terser/node_modules/terser": { + "version": "4.8.1", + "resolved": "https://registry.npmjs.org/terser/-/terser-4.8.1.tgz", + "integrity": "sha512-4GnLC0x667eJG0ewJTa6z/yXrbLGv80D9Ru6HIpCQmO+Q4PfEtBFi0ObSckqwL6VyQv/7ENJieXHo2ANmdQwgw==", + "dev": true, + "dependencies": { + "commander": "^2.20.0", + "source-map": "~0.6.1", + "source-map-support": "~0.5.12" + }, + "bin": { + "terser": "bin/terser" + }, + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/html-minifier-terser/node_modules/terser/node_modules/commander": { + "version": "2.20.3", + "resolved": "https://registry.npmjs.org/commander/-/commander-2.20.3.tgz", + "integrity": "sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ==", + "dev": true + }, + "node_modules/htmlparser2": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/htmlparser2/-/htmlparser2-4.1.0.tgz", + "integrity": "sha512-4zDq1a1zhE4gQso/c5LP1OtrhYTncXNSpvJYtWJBtXAETPlMfi3IFNjGuQbYLuVY4ZR0QMqRVvo4Pdy9KLyP8Q==", + "dev": true, + "dependencies": { + "domelementtype": "^2.0.1", + "domhandler": "^3.0.0", + "domutils": "^2.0.0", + "entities": "^2.0.0" + } + }, + "node_modules/http-deceiver": { + "version": "1.2.7", + "resolved": "https://registry.npmjs.org/http-deceiver/-/http-deceiver-1.2.7.tgz", + "integrity": "sha512-LmpOGxTfbpgtGVxJrj5k7asXHCgNZp5nLfp+hWc8QQRqtb7fUy6kRY3BO1h9ddF6yIPYUARgxGOwB42DnxIaNw==", + "dev": true + }, + "node_modules/http-errors": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/http-errors/-/http-errors-2.0.0.tgz", + "integrity": "sha512-FtwrG/euBzaEjYeRqOgly7G0qviiXoJWnvEH2Z1plBdXgbyjv34pHTSb9zoeHMyDy33+DWy5Wt9Wo+TURtOYSQ==", + "dev": true, + "dependencies": { + "depd": "2.0.0", + "inherits": "2.0.4", + "setprototypeof": "1.2.0", + "statuses": "2.0.1", + "toidentifier": "1.0.1" + }, + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/http-parser-js": { + "version": "0.5.8", + "resolved": "https://registry.npmjs.org/http-parser-js/-/http-parser-js-0.5.8.tgz", + "integrity": "sha512-SGeBX54F94Wgu5RH3X5jsDtf4eHyRogWX1XGT3b4HuW3tQPM4AaBzoUji/4AAJNXCEOWZ5O0DgZmJw1947gD5Q==", + "dev": true + }, + "node_modules/http-proxy": { + "version": "1.18.1", + "resolved": "https://registry.npmjs.org/http-proxy/-/http-proxy-1.18.1.tgz", + "integrity": "sha512-7mz/721AbnJwIVbnaSv1Cz3Am0ZLT/UBwkC92VlxhXv/k/BBQfM2fXElQNC27BVGr0uwUpplYPQM9LnaBMR5NQ==", + "dev": true, + "dependencies": { + "eventemitter3": "^4.0.0", + "follow-redirects": "^1.0.0", + "requires-port": "^1.0.0" + }, + "engines": { + "node": ">=8.0.0" + } + }, + "node_modules/http-proxy-middleware": { + "version": "2.0.6", + "resolved": "https://registry.npmjs.org/http-proxy-middleware/-/http-proxy-middleware-2.0.6.tgz", + "integrity": "sha512-ya/UeJ6HVBYxrgYotAZo1KvPWlgB48kUJLDePFeneHsVujFaW5WNj2NgWCAE//B1Dl02BIfYlpNgBy8Kf8Rjmw==", + "dev": true, + "dependencies": { + "@types/http-proxy": "^1.17.8", + "http-proxy": "^1.18.1", + "is-glob": "^4.0.1", + "is-plain-obj": "^3.0.0", + "micromatch": "^4.0.2" + }, + "engines": { + "node": ">=12.0.0" + }, + "peerDependencies": { + "@types/express": "^4.17.13" + }, + "peerDependenciesMeta": { + "@types/express": { + "optional": true + } + } + }, + "node_modules/https-browserify": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/https-browserify/-/https-browserify-1.0.0.tgz", + "integrity": "sha1-7AbBDgo0wPL68Zn3/X/Hj//QPHM=", + "dev": true + }, + "node_modules/human-signals": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/human-signals/-/human-signals-2.1.0.tgz", + "integrity": "sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw==", + "dev": true, + "engines": { + "node": ">=10.17.0" + } + }, + "node_modules/iconv-lite": { + "version": "0.4.24", + "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.24.tgz", + "integrity": "sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA==", + "dev": true, + "dependencies": { + "safer-buffer": ">= 2.1.2 < 3" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/icss-utils": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/icss-utils/-/icss-utils-5.1.0.tgz", + "integrity": "sha512-soFhflCVWLfRNOPU3iv5Z9VUdT44xFRbzjLsEzSr5AQmgqPMTHdU3PMT1Cf1ssx8fLNJDA1juftYl+PUcv3MqA==", + "dev": true, + "engines": { + "node": "^10 || ^12 || >= 14" + }, + "peerDependencies": { + "postcss": "^8.1.0" + } + }, + "node_modules/ieee754": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/ieee754/-/ieee754-1.2.1.tgz", + "integrity": "sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ] + }, + "node_modules/ignore": { + "version": "5.3.1", + "resolved": "https://registry.npmjs.org/ignore/-/ignore-5.3.1.tgz", + "integrity": "sha512-5Fytz/IraMjqpwfd34ke28PTVMjZjJG2MPn5t7OE4eUCUNf8BAa7b5WUS9/Qvr6mwOQS7Mk6vdsMno5he+T8Xw==", + "dev": true, + "engines": { + "node": ">= 4" + } + }, + "node_modules/imagemin": { + "version": "7.0.1", + "resolved": "https://registry.npmjs.org/imagemin/-/imagemin-7.0.1.tgz", + "integrity": "sha512-33AmZ+xjZhg2JMCe+vDf6a9mzWukE7l+wAtesjE7KyteqqKjzxv7aVQeWnul1Ve26mWvEQqyPwl0OctNBfSR9w==", + "dev": true, + "dependencies": { + "file-type": "^12.0.0", + "globby": "^10.0.0", + "graceful-fs": "^4.2.2", + "junk": "^3.1.0", + "make-dir": "^3.0.0", + "p-pipe": "^3.0.0", + "replace-ext": "^1.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/img-loader": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/img-loader/-/img-loader-4.0.0.tgz", + "integrity": "sha512-UwRcPQdwdOyEHyCxe1V9s9YFwInwEWCpoO+kJGfIqDrBDqA8jZUsEZTxQ0JteNPGw/Gupmwesk2OhLTcnw6tnQ==", + "dev": true, + "dependencies": { + "loader-utils": "^1.1.0" + }, + "engines": { + "node": ">=12" + }, + "peerDependencies": { + "imagemin": "^5.0.0 || ^6.0.0 || ^7.0.0 || ^8.0.0" + } + }, + "node_modules/immutable": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/immutable/-/immutable-4.0.0.tgz", + "integrity": "sha512-zIE9hX70qew5qTUjSS7wi1iwj/l7+m54KWU247nhM3v806UdGj1yDndXj+IOYxxtW9zyLI+xqFNZjTuDaLUqFw==", + "dev": true + }, + "node_modules/import-fresh": { + "version": "3.3.0", + "resolved": "https://registry.npmjs.org/import-fresh/-/import-fresh-3.3.0.tgz", + "integrity": "sha512-veYYhQa+D1QBKznvhUHxb8faxlrwUnxseDAbAp457E0wLNio2bOSKnjYDhMj+YiAq61xrMGhQk9iXVk5FzgQMw==", + "dev": true, + "dependencies": { + "parent-module": "^1.0.0", + "resolve-from": "^4.0.0" + }, + "engines": { + "node": ">=6" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/import-local": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/import-local/-/import-local-3.1.0.tgz", + "integrity": "sha512-ASB07uLtnDs1o6EHjKpX34BKYDSqnFerfTOJL2HvMqF70LnxpjkzDB8J44oT9pu4AMPkQwf8jl6szgvNd2tRIg==", + "dev": true, + "dependencies": { + "pkg-dir": "^4.2.0", + "resolve-cwd": "^3.0.0" + }, + "bin": { + "import-local-fixture": "fixtures/cli.js" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/inflight": { + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", + "integrity": "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=", + "dev": true, + "dependencies": { + "once": "^1.3.0", + "wrappy": "1" + } + }, + "node_modules/inherits": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", + "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==", + "dev": true + }, + "node_modules/interpret": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/interpret/-/interpret-2.2.0.tgz", + "integrity": "sha512-Ju0Bz/cEia55xDwUWEa8+olFpCiQoypjnQySseKtmjNrnps3P+xfpUmGr90T7yjlVJmOtybRvPXhKMbHr+fWnw==", + "dev": true, + "engines": { + "node": ">= 0.10" + } + }, + "node_modules/ipaddr.js": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/ipaddr.js/-/ipaddr.js-2.2.0.tgz", + "integrity": "sha512-Ag3wB2o37wslZS19hZqorUnrnzSkpOVy+IiiDEiTqNubEYpYuHWIf6K4psgN2ZWKExS4xhVCrRVfb/wfW8fWJA==", + "dev": true, + "engines": { + "node": ">= 10" + } + }, + "node_modules/is-arrayish": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/is-arrayish/-/is-arrayish-0.2.1.tgz", + "integrity": "sha512-zz06S8t0ozoDXMG+ube26zeCTNXcKIPJZJi8hBrF4idCLms4CG9QtK7qBl1boi5ODzFpjswb5JPmHCbMpjaYzg==", + "dev": true + }, + "node_modules/is-binary-path": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz", + "integrity": "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==", + "dev": true, + "dependencies": { + "binary-extensions": "^2.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/is-buffer": { + "version": "1.1.6", + "resolved": "https://registry.npmjs.org/is-buffer/-/is-buffer-1.1.6.tgz", + "integrity": "sha512-NcdALwpXkTm5Zvvbk7owOUSvVvBKDgKP5/ewfXEznmQFfs4ZRmanOeKBTjRVjka3QFoN6XJ+9F3USqfHqTaU5w==", + "dev": true + }, + "node_modules/is-core-module": { + "version": "2.8.1", + "resolved": "https://registry.npmjs.org/is-core-module/-/is-core-module-2.8.1.tgz", + "integrity": "sha512-SdNCUs284hr40hFTFP6l0IfZ/RSrMXF3qgoRHd3/79unUTvrFO/JoXwkGm+5J/Oe3E/b5GsnG330uUNgRpu1PA==", + "dev": true, + "dependencies": { + "has": "^1.0.3" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-docker": { + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/is-docker/-/is-docker-2.2.1.tgz", + "integrity": "sha512-F+i2BKsFrH66iaUFc0woD8sLy8getkwTwtOBjvs56Cx4CgJDeKQeqfz8wAYiSb8JOprWhHH5p77PbmYCvvUuXQ==", + "dev": true, + "bin": { + "is-docker": "cli.js" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/is-extglob": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", + "integrity": "sha1-qIwCU1eR8C7TfHahueqXc8gz+MI=", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/is-fullwidth-code-point": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", + "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/is-glob": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.3.tgz", + "integrity": "sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==", + "dev": true, + "dependencies": { + "is-extglob": "^2.1.1" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/is-number": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", + "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==", + "dev": true, + "engines": { + "node": ">=0.12.0" + } + }, + "node_modules/is-plain-obj": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/is-plain-obj/-/is-plain-obj-3.0.0.tgz", + "integrity": "sha512-gwsOE28k+23GP1B6vFl1oVh/WOzmawBrKwo5Ev6wMKzPkaXaCDIQKzLnvsA42DRlbVTWorkgTKIviAKCWkfUwA==", + "dev": true, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/is-plain-object": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/is-plain-object/-/is-plain-object-2.0.4.tgz", + "integrity": "sha512-h5PpgXkWitc38BBMYawTYMWJHFZJVnBquFE57xFpjB8pJFiF6gZ+bU+WyI/yqXiFR5mdLsgYNaPe8uao6Uv9Og==", + "dev": true, + "dependencies": { + "isobject": "^3.0.1" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/is-stream": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-2.0.1.tgz", + "integrity": "sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg==", + "dev": true, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/is-wsl": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/is-wsl/-/is-wsl-2.2.0.tgz", + "integrity": "sha512-fKzAra0rGJUUBwGBgNkHZuToZcn+TtXHpeCgmkMJMMYx1sQDYaCSyjJBSCa2nH1DGm7s3n1oBnohoVTBaN7Lww==", + "dev": true, + "dependencies": { + "is-docker": "^2.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/isarray": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", + "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=", + "dev": true + }, + "node_modules/isexe": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", + "integrity": "sha1-6PvzdNxVb/iUehDcsFctYz8s+hA=", + "dev": true + }, + "node_modules/isobject": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/isobject/-/isobject-3.0.1.tgz", + "integrity": "sha1-TkMekrEalzFjaqH5yNHMvP2reN8=", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/jest-worker": { + "version": "27.5.1", + "resolved": "https://registry.npmjs.org/jest-worker/-/jest-worker-27.5.1.tgz", + "integrity": "sha512-7vuh85V5cdDofPyxn58nrPjBktZo0u9x1g8WtjQol+jZDaE+fhN+cIvTj11GndBnMnyfrUOG1sZQxCdjKh+DKg==", + "dev": true, + "dependencies": { + "@types/node": "*", + "merge-stream": "^2.0.0", + "supports-color": "^8.0.0" + }, + "engines": { + "node": ">= 10.13.0" + } + }, + "node_modules/jest-worker/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-worker/node_modules/supports-color": { + "version": "8.1.1", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-8.1.1.tgz", + "integrity": "sha512-MpUEN2OodtUzxvKQl72cUF7RQ5EiHsGvSsVG0ia9c5RbWGL2CI4C7EpPS8UTBIplnlzZiNuV56w+FuNxy3ty2Q==", + "dev": true, + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/supports-color?sponsor=1" + } + }, + "node_modules/jquery": { + "version": "3.6.0", + "resolved": "https://registry.npmjs.org/jquery/-/jquery-3.6.0.tgz", + "integrity": "sha512-JVzAR/AjBvVt2BmYhxRCSYysDsPcssdmTFnzyLEts9qNwmjmu4JTAMYubEfwVOSwpQ1I1sKKFcxhZCI2buerfw==", + "dev": true + }, + "node_modules/js-tokens": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", + "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==", + "dev": true + }, + "node_modules/jsesc": { + "version": "2.5.2", + "resolved": "https://registry.npmjs.org/jsesc/-/jsesc-2.5.2.tgz", + "integrity": "sha512-OYu7XEzjkCQ3C5Ps3QIZsQfNpqoJyZZA99wd9aWd05NCtC5pWOkShK2mkL6HXQR6/Cy2lbNdPlZBpuQHXE63gA==", + "dev": true, + "bin": { + "jsesc": "bin/jsesc" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/json-parse-even-better-errors": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/json-parse-even-better-errors/-/json-parse-even-better-errors-2.3.1.tgz", + "integrity": "sha512-xyFwyhro/JEof6Ghe2iz2NcXoj2sloNsWr/XsERDK/oiPCfaNhl5ONfp+jQdAZRQQ0IJWNzH9zIZF7li91kh2w==", + "dev": true + }, + "node_modules/json-schema-traverse": { + "version": "0.4.1", + "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz", + "integrity": "sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==", + "dev": true + }, + "node_modules/json5": { + "version": "2.2.3", + "resolved": "https://registry.npmjs.org/json5/-/json5-2.2.3.tgz", + "integrity": "sha512-XmOWe7eyHYH14cLdVPoyg+GOH3rYX++KpzrylJwSW98t3Nk+U8XOl8FWKOgwtzdb8lXGf6zYwDUzeHMWfxasyg==", + "dev": true, + "bin": { + "json5": "lib/cli.js" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/jsonfile": { + "version": "6.1.0", + "resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-6.1.0.tgz", + "integrity": "sha512-5dgndWOriYSm5cnYaJNhalLNDKOqFwyDB/rr1E9ZsGciGvKPs8R2xYGCacuf3z6K1YKDz182fd+fY3cn3pMqXQ==", + "dev": true, + "dependencies": { + "universalify": "^2.0.0" + }, + "optionalDependencies": { + "graceful-fs": "^4.1.6" + } + }, + "node_modules/junk": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/junk/-/junk-3.1.0.tgz", + "integrity": "sha512-pBxcB3LFc8QVgdggvZWyeys+hnrNWg4OcZIU/1X59k5jQdLBlCsYGRQaz234SqoRLTCgMH00fY0xRJH+F9METQ==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/klona": { + "version": "2.0.6", + "resolved": "https://registry.npmjs.org/klona/-/klona-2.0.6.tgz", + "integrity": "sha512-dhG34DXATL5hSxJbIexCft8FChFXtmskoZYnoPWjXQuebWYCNkVeV3KkGegCK9CP1oswI/vQibS2GY7Em/sJJA==", + "dev": true, + "engines": { + "node": ">= 8" + } + }, + "node_modules/laravel-mix": { + "version": "6.0.49", + "resolved": "https://registry.npmjs.org/laravel-mix/-/laravel-mix-6.0.49.tgz", + "integrity": "sha512-bBMFpFjp26XfijPvY5y9zGKud7VqlyOE0OWUcPo3vTBY5asw8LTjafAbee1dhfLz6PWNqDziz69CP78ELSpfKw==", + "dev": true, + "dependencies": { + "@babel/core": "^7.15.8", + "@babel/plugin-proposal-object-rest-spread": "^7.15.6", + "@babel/plugin-syntax-dynamic-import": "^7.8.3", + "@babel/plugin-transform-runtime": "^7.15.8", + "@babel/preset-env": "^7.15.8", + "@babel/runtime": "^7.15.4", + "@types/babel__core": "^7.1.16", + "@types/clean-css": "^4.2.5", + "@types/imagemin-gifsicle": "^7.0.1", + "@types/imagemin-mozjpeg": "^8.0.1", + "@types/imagemin-optipng": "^5.2.1", + "@types/imagemin-svgo": "^8.0.0", + "autoprefixer": "^10.4.0", + "babel-loader": "^8.2.3", + "chalk": "^4.1.2", + "chokidar": "^3.5.2", + "clean-css": "^5.2.4", + "cli-table3": "^0.6.0", + "collect.js": "^4.28.5", + "commander": "^7.2.0", + "concat": "^1.0.3", + "css-loader": "^5.2.6", + "cssnano": "^5.0.8", + "dotenv": "^10.0.0", + "dotenv-expand": "^5.1.0", + "file-loader": "^6.2.0", + "fs-extra": "^10.0.0", + "glob": "^7.2.0", + "html-loader": "^1.3.2", + "imagemin": "^7.0.1", + "img-loader": "^4.0.0", + "lodash": "^4.17.21", + "md5": "^2.3.0", + "mini-css-extract-plugin": "^1.6.2", + "node-libs-browser": "^2.2.1", + "postcss-load-config": "^3.1.0", + "postcss-loader": "^6.2.0", + "semver": "^7.3.5", + "strip-ansi": "^6.0.0", + "style-loader": "^2.0.0", + "terser": "^5.9.0", + "terser-webpack-plugin": "^5.2.4", + "vue-style-loader": "^4.1.3", + "webpack": "^5.60.0", + "webpack-cli": "^4.9.1", + "webpack-dev-server": "^4.7.3", + "webpack-merge": "^5.8.0", + "webpack-notifier": "^1.14.1", + "webpackbar": "^5.0.0-3", + "yargs": "^17.2.1" + }, + "bin": { + "laravel-mix": "bin/cli.js", + "mix": "bin/cli.js" + }, + "engines": { + "node": ">=12.14.0" + }, + "peerDependencies": { + "@babel/core": "^7.15.8", + "@babel/plugin-proposal-object-rest-spread": "^7.15.6", + "@babel/plugin-syntax-dynamic-import": "^7.8.3", + "@babel/plugin-transform-runtime": "^7.15.8", + "@babel/preset-env": "^7.15.8", + "postcss": "^8.3.11", + "webpack": "^5.60.0", + "webpack-cli": "^4.9.1" + } + }, + "node_modules/laravel-mix/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dev": true, + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/laravel-mix/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dev": true, + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/laravel-mix/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/laravel-mix/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true + }, + "node_modules/laravel-mix/node_modules/commander": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/commander/-/commander-7.2.0.tgz", + "integrity": "sha512-QrWXB+ZQSVPmIWIhtEO9H+gwHaMGYiF5ChvoJ+K9ZGHG/sVsa6yiesAD1GC/x46sET00Xlwo1u49RVVVzvcSkw==", + "dev": true, + "engines": { + "node": ">= 10" + } + }, + "node_modules/laravel-mix/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/laravel-mix/node_modules/semver": { + "version": "7.6.2", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.6.2.tgz", + "integrity": "sha512-FNAIBWCx9qcRhoHcgcJ0gvU7SN1lYU2ZXuSfl04bSC5OpvDHFyJCjdNHomPXxjQlCBU67YW64PzY7/VIEH7F2w==", + "dev": true, + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/laravel-mix/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dev": true, + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/launch-editor": { + "version": "2.7.0", + "resolved": "https://registry.npmjs.org/launch-editor/-/launch-editor-2.7.0.tgz", + "integrity": "sha512-KAc66u6LxWL8MifQ94oG3YGKYWDwz/Gi0T15lN//GaQoZe08vQGFJxrXkPAeu50UXgvJPPaRKVGuP1TRUm/aHQ==", + "dev": true, + "dependencies": { + "picocolors": "^1.0.0", + "shell-quote": "^1.8.1" + } + }, + "node_modules/lilconfig": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/lilconfig/-/lilconfig-2.1.0.tgz", + "integrity": "sha512-utWOt/GHzuUxnLKxB6dk81RoOeoNeHgbrXiuGk4yyF5qlRz+iIVWu56E2fqGHFrXz0QNUhLB/8nKqvRH66JKGQ==", + "dev": true, + "engines": { + "node": ">=10" + } + }, + "node_modules/lines-and-columns": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/lines-and-columns/-/lines-and-columns-1.2.4.tgz", + "integrity": "sha512-7ylylesZQ/PV29jhEDl3Ufjo6ZX7gCqJr5F7PKrqc93v7fzSymt1BpwEU8nAUXs8qzzvqhbjhK5QZg6Mt/HkBg==", + "dev": true + }, + "node_modules/linguist-languages": { + "version": "7.27.0", + "resolved": "https://registry.npmjs.org/linguist-languages/-/linguist-languages-7.27.0.tgz", + "integrity": "sha512-Wzx/22c5Jsv2ag+uKy+ITanGA5hzvBZngrNGDXLTC7ZjGM6FLCYGgomauTkxNJeP9of353OM0pWqngYA180xgw==", + "dev": true + }, + "node_modules/loader-runner": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/loader-runner/-/loader-runner-4.3.0.tgz", + "integrity": "sha512-3R/1M+yS3j5ou80Me59j7F9IMs4PXs3VqRrm0TU3AbKPxlmpoY1TNscJV/oGJXo8qCatFGTfDbY6W6ipGOYXfg==", + "dev": true, + "engines": { + "node": ">=6.11.5" + } + }, + "node_modules/loader-utils": { + "version": "1.4.2", + "resolved": "https://registry.npmjs.org/loader-utils/-/loader-utils-1.4.2.tgz", + "integrity": "sha512-I5d00Pd/jwMD2QCduo657+YM/6L3KZu++pmX9VFncxaxvHcru9jx1lBaFft+r4Mt2jK0Yhp41XlRAihzPxHNCg==", + "dev": true, + "dependencies": { + "big.js": "^5.2.2", + "emojis-list": "^3.0.0", + "json5": "^1.0.1" + }, + "engines": { + "node": ">=4.0.0" + } + }, + "node_modules/loader-utils/node_modules/json5": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/json5/-/json5-1.0.2.tgz", + "integrity": "sha512-g1MWMLBiz8FKi1e4w0UyVL3w+iJceWAFBAaBnnGKOpNa5f8TLktkbre1+s6oICydWAm+HRUGTmI+//xv2hvXYA==", + "dev": true, + "dependencies": { + "minimist": "^1.2.0" + }, + "bin": { + "json5": "lib/cli.js" + } + }, + "node_modules/locate-path": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-5.0.0.tgz", + "integrity": "sha512-t7hw9pI+WvuwNJXwk5zVHpyhIqzg2qTlklJOf0mVxGSbe3Fp2VieZcduNYjaLDoy6p9uGpQEGWG87WpMKlNq8g==", + "dev": true, + "dependencies": { + "p-locate": "^4.1.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/lodash": { + "version": "4.17.21", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.21.tgz", + "integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==", + "dev": true + }, + "node_modules/lodash.debounce": { + "version": "4.0.8", + "resolved": "https://registry.npmjs.org/lodash.debounce/-/lodash.debounce-4.0.8.tgz", + "integrity": "sha1-gteb/zCmfEAF/9XiUVMArZyk168=", + "dev": true + }, + "node_modules/lodash.memoize": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/lodash.memoize/-/lodash.memoize-4.1.2.tgz", + "integrity": "sha512-t7j+NzmgnQzTAYXcsHYLgimltOV1MXHtlOWf6GjL9Kj8GK5FInw5JotxvbOs+IvV1/Dzo04/fCGfLVs7aXb4Ag==", + "dev": true + }, + "node_modules/lodash.uniq": { + "version": "4.5.0", + "resolved": "https://registry.npmjs.org/lodash.uniq/-/lodash.uniq-4.5.0.tgz", + "integrity": "sha512-xfBaXQd9ryd9dlSDvnvI0lvxfLJlYAZzXomUYzLKtUeOQvOP5piqAWuGtrhWeqaXK9hhoM/iyJc5AV+XfsX3HQ==", + "dev": true + }, + "node_modules/lower-case": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/lower-case/-/lower-case-2.0.2.tgz", + "integrity": "sha512-7fm3l3NAF9WfN6W3JOmf5drwpVqX78JtoGJ3A6W0a6ZnldM41w2fV5D490psKFTpMds8TJse/eHLFFsNHHjHgg==", + "dev": true, + "dependencies": { + "tslib": "^2.0.3" + } + }, + "node_modules/make-dir": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/make-dir/-/make-dir-3.1.0.tgz", + "integrity": "sha512-g3FeP20LNwhALb/6Cz6Dd4F2ngze0jz7tbzrD2wAV+o9FeNHe4rL+yK2md0J/fiSf1sa1ADhXqi5+oVwOM/eGw==", + "dev": true, + "dependencies": { + "semver": "^6.0.0" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/map-age-cleaner": { + "version": "0.1.3", + "resolved": "https://registry.npmjs.org/map-age-cleaner/-/map-age-cleaner-0.1.3.tgz", + "integrity": "sha512-bJzx6nMoP6PDLPBFmg7+xRKeFZvFboMrGlxmNj9ClvX53KrmvM5bXFXEWjbz4cz1AFn+jWJ9z/DJSz7hrs0w3w==", + "dev": true, + "dependencies": { + "p-defer": "^1.0.0" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/md5": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/md5/-/md5-2.3.0.tgz", + "integrity": "sha512-T1GITYmFaKuO91vxyoQMFETst+O71VUPEU3ze5GNzDm0OWdP8v1ziTaAEPUr/3kLsY3Sftgz242A1SetQiDL7g==", + "dev": true, + "dependencies": { + "charenc": "0.0.2", + "crypt": "0.0.2", + "is-buffer": "~1.1.6" + } + }, + "node_modules/md5.js": { + "version": "1.3.5", + "resolved": "https://registry.npmjs.org/md5.js/-/md5.js-1.3.5.tgz", + "integrity": "sha512-xitP+WxNPcTTOgnTJcrhM0xvdPepipPSf3I8EIpGKeFLjt3PlJLIDG3u8EX53ZIubkb+5U2+3rELYpEhHhzdkg==", + "dev": true, + "dependencies": { + "hash-base": "^3.0.0", + "inherits": "^2.0.1", + "safe-buffer": "^5.1.2" + } + }, + "node_modules/mdn-data": { + "version": "2.0.14", + "resolved": "https://registry.npmjs.org/mdn-data/-/mdn-data-2.0.14.tgz", + "integrity": "sha512-dn6wd0uw5GsdswPFfsgMp5NSB0/aDe6fK94YJV/AJDYXL6HVLWBsxeq7js7Ad+mU2K9LAlwpk6kN2D5mwCPVow==", + "dev": true + }, + "node_modules/media-typer": { + "version": "0.3.0", + "resolved": "https://registry.npmjs.org/media-typer/-/media-typer-0.3.0.tgz", + "integrity": "sha512-dq+qelQ9akHpcOl/gUVRTxVIOkAJ1wR3QAvb4RsVjS8oVoFjDGTc679wJYmUmknUF5HwMLOgb5O+a3KxfWapPQ==", + "dev": true, + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/mem": { + "version": "8.1.1", + "resolved": "https://registry.npmjs.org/mem/-/mem-8.1.1.tgz", + "integrity": "sha512-qFCFUDs7U3b8mBDPyz5EToEKoAkgCzqquIgi9nkkR9bixxOVOre+09lbuH7+9Kn2NFpm56M3GUWVbU2hQgdACA==", + "dev": true, + "dependencies": { + "map-age-cleaner": "^0.1.3", + "mimic-fn": "^3.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sindresorhus/mem?sponsor=1" + } + }, + "node_modules/memfs": { + "version": "3.5.3", + "resolved": "https://registry.npmjs.org/memfs/-/memfs-3.5.3.tgz", + "integrity": "sha512-UERzLsxzllchadvbPs5aolHh65ISpKpM+ccLbOJ8/vvpBKmAWf+la7dXFy7Mr0ySHbdHrFv5kGFCUHHe6GFEmw==", + "dev": true, + "dependencies": { + "fs-monkey": "^1.0.4" + }, + "engines": { + "node": ">= 4.0.0" + } + }, + "node_modules/merge-descriptors": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-1.0.1.tgz", + "integrity": "sha512-cCi6g3/Zr1iqQi6ySbseM1Xvooa98N0w31jzUYrXPX2xqObmFGHJ0tQ5u74H3mVh7wLouTseZyYIq39g8cNp1w==", + "dev": true + }, + "node_modules/merge-stream": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/merge-stream/-/merge-stream-2.0.0.tgz", + "integrity": "sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w==", + "dev": true + }, + "node_modules/merge2": { + "version": "1.4.1", + "resolved": "https://registry.npmjs.org/merge2/-/merge2-1.4.1.tgz", + "integrity": "sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg==", + "dev": true, + "engines": { + "node": ">= 8" + } + }, + "node_modules/methods": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/methods/-/methods-1.1.2.tgz", + "integrity": "sha512-iclAHeNqNm68zFtnZ0e+1L2yUIdvzNoauKU4WBA3VvH/vPFieF7qfRlwUZU+DA9P9bPXIS90ulxoUoCH23sV2w==", + "dev": true, + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/micromatch": { + "version": "4.0.7", + "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-4.0.7.tgz", + "integrity": "sha512-LPP/3KorzCwBxfeUuZmaR6bG2kdeHSbe0P2tY3FLRU4vYrjYz5hI4QZwV0njUx3jeuKe67YukQ1LSPZBKDqO/Q==", + "dev": true, + "dependencies": { + "braces": "^3.0.3", + "picomatch": "^2.3.1" + }, + "engines": { + "node": ">=8.6" + } + }, + "node_modules/miller-rabin": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/miller-rabin/-/miller-rabin-4.0.1.tgz", + "integrity": "sha512-115fLhvZVqWwHPbClyntxEVfVDfl9DLLTuJvq3g2O/Oxi8AiNouAHvDSzHS0viUJc+V5vm3eq91Xwqn9dp4jRA==", + "dev": true, + "dependencies": { + "bn.js": "^4.0.0", + "brorand": "^1.0.1" + }, + "bin": { + "miller-rabin": "bin/miller-rabin" + } + }, + "node_modules/miller-rabin/node_modules/bn.js": { + "version": "4.12.0", + "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-4.12.0.tgz", + "integrity": "sha512-c98Bf3tPniI+scsdk237ku1Dc3ujXQTSgyiPUDEOe7tRkhrqridvh8klBv0HCEso1OLOYcHuCv/cS6DNxKH+ZA==", + "dev": true + }, + "node_modules/mime": { + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/mime/-/mime-1.6.0.tgz", + "integrity": "sha512-x0Vn8spI+wuJ1O6S7gnbaQg8Pxh4NNHb7KSINmEWKiPE4RKOplvijn+NkmYmmRgP68mc70j2EbeTFRsrswaQeg==", + "dev": true, + "bin": { + "mime": "cli.js" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/mime-db": { + "version": "1.52.0", + "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.52.0.tgz", + "integrity": "sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==", + "dev": true, + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/mime-types": { + "version": "2.1.35", + "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.35.tgz", + "integrity": "sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw==", + "dev": true, + "dependencies": { + "mime-db": "1.52.0" + }, + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/mimic-fn": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/mimic-fn/-/mimic-fn-3.1.0.tgz", + "integrity": "sha512-Ysbi9uYW9hFyfrThdDEQuykN4Ey6BuwPD2kpI5ES/nFTDn/98yxYNLZJcgUAKPT/mcrLLKaGzJR9YVxJrIdASQ==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/mini-css-extract-plugin": { + "version": "1.6.2", + "resolved": "https://registry.npmjs.org/mini-css-extract-plugin/-/mini-css-extract-plugin-1.6.2.tgz", + "integrity": "sha512-WhDvO3SjGm40oV5y26GjMJYjd2UMqrLAGKy5YS2/3QKJy2F7jgynuHTir/tgUUOiNQu5saXHdc8reo7YuhhT4Q==", + "dev": true, + "dependencies": { + "loader-utils": "^2.0.0", + "schema-utils": "^3.0.0", + "webpack-sources": "^1.1.0" + }, + "engines": { + "node": ">= 10.13.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/webpack" + }, + "peerDependencies": { + "webpack": "^4.4.0 || ^5.0.0" + } + }, + "node_modules/mini-css-extract-plugin/node_modules/loader-utils": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/loader-utils/-/loader-utils-2.0.4.tgz", + "integrity": "sha512-xXqpXoINfFhgua9xiqD8fPFHgkoq1mmmpE92WlDbm9rNRd/EbRb+Gqf908T2DMfuHjjJlksiK2RbHVOdD/MqSw==", + "dev": true, + "dependencies": { + "big.js": "^5.2.2", + "emojis-list": "^3.0.0", + "json5": "^2.1.2" + }, + "engines": { + "node": ">=8.9.0" + } + }, + "node_modules/mini-css-extract-plugin/node_modules/schema-utils": { + "version": "3.3.0", + "resolved": "https://registry.npmjs.org/schema-utils/-/schema-utils-3.3.0.tgz", + "integrity": "sha512-pN/yOAvcC+5rQ5nERGuwrjLlYvLTbCibnZ1I7B1LaiAz9BRBlE9GMgE/eqV30P7aJQUf7Ddimy/RsbYO/GrVGg==", + "dev": true, + "dependencies": { + "@types/json-schema": "^7.0.8", + "ajv": "^6.12.5", + "ajv-keywords": "^3.5.2" + }, + "engines": { + "node": ">= 10.13.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/webpack" + } + }, + "node_modules/minimalistic-assert": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/minimalistic-assert/-/minimalistic-assert-1.0.1.tgz", + "integrity": "sha512-UtJcAD4yEaGtjPezWuO9wC4nwUnVH/8/Im3yEHQP4b67cXlD/Qr9hdITCU1xDbSEXg2XKNaP8jsReV7vQd00/A==", + "dev": true + }, + "node_modules/minimalistic-crypto-utils": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/minimalistic-crypto-utils/-/minimalistic-crypto-utils-1.0.1.tgz", + "integrity": "sha1-9sAMHAsIIkblxNmd+4x8CDsrWCo=", + "dev": true + }, + "node_modules/minimatch": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", + "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", + "dev": true, + "dependencies": { + "brace-expansion": "^1.1.7" + }, + "engines": { + "node": "*" + } + }, + "node_modules/minimist": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.8.tgz", + "integrity": "sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA==", + "dev": true, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/ms": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", + "integrity": "sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A==", + "dev": true + }, + "node_modules/multicast-dns": { + "version": "7.2.5", + "resolved": "https://registry.npmjs.org/multicast-dns/-/multicast-dns-7.2.5.tgz", + "integrity": "sha512-2eznPJP8z2BFLX50tf0LuODrpINqP1RVIm/CObbTcBRITQgmC/TjcREF1NeTBzIcR5XO/ukWo+YHOjBbFwIupg==", + "dev": true, + "dependencies": { + "dns-packet": "^5.2.2", + "thunky": "^1.0.2" + }, + "bin": { + "multicast-dns": "cli.js" + } + }, + "node_modules/nanoid": { + "version": "3.3.7", + "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.7.tgz", + "integrity": "sha512-eSRppjcPIatRIMC1U6UngP8XFcz8MQWGQdt1MTBQ7NaAmvXDfvNxbvWV3x2y6CdEUciCSsDHDQZbhYaB8QEo2g==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "bin": { + "nanoid": "bin/nanoid.cjs" + }, + "engines": { + "node": "^10 || ^12 || ^13.7 || ^14 || >=15.0.1" + } + }, + "node_modules/negotiator": { + "version": "0.6.3", + "resolved": "https://registry.npmjs.org/negotiator/-/negotiator-0.6.3.tgz", + "integrity": "sha512-+EUsqGPLsM+j/zdChZjsnX51g4XrHFOIXwfnCVPGlQk/k5giakcKsuxCObBRu6DSm9opw/O6slWbJdghQM4bBg==", + "dev": true, + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/neo-async": { + "version": "2.6.2", + "resolved": "https://registry.npmjs.org/neo-async/-/neo-async-2.6.2.tgz", + "integrity": "sha512-Yd3UES5mWCSqR+qNT93S3UoYUkqAZ9lLg8a7g9rimsWmYGK8cVToA4/sF3RrshdyV3sAGMXVUmpMYOw+dLpOuw==", + "dev": true + }, + "node_modules/next-tick": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/next-tick/-/next-tick-1.1.0.tgz", + "integrity": "sha512-CXdUiJembsNjuToQvxayPZF9Vqht7hewsvy2sOWafLvi2awflj9mOC6bHIg50orX8IJvWKY9wYQ/zB2kogPslQ==", + "dev": true + }, + "node_modules/no-case": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/no-case/-/no-case-3.0.4.tgz", + "integrity": "sha512-fgAN3jGAh+RoxUGZHTSOLJIqUc2wmoBwGR4tbpNAKmmovFoWq0OdRkb0VkldReO2a2iBT/OEulG9XSUc10r3zg==", + "dev": true, + "dependencies": { + "lower-case": "^2.0.2", + "tslib": "^2.0.3" + } + }, + "node_modules/node-forge": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/node-forge/-/node-forge-1.3.1.tgz", + "integrity": "sha512-dPEtOeMvF9VMcYV/1Wb8CPoVAXtp6MKMlcbAt4ddqmGqUJ6fQZFXkNZNkNlfevtNkGtaSoXf/vNNNSvgrdXwtA==", + "dev": true, + "engines": { + "node": ">= 6.13.0" + } + }, + "node_modules/node-libs-browser": { + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/node-libs-browser/-/node-libs-browser-2.2.1.tgz", + "integrity": "sha512-h/zcD8H9kaDZ9ALUWwlBUDo6TKF8a7qBSCSEGfjTVIYeqsioSKaAX+BN7NgiMGp6iSIXZ3PxgCu8KS3b71YK5Q==", + "dev": true, + "dependencies": { + "assert": "^1.1.1", + "browserify-zlib": "^0.2.0", + "buffer": "^4.3.0", + "console-browserify": "^1.1.0", + "constants-browserify": "^1.0.0", + "crypto-browserify": "^3.11.0", + "domain-browser": "^1.1.1", + "events": "^3.0.0", + "https-browserify": "^1.0.0", + "os-browserify": "^0.3.0", + "path-browserify": "0.0.1", + "process": "^0.11.10", + "punycode": "^1.2.4", + "querystring-es3": "^0.2.0", + "readable-stream": "^2.3.3", + "stream-browserify": "^2.0.1", + "stream-http": "^2.7.2", + "string_decoder": "^1.0.0", + "timers-browserify": "^2.0.4", + "tty-browserify": "0.0.0", + "url": "^0.11.0", + "util": "^0.11.0", + "vm-browserify": "^1.0.1" + } + }, + "node_modules/node-libs-browser/node_modules/punycode": { + "version": "1.4.1", + "resolved": "https://registry.npmjs.org/punycode/-/punycode-1.4.1.tgz", + "integrity": "sha1-wNWmOycYgArY4esPpSachN1BhF4=", + "dev": true + }, + "node_modules/node-notifier": { + "version": "9.0.1", + "resolved": "https://registry.npmjs.org/node-notifier/-/node-notifier-9.0.1.tgz", + "integrity": "sha512-fPNFIp2hF/Dq7qLDzSg4vZ0J4e9v60gJR+Qx7RbjbWqzPDdEqeVpEx5CFeDAELIl+A/woaaNn1fQ5nEVerMxJg==", + "dev": true, + "dependencies": { + "growly": "^1.3.0", + "is-wsl": "^2.2.0", + "semver": "^7.3.2", + "shellwords": "^0.1.1", + "uuid": "^8.3.0", + "which": "^2.0.2" + } + }, + "node_modules/node-notifier/node_modules/semver": { + "version": "7.6.2", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.6.2.tgz", + "integrity": "sha512-FNAIBWCx9qcRhoHcgcJ0gvU7SN1lYU2ZXuSfl04bSC5OpvDHFyJCjdNHomPXxjQlCBU67YW64PzY7/VIEH7F2w==", + "dev": true, + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/node-releases": { + "version": "2.0.14", + "resolved": "https://registry.npmjs.org/node-releases/-/node-releases-2.0.14.tgz", + "integrity": "sha512-y10wOWt8yZpqXmOgRo77WaHEmhYQYGNA6y421PKsKYWEK8aW+cqAphborZDhqfyKrbZEN92CN1X2KbafY2s7Yw==", + "dev": true + }, + "node_modules/normalize-path": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz", + "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/normalize-range": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/normalize-range/-/normalize-range-0.1.2.tgz", + "integrity": "sha512-bdok/XvKII3nUpklnV6P2hxtMNrCboOjAcyBuQnWEhO665FwrSNRxU+AqpsyvO6LgGYPspN+lu5CLtw4jPRKNA==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/normalize-url": { + "version": "6.1.0", + "resolved": "https://registry.npmjs.org/normalize-url/-/normalize-url-6.1.0.tgz", + "integrity": "sha512-DlL+XwOy3NxAQ8xuC0okPgK46iuVNAK01YN7RueYBqqFeGsBjV9XmCAzAdgt+667bCl5kPh9EqKKDwnaPG1I7A==", + "dev": true, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/npm-run-path": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/npm-run-path/-/npm-run-path-4.0.1.tgz", + "integrity": "sha512-S48WzZW777zhNIrn7gxOlISNAqi9ZC/uQFnRdbeIHhZhCA6UqpkOT8T1G7BvfdgP4Er8gF4sUbaS0i7QvIfCWw==", + "dev": true, + "dependencies": { + "path-key": "^3.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/nth-check": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/nth-check/-/nth-check-2.1.1.tgz", + "integrity": "sha512-lqjrjmaOoAnWfMmBPL+XNnynZh2+swxiX3WUE0s4yEHI6m+AwrK2UZOimIRl3X/4QctVqS8AiZjFqyOGrMXb/w==", + "dev": true, + "dependencies": { + "boolbase": "^1.0.0" + }, + "funding": { + "url": "https://github.com/fb55/nth-check?sponsor=1" + } + }, + "node_modules/object-assign": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz", + "integrity": "sha1-IQmtx5ZYh8/AXLvUQsrIv7s2CGM=", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/object-inspect": { + "version": "1.13.1", + "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.13.1.tgz", + "integrity": "sha512-5qoj1RUiKOMsCCNLV1CBiPYE10sziTsnmNxkAI/rZhiD63CF7IqdFGC/XzjWjpSgLf0LxXX3bDFIh0E18f6UhQ==", + "dev": true, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/object-keys": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/object-keys/-/object-keys-1.1.1.tgz", + "integrity": "sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA==", + "dev": true, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/object.assign": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/object.assign/-/object.assign-4.1.2.tgz", + "integrity": "sha512-ixT2L5THXsApyiUPYKmW+2EHpXXe5Ii3M+f4e+aJFAHao5amFRW6J0OO6c/LU8Be47utCx2GL89hxGB6XSmKuQ==", + "dev": true, + "dependencies": { + "call-bind": "^1.0.0", + "define-properties": "^1.1.3", + "has-symbols": "^1.0.1", + "object-keys": "^1.1.1" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/obuf": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/obuf/-/obuf-1.1.2.tgz", + "integrity": "sha512-PX1wu0AmAdPqOL1mWhqmlOd8kOIZQwGZw6rh7uby9fTc5lhaOWFLX3I6R1hrF9k3zUY40e6igsLGkDXK92LJNg==", + "dev": true + }, + "node_modules/on-finished": { + "version": "2.4.1", + "resolved": "https://registry.npmjs.org/on-finished/-/on-finished-2.4.1.tgz", + "integrity": "sha512-oVlzkg3ENAhCk2zdv7IJwd/QUD4z2RxRwpkcGY8psCVcCYZNq4wYnVWALHM+brtuJjePWiYF/ClmuDr8Ch5+kg==", + "dev": true, + "dependencies": { + "ee-first": "1.1.1" + }, + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/on-headers": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/on-headers/-/on-headers-1.0.2.tgz", + "integrity": "sha512-pZAE+FJLoyITytdqK0U5s+FIpjN0JP3OzFi/u8Rx+EV5/W+JTWGXG8xFzevE7AjBfDqHv/8vL8qQsIhHnqRkrA==", + "dev": true, + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/once": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", + "integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=", + "dev": true, + "dependencies": { + "wrappy": "1" + } + }, + "node_modules/onetime": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/onetime/-/onetime-5.1.2.tgz", + "integrity": "sha512-kbpaSSGJTWdAY5KPVeMOKXSrPtr8C8C7wodJbcsd51jRnmD+GZu8Y0VoU6Dm5Z4vWr0Ig/1NKuWRKf7j5aaYSg==", + "dev": true, + "dependencies": { + "mimic-fn": "^2.1.0" + }, + "engines": { + "node": ">=6" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/onetime/node_modules/mimic-fn": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/mimic-fn/-/mimic-fn-2.1.0.tgz", + "integrity": "sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/open": { + "version": "8.4.2", + "resolved": "https://registry.npmjs.org/open/-/open-8.4.2.tgz", + "integrity": "sha512-7x81NCL719oNbsq/3mh+hVrAWmFuEYUqrq/Iw3kUzH8ReypT9QQ0BLoJS7/G9k6N81XjW4qHWtjWwe/9eLy1EQ==", + "dev": true, + "dependencies": { + "define-lazy-prop": "^2.0.0", + "is-docker": "^2.1.1", + "is-wsl": "^2.2.0" + }, + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/os-browserify": { + "version": "0.3.0", + "resolved": "https://registry.npmjs.org/os-browserify/-/os-browserify-0.3.0.tgz", + "integrity": "sha1-hUNzx/XCMVkU/Jv8a9gjj92h7Cc=", + "dev": true + }, + "node_modules/p-defer": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/p-defer/-/p-defer-1.0.0.tgz", + "integrity": "sha512-wB3wfAxZpk2AzOfUMJNL+d36xothRSyj8EXOa4f6GMqYDN9BJaaSISbsk+wS9abmnebVw95C2Kb5t85UmpCxuw==", + "dev": true, + "engines": { + "node": ">=4" + } + }, + "node_modules/p-limit": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", + "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", + "dev": true, + "dependencies": { + "p-try": "^2.0.0" + }, + "engines": { + "node": ">=6" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/p-locate": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-4.1.0.tgz", + "integrity": "sha512-R79ZZ/0wAxKGu3oYMlz8jy/kbhsNrS7SKZ7PxEHBgJ5+F2mtFW2fK2cOtBh1cHYkQsbzFV7I+EoRKe6Yt0oK7A==", + "dev": true, + "dependencies": { + "p-limit": "^2.2.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/p-pipe": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/p-pipe/-/p-pipe-3.1.0.tgz", + "integrity": "sha512-08pj8ATpzMR0Y80x50yJHn37NF6vjrqHutASaX5LiH5npS9XPvrUmscd9MF5R4fuYRHOxQR1FfMIlF7AzwoPqw==", + "dev": true, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/p-retry": { + "version": "4.6.2", + "resolved": "https://registry.npmjs.org/p-retry/-/p-retry-4.6.2.tgz", + "integrity": "sha512-312Id396EbJdvRONlngUx0NydfrIQ5lsYu0znKVUzVvArzEIt08V1qhtyESbGVd1FGX7UKtiFp5uwKZdM8wIuQ==", + "dev": true, + "dependencies": { + "@types/retry": "0.12.0", + "retry": "^0.13.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/p-try": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/p-try/-/p-try-2.2.0.tgz", + "integrity": "sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/pako": { + "version": "1.0.11", + "resolved": "https://registry.npmjs.org/pako/-/pako-1.0.11.tgz", + "integrity": "sha512-4hLB8Py4zZce5s4yd9XzopqwVv/yGNhV1Bl8NTmCq1763HeK2+EwVTv+leGeL13Dnh2wfbqowVPXCIO0z4taYw==", + "dev": true + }, + "node_modules/param-case": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/param-case/-/param-case-3.0.4.tgz", + "integrity": "sha512-RXlj7zCYokReqWpOPH9oYivUzLYZ5vAPIfEmCTNViosC78F8F0H9y7T7gG2M39ymgutxF5gcFEsyZQSph9Bp3A==", + "dev": true, + "dependencies": { + "dot-case": "^3.0.4", + "tslib": "^2.0.3" + } + }, + "node_modules/parent-module": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/parent-module/-/parent-module-1.0.1.tgz", + "integrity": "sha512-GQ2EWRpQV8/o+Aw8YqtfZZPfNRWZYkbidE9k5rpl/hC3vtHHBfGm2Ifi6qWV+coDGkrUKZAxE3Lot5kcsRlh+g==", + "dev": true, + "dependencies": { + "callsites": "^3.0.0" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/parse-asn1": { + "version": "5.1.7", + "resolved": "https://registry.npmjs.org/parse-asn1/-/parse-asn1-5.1.7.tgz", + "integrity": "sha512-CTM5kuWR3sx9IFamcl5ErfPl6ea/N8IYwiJ+vpeB2g+1iknv7zBl5uPwbMbRVznRVbrNY6lGuDoE5b30grmbqg==", + "dev": true, + "dependencies": { + "asn1.js": "^4.10.1", + "browserify-aes": "^1.2.0", + "evp_bytestokey": "^1.0.3", + "hash-base": "~3.0", + "pbkdf2": "^3.1.2", + "safe-buffer": "^5.2.1" + }, + "engines": { + "node": ">= 0.10" + } + }, + "node_modules/parse-asn1/node_modules/hash-base": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/hash-base/-/hash-base-3.0.4.tgz", + "integrity": "sha512-EeeoJKjTyt868liAlVmcv2ZsUfGHlE3Q+BICOXcZiwN3osr5Q/zFGYmTJpoIzuaSTAwndFy+GqhEwlU4L3j4Ow==", + "dev": true, + "dependencies": { + "inherits": "^2.0.1", + "safe-buffer": "^5.0.1" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/parse-asn1/node_modules/safe-buffer": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", + "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ] + }, + "node_modules/parse-json": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/parse-json/-/parse-json-5.2.0.tgz", + "integrity": "sha512-ayCKvm/phCGxOkYRSCM82iDwct8/EonSEgCSxWxD7ve6jHggsFl4fZVQBPRNgQoKiuV/odhFrGzQXZwbifC8Rg==", + "dev": true, + "dependencies": { + "@babel/code-frame": "^7.0.0", + "error-ex": "^1.3.1", + "json-parse-even-better-errors": "^2.3.0", + "lines-and-columns": "^1.1.6" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/parseurl": { + "version": "1.3.3", + "resolved": "https://registry.npmjs.org/parseurl/-/parseurl-1.3.3.tgz", + "integrity": "sha512-CiyeOxFT/JZyN5m0z9PfXw4SCBJ6Sygz1Dpl0wqjlhDEGGBP1GnsUVEL0p63hoG1fcj3fHynXi9NYO4nWOL+qQ==", + "dev": true, + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/pascal-case": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/pascal-case/-/pascal-case-3.1.2.tgz", + "integrity": "sha512-uWlGT3YSnK9x3BQJaOdcZwrnV6hPpd8jFH1/ucpiLRPh/2zCVJKS19E4GvYHvaCcACn3foXZ0cLB9Wrx1KGe5g==", + "dev": true, + "dependencies": { + "no-case": "^3.0.4", + "tslib": "^2.0.3" + } + }, + "node_modules/path-browserify": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/path-browserify/-/path-browserify-0.0.1.tgz", + "integrity": "sha512-BapA40NHICOS+USX9SN4tyhq+A2RrN/Ws5F0Z5aMHDp98Fl86lX8Oti8B7uN93L4Ifv4fHOEA+pQw87gmMO/lQ==", + "dev": true + }, + "node_modules/path-exists": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", + "integrity": "sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/path-is-absolute": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", + "integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/path-key": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/path-key/-/path-key-3.1.1.tgz", + "integrity": "sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/path-parse": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.7.tgz", + "integrity": "sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==", + "dev": true + }, + "node_modules/path-to-regexp": { + "version": "0.1.7", + "resolved": "https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-0.1.7.tgz", + "integrity": "sha512-5DFkuoqlv1uYQKxy8omFBeJPQcdoE07Kv2sferDCrAq1ohOU+MSDswDIbnx3YAM60qIOnYa53wBhXW0EbMonrQ==", + "dev": true + }, + "node_modules/path-type": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/path-type/-/path-type-4.0.0.tgz", + "integrity": "sha512-gDKb8aZMDeD/tZWs9P6+q0J9Mwkdl6xMV8TjnGP3qJVJ06bdMgkbBlLU8IdfOsIsFz2BW1rNVT3XuNEl8zPAvw==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/pbkdf2": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/pbkdf2/-/pbkdf2-3.1.2.tgz", + "integrity": "sha512-iuh7L6jA7JEGu2WxDwtQP1ddOpaJNC4KlDEFfdQajSGgGPNi4OyDc2R7QnbY2bR9QjBVGwgvTdNJZoE7RaxUMA==", + "dev": true, + "dependencies": { + "create-hash": "^1.1.2", + "create-hmac": "^1.1.4", + "ripemd160": "^2.0.1", + "safe-buffer": "^5.0.1", + "sha.js": "^2.4.8" + }, + "engines": { + "node": ">=0.12" + } + }, + "node_modules/php-parser": { + "version": "3.1.5", + "resolved": "https://registry.npmjs.org/php-parser/-/php-parser-3.1.5.tgz", + "integrity": "sha512-jEY2DcbgCm5aclzBdfW86GM6VEIWcSlhTBSHN1qhJguVePlYe28GhwS0yoeLYXpM2K8y6wzLwrbq814n2PHSoQ==", + "dev": true + }, + "node_modules/picocolors": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.0.1.tgz", + "integrity": "sha512-anP1Z8qwhkbmu7MFP5iTt+wQKXgwzf7zTyGlcdzabySa9vd0Xt392U0rVmz9poOaBj0uHJKyyo9/upk0HrEQew==", + "dev": true + }, + "node_modules/picomatch": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.1.tgz", + "integrity": "sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==", + "dev": true, + "engines": { + "node": ">=8.6" + }, + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" + } + }, + "node_modules/pkg-dir": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/pkg-dir/-/pkg-dir-4.2.0.tgz", + "integrity": "sha512-HRDzbaKjC+AOWVXxAU/x54COGeIv9eb+6CkDSQoNTt4XyWoIJvuPsXizxu/Fr23EiekbtZwmh1IcIG/l/a10GQ==", + "dev": true, + "dependencies": { + "find-up": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/popper.js": { + "version": "1.16.1", + "resolved": "https://registry.npmjs.org/popper.js/-/popper.js-1.16.1.tgz", + "integrity": "sha512-Wb4p1J4zyFTbM+u6WuO4XstYx4Ky9Cewe4DWrel7B0w6VVICvPwdOpotjzcf6eD8TsckVnIMNONQyPIUFOUbCQ==", + "deprecated": "You can find the new Popper v2 at @popperjs/core, this package is dedicated to the legacy v1", + "dev": true, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/popperjs" + } + }, + "node_modules/postcss": { + "version": "8.4.38", + "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.4.38.tgz", + "integrity": "sha512-Wglpdk03BSfXkHoQa3b/oulrotAkwrlLDRSOb9D0bN86FdRyE9lppSp33aHNPgBa0JKCoB+drFLZkQoRRYae5A==", + "dev": true, + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/postcss" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "dependencies": { + "nanoid": "^3.3.7", + "picocolors": "^1.0.0", + "source-map-js": "^1.2.0" + }, + "engines": { + "node": "^10 || ^12 || >=14" + } + }, + "node_modules/postcss-calc": { + "version": "8.2.4", + "resolved": "https://registry.npmjs.org/postcss-calc/-/postcss-calc-8.2.4.tgz", + "integrity": "sha512-SmWMSJmB8MRnnULldx0lQIyhSNvuDl9HfrZkaqqE/WHAhToYsAvDq+yAsA/kIyINDszOp3Rh0GFoNuH5Ypsm3Q==", + "dev": true, + "dependencies": { + "postcss-selector-parser": "^6.0.9", + "postcss-value-parser": "^4.2.0" + }, + "peerDependencies": { + "postcss": "^8.2.2" + } + }, + "node_modules/postcss-colormin": { + "version": "5.3.1", + "resolved": "https://registry.npmjs.org/postcss-colormin/-/postcss-colormin-5.3.1.tgz", + "integrity": "sha512-UsWQG0AqTFQmpBegeLLc1+c3jIqBNB0zlDGRWR+dQ3pRKJL1oeMzyqmH3o2PIfn9MBdNrVPWhDbT769LxCTLJQ==", + "dev": true, + "dependencies": { + "browserslist": "^4.21.4", + "caniuse-api": "^3.0.0", + "colord": "^2.9.1", + "postcss-value-parser": "^4.2.0" + }, + "engines": { + "node": "^10 || ^12 || >=14.0" + }, + "peerDependencies": { + "postcss": "^8.2.15" + } + }, + "node_modules/postcss-convert-values": { + "version": "5.1.3", + "resolved": "https://registry.npmjs.org/postcss-convert-values/-/postcss-convert-values-5.1.3.tgz", + "integrity": "sha512-82pC1xkJZtcJEfiLw6UXnXVXScgtBrjlO5CBmuDQc+dlb88ZYheFsjTn40+zBVi3DkfF7iezO0nJUPLcJK3pvA==", + "dev": true, + "dependencies": { + "browserslist": "^4.21.4", + "postcss-value-parser": "^4.2.0" + }, + "engines": { + "node": "^10 || ^12 || >=14.0" + }, + "peerDependencies": { + "postcss": "^8.2.15" + } + }, + "node_modules/postcss-discard-comments": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/postcss-discard-comments/-/postcss-discard-comments-5.1.2.tgz", + "integrity": "sha512-+L8208OVbHVF2UQf1iDmRcbdjJkuBF6IS29yBDSiWUIzpYaAhtNl6JYnYm12FnkeCwQqF5LeklOu6rAqgfBZqQ==", + "dev": true, + "engines": { + "node": "^10 || ^12 || >=14.0" + }, + "peerDependencies": { + "postcss": "^8.2.15" + } + }, + "node_modules/postcss-discard-duplicates": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/postcss-discard-duplicates/-/postcss-discard-duplicates-5.1.0.tgz", + "integrity": "sha512-zmX3IoSI2aoenxHV6C7plngHWWhUOV3sP1T8y2ifzxzbtnuhk1EdPwm0S1bIUNaJ2eNbWeGLEwzw8huPD67aQw==", + "dev": true, + "engines": { + "node": "^10 || ^12 || >=14.0" + }, + "peerDependencies": { + "postcss": "^8.2.15" + } + }, + "node_modules/postcss-discard-empty": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/postcss-discard-empty/-/postcss-discard-empty-5.1.1.tgz", + "integrity": "sha512-zPz4WljiSuLWsI0ir4Mcnr4qQQ5e1Ukc3i7UfE2XcrwKK2LIPIqE5jxMRxO6GbI3cv//ztXDsXwEWT3BHOGh3A==", + "dev": true, + "engines": { + "node": "^10 || ^12 || >=14.0" + }, + "peerDependencies": { + "postcss": "^8.2.15" + } + }, + "node_modules/postcss-discard-overridden": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/postcss-discard-overridden/-/postcss-discard-overridden-5.1.0.tgz", + "integrity": "sha512-21nOL7RqWR1kasIVdKs8HNqQJhFxLsyRfAnUDm4Fe4t4mCWL9OJiHvlHPjcd8zc5Myu89b/7wZDnOSjFgeWRtw==", + "dev": true, + "engines": { + "node": "^10 || ^12 || >=14.0" + }, + "peerDependencies": { + "postcss": "^8.2.15" + } + }, + "node_modules/postcss-load-config": { + "version": "3.1.4", + "resolved": "https://registry.npmjs.org/postcss-load-config/-/postcss-load-config-3.1.4.tgz", + "integrity": "sha512-6DiM4E7v4coTE4uzA8U//WhtPwyhiim3eyjEMFCnUpzbrkK9wJHgKDT2mR+HbtSrd/NubVaYTOpSpjUl8NQeRg==", + "dev": true, + "dependencies": { + "lilconfig": "^2.0.5", + "yaml": "^1.10.2" + }, + "engines": { + "node": ">= 10" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + }, + "peerDependencies": { + "postcss": ">=8.0.9", + "ts-node": ">=9.0.0" + }, + "peerDependenciesMeta": { + "postcss": { + "optional": true + }, + "ts-node": { + "optional": true + } + } + }, + "node_modules/postcss-loader": { + "version": "6.2.1", + "resolved": "https://registry.npmjs.org/postcss-loader/-/postcss-loader-6.2.1.tgz", + "integrity": "sha512-WbbYpmAaKcux/P66bZ40bpWsBucjx/TTgVVzRZ9yUO8yQfVBlameJ0ZGVaPfH64hNSBh63a+ICP5nqOpBA0w+Q==", + "dev": true, + "dependencies": { + "cosmiconfig": "^7.0.0", + "klona": "^2.0.5", + "semver": "^7.3.5" + }, + "engines": { + "node": ">= 12.13.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/webpack" + }, + "peerDependencies": { + "postcss": "^7.0.0 || ^8.0.1", + "webpack": "^5.0.0" + } + }, + "node_modules/postcss-loader/node_modules/semver": { + "version": "7.6.2", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.6.2.tgz", + "integrity": "sha512-FNAIBWCx9qcRhoHcgcJ0gvU7SN1lYU2ZXuSfl04bSC5OpvDHFyJCjdNHomPXxjQlCBU67YW64PzY7/VIEH7F2w==", + "dev": true, + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/postcss-merge-longhand": { + "version": "5.1.7", + "resolved": "https://registry.npmjs.org/postcss-merge-longhand/-/postcss-merge-longhand-5.1.7.tgz", + "integrity": "sha512-YCI9gZB+PLNskrK0BB3/2OzPnGhPkBEwmwhfYk1ilBHYVAZB7/tkTHFBAnCrvBBOmeYyMYw3DMjT55SyxMBzjQ==", + "dev": true, + "dependencies": { + "postcss-value-parser": "^4.2.0", + "stylehacks": "^5.1.1" + }, + "engines": { + "node": "^10 || ^12 || >=14.0" + }, + "peerDependencies": { + "postcss": "^8.2.15" + } + }, + "node_modules/postcss-merge-rules": { + "version": "5.1.4", + "resolved": "https://registry.npmjs.org/postcss-merge-rules/-/postcss-merge-rules-5.1.4.tgz", + "integrity": "sha512-0R2IuYpgU93y9lhVbO/OylTtKMVcHb67zjWIfCiKR9rWL3GUk1677LAqD/BcHizukdZEjT8Ru3oHRoAYoJy44g==", + "dev": true, + "dependencies": { + "browserslist": "^4.21.4", + "caniuse-api": "^3.0.0", + "cssnano-utils": "^3.1.0", + "postcss-selector-parser": "^6.0.5" + }, + "engines": { + "node": "^10 || ^12 || >=14.0" + }, + "peerDependencies": { + "postcss": "^8.2.15" + } + }, + "node_modules/postcss-minify-font-values": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/postcss-minify-font-values/-/postcss-minify-font-values-5.1.0.tgz", + "integrity": "sha512-el3mYTgx13ZAPPirSVsHqFzl+BBBDrXvbySvPGFnQcTI4iNslrPaFq4muTkLZmKlGk4gyFAYUBMH30+HurREyA==", + "dev": true, + "dependencies": { + "postcss-value-parser": "^4.2.0" + }, + "engines": { + "node": "^10 || ^12 || >=14.0" + }, + "peerDependencies": { + "postcss": "^8.2.15" + } + }, + "node_modules/postcss-minify-gradients": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/postcss-minify-gradients/-/postcss-minify-gradients-5.1.1.tgz", + "integrity": "sha512-VGvXMTpCEo4qHTNSa9A0a3D+dxGFZCYwR6Jokk+/3oB6flu2/PnPXAh2x7x52EkY5xlIHLm+Le8tJxe/7TNhzw==", + "dev": true, + "dependencies": { + "colord": "^2.9.1", + "cssnano-utils": "^3.1.0", + "postcss-value-parser": "^4.2.0" + }, + "engines": { + "node": "^10 || ^12 || >=14.0" + }, + "peerDependencies": { + "postcss": "^8.2.15" + } + }, + "node_modules/postcss-minify-params": { + "version": "5.1.4", + "resolved": "https://registry.npmjs.org/postcss-minify-params/-/postcss-minify-params-5.1.4.tgz", + "integrity": "sha512-+mePA3MgdmVmv6g+30rn57USjOGSAyuxUmkfiWpzalZ8aiBkdPYjXWtHuwJGm1v5Ojy0Z0LaSYhHaLJQB0P8Jw==", + "dev": true, + "dependencies": { + "browserslist": "^4.21.4", + "cssnano-utils": "^3.1.0", + "postcss-value-parser": "^4.2.0" + }, + "engines": { + "node": "^10 || ^12 || >=14.0" + }, + "peerDependencies": { + "postcss": "^8.2.15" + } + }, + "node_modules/postcss-minify-selectors": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/postcss-minify-selectors/-/postcss-minify-selectors-5.2.1.tgz", + "integrity": "sha512-nPJu7OjZJTsVUmPdm2TcaiohIwxP+v8ha9NehQ2ye9szv4orirRU3SDdtUmKH+10nzn0bAyOXZ0UEr7OpvLehg==", + "dev": true, + "dependencies": { + "postcss-selector-parser": "^6.0.5" + }, + "engines": { + "node": "^10 || ^12 || >=14.0" + }, + "peerDependencies": { + "postcss": "^8.2.15" + } + }, + "node_modules/postcss-modules-extract-imports": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/postcss-modules-extract-imports/-/postcss-modules-extract-imports-3.1.0.tgz", + "integrity": "sha512-k3kNe0aNFQDAZGbin48pL2VNidTF0w4/eASDsxlyspobzU3wZQLOGj7L9gfRe0Jo9/4uud09DsjFNH7winGv8Q==", + "dev": true, + "engines": { + "node": "^10 || ^12 || >= 14" + }, + "peerDependencies": { + "postcss": "^8.1.0" + } + }, + "node_modules/postcss-modules-local-by-default": { + "version": "4.0.5", + "resolved": "https://registry.npmjs.org/postcss-modules-local-by-default/-/postcss-modules-local-by-default-4.0.5.tgz", + "integrity": "sha512-6MieY7sIfTK0hYfafw1OMEG+2bg8Q1ocHCpoWLqOKj3JXlKu4G7btkmM/B7lFubYkYWmRSPLZi5chid63ZaZYw==", + "dev": true, + "dependencies": { + "icss-utils": "^5.0.0", + "postcss-selector-parser": "^6.0.2", + "postcss-value-parser": "^4.1.0" + }, + "engines": { + "node": "^10 || ^12 || >= 14" + }, + "peerDependencies": { + "postcss": "^8.1.0" + } + }, + "node_modules/postcss-modules-scope": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/postcss-modules-scope/-/postcss-modules-scope-3.2.0.tgz", + "integrity": "sha512-oq+g1ssrsZOsx9M96c5w8laRmvEu9C3adDSjI8oTcbfkrTE8hx/zfyobUoWIxaKPO8bt6S62kxpw5GqypEw1QQ==", + "dev": true, + "dependencies": { + "postcss-selector-parser": "^6.0.4" + }, + "engines": { + "node": "^10 || ^12 || >= 14" + }, + "peerDependencies": { + "postcss": "^8.1.0" + } + }, + "node_modules/postcss-modules-values": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/postcss-modules-values/-/postcss-modules-values-4.0.0.tgz", + "integrity": "sha512-RDxHkAiEGI78gS2ofyvCsu7iycRv7oqw5xMWn9iMoR0N/7mf9D50ecQqUo5BZ9Zh2vH4bCUR/ktCqbB9m8vJjQ==", + "dev": true, + "dependencies": { + "icss-utils": "^5.0.0" + }, + "engines": { + "node": "^10 || ^12 || >= 14" + }, + "peerDependencies": { + "postcss": "^8.1.0" + } + }, + "node_modules/postcss-normalize-charset": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/postcss-normalize-charset/-/postcss-normalize-charset-5.1.0.tgz", + "integrity": "sha512-mSgUJ+pd/ldRGVx26p2wz9dNZ7ji6Pn8VWBajMXFf8jk7vUoSrZ2lt/wZR7DtlZYKesmZI680qjr2CeFF2fbUg==", + "dev": true, + "engines": { + "node": "^10 || ^12 || >=14.0" + }, + "peerDependencies": { + "postcss": "^8.2.15" + } + }, + "node_modules/postcss-normalize-display-values": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/postcss-normalize-display-values/-/postcss-normalize-display-values-5.1.0.tgz", + "integrity": "sha512-WP4KIM4o2dazQXWmFaqMmcvsKmhdINFblgSeRgn8BJ6vxaMyaJkwAzpPpuvSIoG/rmX3M+IrRZEz2H0glrQNEA==", + "dev": true, + "dependencies": { + "postcss-value-parser": "^4.2.0" + }, + "engines": { + "node": "^10 || ^12 || >=14.0" + }, + "peerDependencies": { + "postcss": "^8.2.15" + } + }, + "node_modules/postcss-normalize-positions": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/postcss-normalize-positions/-/postcss-normalize-positions-5.1.1.tgz", + "integrity": "sha512-6UpCb0G4eofTCQLFVuI3EVNZzBNPiIKcA1AKVka+31fTVySphr3VUgAIULBhxZkKgwLImhzMR2Bw1ORK+37INg==", + "dev": true, + "dependencies": { + "postcss-value-parser": "^4.2.0" + }, + "engines": { + "node": "^10 || ^12 || >=14.0" + }, + "peerDependencies": { + "postcss": "^8.2.15" + } + }, + "node_modules/postcss-normalize-repeat-style": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/postcss-normalize-repeat-style/-/postcss-normalize-repeat-style-5.1.1.tgz", + "integrity": "sha512-mFpLspGWkQtBcWIRFLmewo8aC3ImN2i/J3v8YCFUwDnPu3Xz4rLohDO26lGjwNsQxB3YF0KKRwspGzE2JEuS0g==", + "dev": true, + "dependencies": { + "postcss-value-parser": "^4.2.0" + }, + "engines": { + "node": "^10 || ^12 || >=14.0" + }, + "peerDependencies": { + "postcss": "^8.2.15" + } + }, + "node_modules/postcss-normalize-string": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/postcss-normalize-string/-/postcss-normalize-string-5.1.0.tgz", + "integrity": "sha512-oYiIJOf4T9T1N4i+abeIc7Vgm/xPCGih4bZz5Nm0/ARVJ7K6xrDlLwvwqOydvyL3RHNf8qZk6vo3aatiw/go3w==", + "dev": true, + "dependencies": { + "postcss-value-parser": "^4.2.0" + }, + "engines": { + "node": "^10 || ^12 || >=14.0" + }, + "peerDependencies": { + "postcss": "^8.2.15" + } + }, + "node_modules/postcss-normalize-timing-functions": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/postcss-normalize-timing-functions/-/postcss-normalize-timing-functions-5.1.0.tgz", + "integrity": "sha512-DOEkzJ4SAXv5xkHl0Wa9cZLF3WCBhF3o1SKVxKQAa+0pYKlueTpCgvkFAHfk+Y64ezX9+nITGrDZeVGgITJXjg==", + "dev": true, + "dependencies": { + "postcss-value-parser": "^4.2.0" + }, + "engines": { + "node": "^10 || ^12 || >=14.0" + }, + "peerDependencies": { + "postcss": "^8.2.15" + } + }, + "node_modules/postcss-normalize-unicode": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/postcss-normalize-unicode/-/postcss-normalize-unicode-5.1.1.tgz", + "integrity": "sha512-qnCL5jzkNUmKVhZoENp1mJiGNPcsJCs1aaRmURmeJGES23Z/ajaln+EPTD+rBeNkSryI+2WTdW+lwcVdOikrpA==", + "dev": true, + "dependencies": { + "browserslist": "^4.21.4", + "postcss-value-parser": "^4.2.0" + }, + "engines": { + "node": "^10 || ^12 || >=14.0" + }, + "peerDependencies": { + "postcss": "^8.2.15" + } + }, + "node_modules/postcss-normalize-url": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/postcss-normalize-url/-/postcss-normalize-url-5.1.0.tgz", + "integrity": "sha512-5upGeDO+PVthOxSmds43ZeMeZfKH+/DKgGRD7TElkkyS46JXAUhMzIKiCa7BabPeIy3AQcTkXwVVN7DbqsiCew==", + "dev": true, + "dependencies": { + "normalize-url": "^6.0.1", + "postcss-value-parser": "^4.2.0" + }, + "engines": { + "node": "^10 || ^12 || >=14.0" + }, + "peerDependencies": { + "postcss": "^8.2.15" + } + }, + "node_modules/postcss-normalize-whitespace": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/postcss-normalize-whitespace/-/postcss-normalize-whitespace-5.1.1.tgz", + "integrity": "sha512-83ZJ4t3NUDETIHTa3uEg6asWjSBYL5EdkVB0sDncx9ERzOKBVJIUeDO9RyA9Zwtig8El1d79HBp0JEi8wvGQnA==", + "dev": true, + "dependencies": { + "postcss-value-parser": "^4.2.0" + }, + "engines": { + "node": "^10 || ^12 || >=14.0" + }, + "peerDependencies": { + "postcss": "^8.2.15" + } + }, + "node_modules/postcss-ordered-values": { + "version": "5.1.3", + "resolved": "https://registry.npmjs.org/postcss-ordered-values/-/postcss-ordered-values-5.1.3.tgz", + "integrity": "sha512-9UO79VUhPwEkzbb3RNpqqghc6lcYej1aveQteWY+4POIwlqkYE21HKWaLDF6lWNuqCobEAyTovVhtI32Rbv2RQ==", + "dev": true, + "dependencies": { + "cssnano-utils": "^3.1.0", + "postcss-value-parser": "^4.2.0" + }, + "engines": { + "node": "^10 || ^12 || >=14.0" + }, + "peerDependencies": { + "postcss": "^8.2.15" + } + }, + "node_modules/postcss-reduce-initial": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/postcss-reduce-initial/-/postcss-reduce-initial-5.1.2.tgz", + "integrity": "sha512-dE/y2XRaqAi6OvjzD22pjTUQ8eOfc6m/natGHgKFBK9DxFmIm69YmaRVQrGgFlEfc1HePIurY0TmDeROK05rIg==", + "dev": true, + "dependencies": { + "browserslist": "^4.21.4", + "caniuse-api": "^3.0.0" + }, + "engines": { + "node": "^10 || ^12 || >=14.0" + }, + "peerDependencies": { + "postcss": "^8.2.15" + } + }, + "node_modules/postcss-reduce-transforms": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/postcss-reduce-transforms/-/postcss-reduce-transforms-5.1.0.tgz", + "integrity": "sha512-2fbdbmgir5AvpW9RLtdONx1QoYG2/EtqpNQbFASDlixBbAYuTcJ0dECwlqNqH7VbaUnEnh8SrxOe2sRIn24XyQ==", + "dev": true, + "dependencies": { + "postcss-value-parser": "^4.2.0" + }, + "engines": { + "node": "^10 || ^12 || >=14.0" + }, + "peerDependencies": { + "postcss": "^8.2.15" + } + }, + "node_modules/postcss-selector-parser": { + "version": "6.1.0", + "resolved": "https://registry.npmjs.org/postcss-selector-parser/-/postcss-selector-parser-6.1.0.tgz", + "integrity": "sha512-UMz42UD0UY0EApS0ZL9o1XnLhSTtvvvLe5Dc2H2O56fvRZi+KulDyf5ctDhhtYJBGKStV2FL1fy6253cmLgqVQ==", + "dev": true, + "dependencies": { + "cssesc": "^3.0.0", + "util-deprecate": "^1.0.2" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/postcss-svgo": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/postcss-svgo/-/postcss-svgo-5.1.0.tgz", + "integrity": "sha512-D75KsH1zm5ZrHyxPakAxJWtkyXew5qwS70v56exwvw542d9CRtTo78K0WeFxZB4G7JXKKMbEZtZayTGdIky/eA==", + "dev": true, + "dependencies": { + "postcss-value-parser": "^4.2.0", + "svgo": "^2.7.0" + }, + "engines": { + "node": "^10 || ^12 || >=14.0" + }, + "peerDependencies": { + "postcss": "^8.2.15" + } + }, + "node_modules/postcss-unique-selectors": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/postcss-unique-selectors/-/postcss-unique-selectors-5.1.1.tgz", + "integrity": "sha512-5JiODlELrz8L2HwxfPnhOWZYWDxVHWL83ufOv84NrcgipI7TaeRsatAhK4Tr2/ZiYldpK/wBvw5BD3qfaK96GA==", + "dev": true, + "dependencies": { + "postcss-selector-parser": "^6.0.5" + }, + "engines": { + "node": "^10 || ^12 || >=14.0" + }, + "peerDependencies": { + "postcss": "^8.2.15" + } + }, + "node_modules/postcss-value-parser": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/postcss-value-parser/-/postcss-value-parser-4.2.0.tgz", + "integrity": "sha512-1NNCs6uurfkVbeXG4S8JFT9t19m45ICnif8zWLd5oPSZ50QnwMfK+H3jv408d4jw/7Bttv5axS5IiHoLaVNHeQ==", + "dev": true + }, + "node_modules/prettier": { + "version": "2.8.8", + "resolved": "https://registry.npmjs.org/prettier/-/prettier-2.8.8.tgz", + "integrity": "sha512-tdN8qQGvNjw4CHbY+XXk0JgCXn9QiF21a55rBe5LJAU+kDyC4WQn4+awm2Xfk2lQMk5fKup9XgzTZtGkjBdP9Q==", + "dev": true, + "bin": { + "prettier": "bin-prettier.js" + }, + "engines": { + "node": ">=10.13.0" + }, + "funding": { + "url": "https://github.com/prettier/prettier?sponsor=1" + } + }, + "node_modules/pretty-time": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/pretty-time/-/pretty-time-1.1.0.tgz", + "integrity": "sha512-28iF6xPQrP8Oa6uxE6a1biz+lWeTOAPKggvjB8HAs6nVMKZwf5bG++632Dx614hIWgUPkgivRfG+a8uAXGTIbA==", + "dev": true, + "engines": { + "node": ">=4" + } + }, + "node_modules/process": { + "version": "0.11.10", + "resolved": "https://registry.npmjs.org/process/-/process-0.11.10.tgz", + "integrity": "sha1-czIwDoQBYb2j5podHZGn1LwW8YI=", + "dev": true, + "engines": { + "node": ">= 0.6.0" + } + }, + "node_modules/process-nextick-args": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.1.tgz", + "integrity": "sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag==", + "dev": true + }, + "node_modules/proxy-addr": { + "version": "2.0.7", + "resolved": "https://registry.npmjs.org/proxy-addr/-/proxy-addr-2.0.7.tgz", + "integrity": "sha512-llQsMLSUDUPT44jdrU/O37qlnifitDP+ZwrmmZcoSKyLKvtZxpyV0n2/bD/N4tBAAZ/gJEdZU7KMraoK1+XYAg==", + "dev": true, + "dependencies": { + "forwarded": "0.2.0", + "ipaddr.js": "1.9.1" + }, + "engines": { + "node": ">= 0.10" + } + }, + "node_modules/proxy-addr/node_modules/ipaddr.js": { + "version": "1.9.1", + "resolved": "https://registry.npmjs.org/ipaddr.js/-/ipaddr.js-1.9.1.tgz", + "integrity": "sha512-0KI/607xoxSToH7GjN1FfSbLoU0+btTicjsQSWQlh/hZykN8KpmMf7uYwPW3R+akZ6R/w18ZlXSHBYXiYUPO3g==", + "dev": true, + "engines": { + "node": ">= 0.10" + } + }, + "node_modules/proxy-from-env": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/proxy-from-env/-/proxy-from-env-1.1.0.tgz", + "integrity": "sha512-D+zkORCbA9f1tdWRK0RaCR3GPv50cMxcrz4X8k5LTSUD1Dkw47mKJEZQNunItRTkWwgtaUSo1RVFRIG9ZXiFYg==", + "dev": true + }, + "node_modules/public-encrypt": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/public-encrypt/-/public-encrypt-4.0.3.tgz", + "integrity": "sha512-zVpa8oKZSz5bTMTFClc1fQOnyyEzpl5ozpi1B5YcvBrdohMjH2rfsBtyXcuNuwjsDIXmBYlF2N5FlJYhR29t8Q==", + "dev": true, + "dependencies": { + "bn.js": "^4.1.0", + "browserify-rsa": "^4.0.0", + "create-hash": "^1.1.0", + "parse-asn1": "^5.0.0", + "randombytes": "^2.0.1", + "safe-buffer": "^5.1.2" + } + }, + "node_modules/public-encrypt/node_modules/bn.js": { + "version": "4.12.0", + "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-4.12.0.tgz", + "integrity": "sha512-c98Bf3tPniI+scsdk237ku1Dc3ujXQTSgyiPUDEOe7tRkhrqridvh8klBv0HCEso1OLOYcHuCv/cS6DNxKH+ZA==", + "dev": true + }, + "node_modules/punycode": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.1.1.tgz", + "integrity": "sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/qs": { + "version": "6.11.0", + "resolved": "https://registry.npmjs.org/qs/-/qs-6.11.0.tgz", + "integrity": "sha512-MvjoMCJwEarSbUYk5O+nmoSzSutSsTwF85zcHPQ9OrlFoZOYIjaqBAJIqIXjptyD5vThxGq52Xu/MaJzRkIk4Q==", + "dev": true, + "dependencies": { + "side-channel": "^1.0.4" + }, + "engines": { + "node": ">=0.6" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/querystring": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/querystring/-/querystring-0.2.0.tgz", + "integrity": "sha1-sgmEkgO7Jd+CDadW50cAWHhSFiA=", + "deprecated": "The querystring API is considered Legacy. new code should use the URLSearchParams API instead.", + "dev": true, + "engines": { + "node": ">=0.4.x" + } + }, + "node_modules/querystring-es3": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/querystring-es3/-/querystring-es3-0.2.1.tgz", + "integrity": "sha1-nsYfeQSYdXB9aUFFlv2Qek1xHnM=", + "dev": true, + "engines": { + "node": ">=0.4.x" + } + }, + "node_modules/queue-microtask": { + "version": "1.2.3", + "resolved": "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz", + "integrity": "sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ] + }, + "node_modules/randombytes": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/randombytes/-/randombytes-2.1.0.tgz", + "integrity": "sha512-vYl3iOX+4CKUWuxGi9Ukhie6fsqXqS9FE2Zaic4tNFD2N2QQaXOMFbuKK4QmDHC0JO6B1Zp41J0LpT0oR68amQ==", + "dev": true, + "dependencies": { + "safe-buffer": "^5.1.0" + } + }, + "node_modules/randomfill": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/randomfill/-/randomfill-1.0.4.tgz", + "integrity": "sha512-87lcbR8+MhcWcUiQ+9e+Rwx8MyR2P7qnt15ynUlbm3TU/fjbgz4GsvfSUDTemtCCtVCqb4ZcEFlyPNTh9bBTLw==", + "dev": true, + "dependencies": { + "randombytes": "^2.0.5", + "safe-buffer": "^5.1.0" + } + }, + "node_modules/range-parser": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/range-parser/-/range-parser-1.2.1.tgz", + "integrity": "sha512-Hrgsx+orqoygnmhFbKaHE6c296J+HTAQXoxEF6gNupROmmGJRoyzfG3ccAveqCBrwr/2yxQ5BVd/GTl5agOwSg==", + "dev": true, + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/raw-body": { + "version": "2.5.2", + "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-2.5.2.tgz", + "integrity": "sha512-8zGqypfENjCIqGhgXToC8aB2r7YrBX+AQAfIPs/Mlk+BtPTztOvTS01NRW/3Eh60J+a48lt8qsCzirQ6loCVfA==", + "dev": true, + "dependencies": { + "bytes": "3.1.2", + "http-errors": "2.0.0", + "iconv-lite": "0.4.24", + "unpipe": "1.0.0" + }, + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/raw-body/node_modules/bytes": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/bytes/-/bytes-3.1.2.tgz", + "integrity": "sha512-/Nf7TyzTx6S3yRJObOAV7956r8cr2+Oj8AC5dt8wSP3BQAoeX58NoHyCU8P8zGkNXStjTSi6fzO6F0pBdcYbEg==", + "dev": true, + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/readable-stream": { + "version": "2.3.8", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.8.tgz", + "integrity": "sha512-8p0AUk4XODgIewSi0l8Epjs+EVnWiK7NoDIEGU0HhE7+ZyY8D1IMY7odu5lRrFXGg71L15KG8QrPmum45RTtdA==", + "dev": true, + "dependencies": { + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" + } + }, + "node_modules/readdirp": { + "version": "3.6.0", + "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-3.6.0.tgz", + "integrity": "sha512-hOS089on8RduqdbhvQ5Z37A0ESjsqz6qnRcffsMU3495FuTdqSm+7bhJ29JvIOsBDEEnan5DPu9t3To9VRlMzA==", + "dev": true, + "dependencies": { + "picomatch": "^2.2.1" + }, + "engines": { + "node": ">=8.10.0" + } + }, + "node_modules/rechoir": { + "version": "0.7.1", + "resolved": "https://registry.npmjs.org/rechoir/-/rechoir-0.7.1.tgz", + "integrity": "sha512-/njmZ8s1wVeR6pjTZ+0nCnv8SpZNRMT2D1RLOJQESlYFDBvwpTA4KWJpZ+sBJ4+vhjILRcK7JIFdGCdxEAAitg==", + "dev": true, + "dependencies": { + "resolve": "^1.9.0" + }, + "engines": { + "node": ">= 0.10" + } + }, + "node_modules/regenerate": { + "version": "1.4.2", + "resolved": "https://registry.npmjs.org/regenerate/-/regenerate-1.4.2.tgz", + "integrity": "sha512-zrceR/XhGYU/d/opr2EKO7aRHUeiBI8qjtfHqADTwZd6Szfy16la6kqD0MIUs5z5hx6AaKa+PixpPrR289+I0A==", + "dev": true + }, + "node_modules/regenerate-unicode-properties": { + "version": "10.0.1", + "resolved": "https://registry.npmjs.org/regenerate-unicode-properties/-/regenerate-unicode-properties-10.0.1.tgz", + "integrity": "sha512-vn5DU6yg6h8hP/2OkQo3K7uVILvY4iu0oI4t3HFa81UPkhGJwkRwM10JEc3upjdhHjs/k8GJY1sRBhk5sr69Bw==", + "dev": true, + "dependencies": { + "regenerate": "^1.4.2" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/regenerator-runtime": { + "version": "0.13.9", + "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.13.9.tgz", + "integrity": "sha512-p3VT+cOEgxFsRRA9X4lkI1E+k2/CtnKtU4gcxyaCUreilL/vqI6CdZ3wxVUx3UOUg+gnUOQQcRI7BmSI656MYA==", + "dev": true + }, + "node_modules/regenerator-transform": { + "version": "0.14.5", + "resolved": "https://registry.npmjs.org/regenerator-transform/-/regenerator-transform-0.14.5.tgz", + "integrity": "sha512-eOf6vka5IO151Jfsw2NO9WpGX58W6wWmefK3I1zEGr0lOD0u8rwPaNqQL1aRxUaxLeKO3ArNh3VYg1KbaD+FFw==", + "dev": true, + "dependencies": { + "@babel/runtime": "^7.8.4" + } + }, + "node_modules/regex-parser": { + "version": "2.2.11", + "resolved": "https://registry.npmjs.org/regex-parser/-/regex-parser-2.2.11.tgz", + "integrity": "sha512-jbD/FT0+9MBU2XAZluI7w2OBs1RBi6p9M83nkoZayQXXU9e8Robt69FcZc7wU4eJD/YFTjn1JdCk3rbMJajz8Q==", + "dev": true + }, + "node_modules/regexpu-core": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/regexpu-core/-/regexpu-core-5.0.1.tgz", + "integrity": "sha512-CriEZlrKK9VJw/xQGJpQM5rY88BtuL8DM+AEwvcThHilbxiTAy8vq4iJnd2tqq8wLmjbGZzP7ZcKFjbGkmEFrw==", + "dev": true, + "dependencies": { + "regenerate": "^1.4.2", + "regenerate-unicode-properties": "^10.0.1", + "regjsgen": "^0.6.0", + "regjsparser": "^0.8.2", + "unicode-match-property-ecmascript": "^2.0.0", + "unicode-match-property-value-ecmascript": "^2.0.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/regjsgen": { + "version": "0.6.0", + "resolved": "https://registry.npmjs.org/regjsgen/-/regjsgen-0.6.0.tgz", + "integrity": "sha512-ozE883Uigtqj3bx7OhL1KNbCzGyW2NQZPl6Hs09WTvCuZD5sTI4JY58bkbQWa/Y9hxIsvJ3M8Nbf7j54IqeZbA==", + "dev": true + }, + "node_modules/regjsparser": { + "version": "0.8.4", + "resolved": "https://registry.npmjs.org/regjsparser/-/regjsparser-0.8.4.tgz", + "integrity": "sha512-J3LABycON/VNEu3abOviqGHuB/LOtOQj8SKmfP9anY5GfAVw/SPjwzSjxGjbZXIxbGfqTHtJw58C2Li/WkStmA==", + "dev": true, + "dependencies": { + "jsesc": "~0.5.0" + }, + "bin": { + "regjsparser": "bin/parser" + } + }, + "node_modules/regjsparser/node_modules/jsesc": { + "version": "0.5.0", + "resolved": "https://registry.npmjs.org/jsesc/-/jsesc-0.5.0.tgz", + "integrity": "sha1-597mbjXW/Bb3EP6R1c9p9w8IkR0=", + "dev": true, + "bin": { + "jsesc": "bin/jsesc" + } + }, + "node_modules/relateurl": { + "version": "0.2.7", + "resolved": "https://registry.npmjs.org/relateurl/-/relateurl-0.2.7.tgz", + "integrity": "sha512-G08Dxvm4iDN3MLM0EsP62EDV9IuhXPR6blNz6Utcp7zyV3tr4HVNINt6MpaRWbxoOHT3Q7YN2P+jaHX8vUbgog==", + "dev": true, + "engines": { + "node": ">= 0.10" + } + }, + "node_modules/replace-ext": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/replace-ext/-/replace-ext-1.0.1.tgz", + "integrity": "sha512-yD5BHCe7quCgBph4rMQ+0KkIRKwWCrHDOX1p1Gp6HwjPM5kVoCdKGNhN7ydqqsX6lJEnQDKZ/tFMiEdQ1dvPEw==", + "dev": true, + "engines": { + "node": ">= 0.10" + } + }, + "node_modules/require-directory": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", + "integrity": "sha512-fGxEI7+wsG9xrvdjsrlmL22OMTTiHRwAMroiEeMgq8gzoLC/PQr7RsRDSTLUg/bZAZtF+TVIkHc6/4RIKrui+Q==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/require-from-string": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/require-from-string/-/require-from-string-2.0.2.tgz", + "integrity": "sha512-Xf0nWe6RseziFMu+Ap9biiUbmplq6S9/p+7w7YXP/JBHhrUDDUhwa+vANyubuqfZWTveU//DYVGsDG7RKL/vEw==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/requires-port": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/requires-port/-/requires-port-1.0.0.tgz", + "integrity": "sha512-KigOCHcocU3XODJxsu8i/j8T9tzT4adHiecwORRQ0ZZFcp7ahwXuRU1m+yuO90C5ZUyGeGfocHDI14M3L3yDAQ==", + "dev": true + }, + "node_modules/resolve": { + "version": "1.22.0", + "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.22.0.tgz", + "integrity": "sha512-Hhtrw0nLeSrFQ7phPp4OOcVjLPIeMnRlr5mcnVuMe7M/7eBn98A3hmFRLoFo3DLZkivSYwhRUJTyPyWAk56WLw==", + "dev": true, + "dependencies": { + "is-core-module": "^2.8.1", + "path-parse": "^1.0.7", + "supports-preserve-symlinks-flag": "^1.0.0" + }, + "bin": { + "resolve": "bin/resolve" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/resolve-cwd": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/resolve-cwd/-/resolve-cwd-3.0.0.tgz", + "integrity": "sha512-OrZaX2Mb+rJCpH/6CpSqt9xFVpN++x01XnN2ie9g6P5/3xelLAkXWVADpdz1IHD/KFfEXyE6V0U01OQ3UO2rEg==", + "dev": true, + "dependencies": { + "resolve-from": "^5.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/resolve-cwd/node_modules/resolve-from": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-5.0.0.tgz", + "integrity": "sha512-qYg9KP24dD5qka9J47d0aVky0N+b4fTU89LN9iDnjB5waksiC49rvMB0PrUJQGoTmH50XPiqOvAjDfaijGxYZw==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/resolve-from": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-4.0.0.tgz", + "integrity": "sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g==", + "dev": true, + "engines": { + "node": ">=4" + } + }, + "node_modules/resolve-url": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/resolve-url/-/resolve-url-0.2.1.tgz", + "integrity": "sha1-LGN/53yJOv0qZj/iGqkIAGjiBSo=", + "deprecated": "https://github.com/lydell/resolve-url#deprecated", + "dev": true + }, + "node_modules/resolve-url-loader": { + "version": "3.1.5", + "resolved": "https://registry.npmjs.org/resolve-url-loader/-/resolve-url-loader-3.1.5.tgz", + "integrity": "sha512-mgFMCmrV/tA4738EsFmPFE5/MaqSgUMe8LK971kVEKA/RrNVb7+VqFsg/qmKyythf34eyq476qIobP/gfFBGSQ==", + "dev": true, + "dependencies": { + "adjust-sourcemap-loader": "3.0.0", + "camelcase": "5.3.1", + "compose-function": "3.0.3", + "convert-source-map": "1.7.0", + "es6-iterator": "2.0.3", + "loader-utils": "^1.2.3", + "postcss": "7.0.36", + "rework": "1.0.1", + "rework-visit": "1.0.0", + "source-map": "0.6.1" + }, + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/resolve-url-loader/node_modules/convert-source-map": { + "version": "1.7.0", + "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-1.7.0.tgz", + "integrity": "sha512-4FJkXzKXEDB1snCFZlLP4gpC3JILicCpGbzG9f9G7tGqGCzETQ2hWPrcinA9oU4wtf2biUaEH5065UnMeR33oA==", + "dev": true, + "dependencies": { + "safe-buffer": "~5.1.1" + } + }, + "node_modules/resolve-url-loader/node_modules/postcss": { + "version": "7.0.36", + "resolved": "https://registry.npmjs.org/postcss/-/postcss-7.0.36.tgz", + "integrity": "sha512-BebJSIUMwJHRH0HAQoxN4u1CN86glsrwsW0q7T+/m44eXOUAxSNdHRkNZPYz5vVUbg17hFgOQDE7fZk7li3pZw==", + "dev": true, + "dependencies": { + "chalk": "^2.4.2", + "source-map": "^0.6.1", + "supports-color": "^6.1.0" + }, + "engines": { + "node": ">=6.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + } + }, + "node_modules/resolve-url-loader/node_modules/supports-color": { + "version": "6.1.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-6.1.0.tgz", + "integrity": "sha512-qe1jfm1Mg7Nq/NSh6XE24gPXROEVsWHxC1LIx//XNlD9iw7YZQGjZNjYN7xGaEG6iKdA8EtNFW6R0gjnVXp+wQ==", + "dev": true, + "dependencies": { + "has-flag": "^3.0.0" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/retry": { + "version": "0.13.1", + "resolved": "https://registry.npmjs.org/retry/-/retry-0.13.1.tgz", + "integrity": "sha512-XQBQ3I8W1Cge0Seh+6gjj03LbmRFWuoszgK9ooCpwYIrhhoO80pfq4cUkU5DkknwfOfFteRwlZ56PYOGYyFWdg==", + "dev": true, + "engines": { + "node": ">= 4" + } + }, + "node_modules/reusify": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/reusify/-/reusify-1.0.4.tgz", + "integrity": "sha512-U9nH88a3fc/ekCF1l0/UP1IosiuIjyTh7hBvXVMHYgVcfGvt897Xguj2UOLDeI5BG2m7/uwyaLVT6fbtCwTyzw==", + "dev": true, + "engines": { + "iojs": ">=1.0.0", + "node": ">=0.10.0" + } + }, + "node_modules/rework": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/rework/-/rework-1.0.1.tgz", + "integrity": "sha1-MIBqhBNCtUUQqkEQhQzUhTQUSqc=", + "dev": true, + "dependencies": { + "convert-source-map": "^0.3.3", + "css": "^2.0.0" + } + }, + "node_modules/rework-visit": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/rework-visit/-/rework-visit-1.0.0.tgz", + "integrity": "sha1-mUWygD8hni96ygCtuLyfZA+ELJo=", + "dev": true + }, + "node_modules/rework/node_modules/convert-source-map": { + "version": "0.3.5", + "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-0.3.5.tgz", + "integrity": "sha1-8dgClQr33SYxof6+BZZVDIarMZA=", + "dev": true + }, + "node_modules/rimraf": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-3.0.2.tgz", + "integrity": "sha512-JZkJMZkAGFFPP2YqXZXPbMlMBgsxzE8ILs4lMIX/2o0L9UBw9O/Y3o6wFw/i9YLapcUJWwqbi3kdxIPdC62TIA==", + "deprecated": "Rimraf versions prior to v4 are no longer supported", + "dev": true, + "dependencies": { + "glob": "^7.1.3" + }, + "bin": { + "rimraf": "bin.js" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, + "node_modules/ripemd160": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/ripemd160/-/ripemd160-2.0.2.tgz", + "integrity": "sha512-ii4iagi25WusVoiC4B4lq7pbXfAp3D9v5CwfkY33vffw2+pkDjY1D8GaN7spsxvCSx8dkPqOZCEZyfxcmJG2IA==", + "dev": true, + "dependencies": { + "hash-base": "^3.0.0", + "inherits": "^2.0.1" + } + }, + "node_modules/run-parallel": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/run-parallel/-/run-parallel-1.2.0.tgz", + "integrity": "sha512-5l4VyZR86LZ/lDxZTR6jqL8AFE2S0IFLMP26AbjsLVADxHdhB/c0GUsH+y39UfCi3dzz8OlQuPmnaJOMoDHQBA==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "dependencies": { + "queue-microtask": "^1.2.2" + } + }, + "node_modules/safe-buffer": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", + "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==", + "dev": true + }, + "node_modules/safer-buffer": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", + "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==", + "dev": true + }, + "node_modules/sass": { + "version": "1.49.7", + "resolved": "https://registry.npmjs.org/sass/-/sass-1.49.7.tgz", + "integrity": "sha512-13dml55EMIR2rS4d/RDHHP0sXMY3+30e1TKsyXaSz3iLWVoDWEoboY8WzJd5JMnxrRHffKO3wq2mpJ0jxRJiEQ==", + "dev": true, + "dependencies": { + "chokidar": ">=3.0.0 <4.0.0", + "immutable": "^4.0.0", + "source-map-js": ">=0.6.2 <2.0.0" + }, + "bin": { + "sass": "sass.js" + }, + "engines": { + "node": ">=12.0.0" + } + }, + "node_modules/sass-loader": { + "version": "8.0.2", + "resolved": "https://registry.npmjs.org/sass-loader/-/sass-loader-8.0.2.tgz", + "integrity": "sha512-7o4dbSK8/Ol2KflEmSco4jTjQoV988bM82P9CZdmo9hR3RLnvNc0ufMNdMrB0caq38JQ/FgF4/7RcbcfKzxoFQ==", + "dev": true, + "dependencies": { + "clone-deep": "^4.0.1", + "loader-utils": "^1.2.3", + "neo-async": "^2.6.1", + "schema-utils": "^2.6.1", + "semver": "^6.3.0" + }, + "engines": { + "node": ">= 8.9.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/webpack" + }, + "peerDependencies": { + "fibers": ">= 3.1.0", + "node-sass": "^4.0.0", + "sass": "^1.3.0", + "webpack": "^4.36.0 || ^5.0.0" + }, + "peerDependenciesMeta": { + "fibers": { + "optional": true + }, + "node-sass": { + "optional": true + }, + "sass": { + "optional": true + } + } + }, + "node_modules/schema-utils": { + "version": "2.7.1", + "resolved": "https://registry.npmjs.org/schema-utils/-/schema-utils-2.7.1.tgz", + "integrity": "sha512-SHiNtMOUGWBQJwzISiVYKu82GiV4QYGePp3odlY1tuKO7gPtphAT5R/py0fA6xtbgLL/RvtJZnU9b8s0F1q0Xg==", + "dev": true, + "dependencies": { + "@types/json-schema": "^7.0.5", + "ajv": "^6.12.4", + "ajv-keywords": "^3.5.2" + }, + "engines": { + "node": ">= 8.9.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/webpack" + } + }, + "node_modules/select-hose": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/select-hose/-/select-hose-2.0.0.tgz", + "integrity": "sha512-mEugaLK+YfkijB4fx0e6kImuJdCIt2LxCRcbEYPqRGCs4F2ogyfZU5IAZRdjCP8JPq2AtdNoC/Dux63d9Kiryg==", + "dev": true + }, + "node_modules/selfsigned": { + "version": "2.4.1", + "resolved": "https://registry.npmjs.org/selfsigned/-/selfsigned-2.4.1.tgz", + "integrity": "sha512-th5B4L2U+eGLq1TVh7zNRGBapioSORUeymIydxgFpwww9d2qyKvtuPU2jJuHvYAwwqi2Y596QBL3eEqcPEYL8Q==", + "dev": true, + "dependencies": { + "@types/node-forge": "^1.3.0", + "node-forge": "^1" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/semver": { + "version": "6.3.1", + "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz", + "integrity": "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==", + "dev": true, + "bin": { + "semver": "bin/semver.js" + } + }, + "node_modules/send": { + "version": "0.18.0", + "resolved": "https://registry.npmjs.org/send/-/send-0.18.0.tgz", + "integrity": "sha512-qqWzuOjSFOuqPjFe4NOsMLafToQQwBSOEpS+FwEt3A2V3vKubTquT3vmLTQpFgMXp8AlFWFuP1qKaJZOtPpVXg==", + "dev": true, + "dependencies": { + "debug": "2.6.9", + "depd": "2.0.0", + "destroy": "1.2.0", + "encodeurl": "~1.0.2", + "escape-html": "~1.0.3", + "etag": "~1.8.1", + "fresh": "0.5.2", + "http-errors": "2.0.0", + "mime": "1.6.0", + "ms": "2.1.3", + "on-finished": "2.4.1", + "range-parser": "~1.2.1", + "statuses": "2.0.1" + }, + "engines": { + "node": ">= 0.8.0" + } + }, + "node_modules/send/node_modules/ms": { + "version": "2.1.3", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz", + "integrity": "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==", + "dev": true + }, + "node_modules/serialize-javascript": { + "version": "6.0.2", + "resolved": "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-6.0.2.tgz", + "integrity": "sha512-Saa1xPByTTq2gdeFZYLLo+RFE35NHZkAbqZeWNd3BpzppeVisAqpDjcp8dyf6uIvEqJRd46jemmyA4iFIeVk8g==", + "dev": true, + "dependencies": { + "randombytes": "^2.1.0" + } + }, + "node_modules/serve-index": { + "version": "1.9.1", + "resolved": "https://registry.npmjs.org/serve-index/-/serve-index-1.9.1.tgz", + "integrity": "sha512-pXHfKNP4qujrtteMrSBb0rc8HJ9Ms/GrXwcUtUtD5s4ewDJI8bT3Cz2zTVRMKtri49pLx2e0Ya8ziP5Ya2pZZw==", + "dev": true, + "dependencies": { + "accepts": "~1.3.4", + "batch": "0.6.1", + "debug": "2.6.9", + "escape-html": "~1.0.3", + "http-errors": "~1.6.2", + "mime-types": "~2.1.17", + "parseurl": "~1.3.2" + }, + "engines": { + "node": ">= 0.8.0" + } + }, + "node_modules/serve-index/node_modules/depd": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/depd/-/depd-1.1.2.tgz", + "integrity": "sha512-7emPTl6Dpo6JRXOXjLRxck+FlLRX5847cLKEn00PLAgc3g2hTZZgr+e4c2v6QpSmLeFP3n5yUo7ft6avBK/5jQ==", + "dev": true, + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/serve-index/node_modules/http-errors": { + "version": "1.6.3", + "resolved": "https://registry.npmjs.org/http-errors/-/http-errors-1.6.3.tgz", + "integrity": "sha512-lks+lVC8dgGyh97jxvxeYTWQFvh4uw4yC12gVl63Cg30sjPX4wuGcdkICVXDAESr6OJGjqGA8Iz5mkeN6zlD7A==", + "dev": true, + "dependencies": { + "depd": "~1.1.2", + "inherits": "2.0.3", + "setprototypeof": "1.1.0", + "statuses": ">= 1.4.0 < 2" + }, + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/serve-index/node_modules/inherits": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.3.tgz", + "integrity": "sha512-x00IRNXNy63jwGkJmzPigoySHbaqpNuzKbBOmzK+g2OdZpQ9w+sxCN+VSB3ja7IAge2OP2qpfxTjeNcyjmW1uw==", + "dev": true + }, + "node_modules/serve-index/node_modules/setprototypeof": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/setprototypeof/-/setprototypeof-1.1.0.tgz", + "integrity": "sha512-BvE/TwpZX4FXExxOxZyRGQQv651MSwmWKZGqvmPcRIjDqWub67kTKuIMx43cZZrS/cBBzwBcNDWoFxt2XEFIpQ==", + "dev": true + }, + "node_modules/serve-index/node_modules/statuses": { + "version": "1.5.0", + "resolved": "https://registry.npmjs.org/statuses/-/statuses-1.5.0.tgz", + "integrity": "sha512-OpZ3zP+jT1PI7I8nemJX4AKmAX070ZkYPVWV/AaKTJl+tXCTGyVdC1a4SL8RUQYEwk/f34ZX8UTykN68FwrqAA==", + "dev": true, + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/serve-static": { + "version": "1.15.0", + "resolved": "https://registry.npmjs.org/serve-static/-/serve-static-1.15.0.tgz", + "integrity": "sha512-XGuRDNjXUijsUL0vl6nSD7cwURuzEgglbOaFuZM9g3kwDXOWVTck0jLzjPzGD+TazWbboZYu52/9/XPdUgne9g==", + "dev": true, + "dependencies": { + "encodeurl": "~1.0.2", + "escape-html": "~1.0.3", + "parseurl": "~1.3.3", + "send": "0.18.0" + }, + "engines": { + "node": ">= 0.8.0" + } + }, + "node_modules/set-function-length": { + "version": "1.2.2", + "resolved": "https://registry.npmjs.org/set-function-length/-/set-function-length-1.2.2.tgz", + "integrity": "sha512-pgRc4hJ4/sNjWCSS9AmnS40x3bNMDTknHgL5UaMBTMyJnU90EgWh1Rz+MC9eFu4BuN/UwZjKQuY/1v3rM7HMfg==", + "dev": true, + "dependencies": { + "define-data-property": "^1.1.4", + "es-errors": "^1.3.0", + "function-bind": "^1.1.2", + "get-intrinsic": "^1.2.4", + "gopd": "^1.0.1", + "has-property-descriptors": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/setimmediate": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/setimmediate/-/setimmediate-1.0.5.tgz", + "integrity": "sha1-KQy7Iy4waULX1+qbg3Mqt4VvgoU=", + "dev": true + }, + "node_modules/setprototypeof": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/setprototypeof/-/setprototypeof-1.2.0.tgz", + "integrity": "sha512-E5LDX7Wrp85Kil5bhZv46j8jOeboKq5JMmYM3gVGdGH8xFpPWXUMsNrlODCrkoxMEeNi/XZIwuRvY4XNwYMJpw==", + "dev": true + }, + "node_modules/sha.js": { + "version": "2.4.11", + "resolved": "https://registry.npmjs.org/sha.js/-/sha.js-2.4.11.tgz", + "integrity": "sha512-QMEp5B7cftE7APOjk5Y6xgrbWu+WkLVQwk8JNjZ8nKRciZaByEW6MubieAiToS7+dwvrjGhH8jRXz3MVd0AYqQ==", + "dev": true, + "dependencies": { + "inherits": "^2.0.1", + "safe-buffer": "^5.0.1" + }, + "bin": { + "sha.js": "bin.js" + } + }, + "node_modules/shallow-clone": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/shallow-clone/-/shallow-clone-3.0.1.tgz", + "integrity": "sha512-/6KqX+GVUdqPuPPd2LxDDxzX6CAbjJehAAOKlNpqqUpAqPM6HeL8f+o3a+JsyGjn2lv0WY8UsTgUJjU9Ok55NA==", + "dev": true, + "dependencies": { + "kind-of": "^6.0.2" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/shallow-clone/node_modules/kind-of": { + "version": "6.0.3", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-6.0.3.tgz", + "integrity": "sha512-dcS1ul+9tmeD95T+x28/ehLgd9mENa3LsvDTtzm3vyBEO7RPptvAD+t44WVXaUjTBRcrpFeFlC8WCruUR456hw==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/shebang-command": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-2.0.0.tgz", + "integrity": "sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==", + "dev": true, + "dependencies": { + "shebang-regex": "^3.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/shebang-regex": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-3.0.0.tgz", + "integrity": "sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/shell-quote": { + "version": "1.8.1", + "resolved": "https://registry.npmjs.org/shell-quote/-/shell-quote-1.8.1.tgz", + "integrity": "sha512-6j1W9l1iAs/4xYBI1SYOVZyFcCis9b4KCLQ8fgAGG07QvzaRLVVRQvAy85yNmmZSjYjg4MWh4gNvlPujU/5LpA==", + "dev": true, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/shellwords": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/shellwords/-/shellwords-0.1.1.tgz", + "integrity": "sha512-vFwSUfQvqybiICwZY5+DAWIPLKsWO31Q91JSKl3UYv+K5c2QRPzn0qzec6QPu1Qc9eHYItiP3NdJqNVqetYAww==", + "dev": true + }, + "node_modules/side-channel": { + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/side-channel/-/side-channel-1.0.6.tgz", + "integrity": "sha512-fDW/EZ6Q9RiO8eFG8Hj+7u/oW+XrPTIChwCOM2+th2A6OblDtYYIpve9m+KvI9Z4C9qSEXlaGR6bTEYHReuglA==", + "dev": true, + "dependencies": { + "call-bind": "^1.0.7", + "es-errors": "^1.3.0", + "get-intrinsic": "^1.2.4", + "object-inspect": "^1.13.1" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/signal-exit": { + "version": "3.0.7", + "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.7.tgz", + "integrity": "sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ==", + "dev": true + }, + "node_modules/slash": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/slash/-/slash-3.0.0.tgz", + "integrity": "sha512-g9Q1haeby36OSStwb4ntCGGGaKsaVSjQ68fBxoQcutl5fS1vuY18H3wSt3jFyFtrkx+Kz0V1G85A4MyAdDMi2Q==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/sockjs": { + "version": "0.3.24", + "resolved": "https://registry.npmjs.org/sockjs/-/sockjs-0.3.24.tgz", + "integrity": "sha512-GJgLTZ7vYb/JtPSSZ10hsOYIvEYsjbNU+zPdIHcUaWVNUEPivzxku31865sSSud0Da0W4lEeOPlmw93zLQchuQ==", + "dev": true, + "dependencies": { + "faye-websocket": "^0.11.3", + "uuid": "^8.3.2", + "websocket-driver": "^0.7.4" + } + }, + "node_modules/source-list-map": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/source-list-map/-/source-list-map-2.0.1.tgz", + "integrity": "sha512-qnQ7gVMxGNxsiL4lEuJwe/To8UnK7fAnmbGEEH8RpLouuKbeEm0lhbQVFIrNSuB+G7tVrAlVsZgETT5nljf+Iw==", + "dev": true + }, + "node_modules/source-map": { + "version": "0.6.1", + "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", + "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/source-map-js": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/source-map-js/-/source-map-js-1.2.0.tgz", + "integrity": "sha512-itJW8lvSA0TXEphiRoawsCksnlf8SyvmFzIhltqAHluXd88pkCd+cXJVHTDwdCr0IzwptSm035IHQktUu1QUMg==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/source-map-resolve": { + "version": "0.5.3", + "resolved": "https://registry.npmjs.org/source-map-resolve/-/source-map-resolve-0.5.3.tgz", + "integrity": "sha512-Htz+RnsXWk5+P2slx5Jh3Q66vhQj1Cllm0zvnaY98+NFx+Dv2CF/f5O/t8x+KaNdrdIAsruNzoh/KpialbqAnw==", + "deprecated": "See https://github.com/lydell/source-map-resolve#deprecated", + "dev": true, + "dependencies": { + "atob": "^2.1.2", + "decode-uri-component": "^0.2.0", + "resolve-url": "^0.2.1", + "source-map-url": "^0.4.0", + "urix": "^0.1.0" + } + }, + "node_modules/source-map-support": { + "version": "0.5.21", + "resolved": "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.21.tgz", + "integrity": "sha512-uBHU3L3czsIyYXKX88fdrGovxdSCoTGDRZ6SYXtSRxLZUzHg5P/66Ht6uoUlHu9EZod+inXhKo3qQgwXUT/y1w==", + "dev": true, + "dependencies": { + "buffer-from": "^1.0.0", + "source-map": "^0.6.0" + } + }, + "node_modules/source-map-url": { + "version": "0.4.1", + "resolved": "https://registry.npmjs.org/source-map-url/-/source-map-url-0.4.1.tgz", + "integrity": "sha512-cPiFOTLUKvJFIg4SKVScy4ilPPW6rFgMgfuZJPNoDuMs3nC1HbMUycBoJw77xFIp6z1UJQJOfx6C9GMH80DiTw==", + "deprecated": "See https://github.com/lydell/source-map-url#deprecated", + "dev": true + }, + "node_modules/sourcemap-codec": { + "version": "1.4.8", + "resolved": "https://registry.npmjs.org/sourcemap-codec/-/sourcemap-codec-1.4.8.tgz", + "integrity": "sha512-9NykojV5Uih4lgo5So5dtw+f0JgJX30KCNI8gwhz2J9A15wD0Ml6tjHKwf6fTSa6fAdVBdZeNOs9eJ71qCk8vA==", + "dev": true + }, + "node_modules/spdy": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/spdy/-/spdy-4.0.2.tgz", + "integrity": "sha512-r46gZQZQV+Kl9oItvl1JZZqJKGr+oEkB08A6BzkiR7593/7IbtuncXHd2YoYeTsG4157ZssMu9KYvUHLcjcDoA==", + "dev": true, + "dependencies": { + "debug": "^4.1.0", + "handle-thing": "^2.0.0", + "http-deceiver": "^1.2.7", + "select-hose": "^2.0.0", + "spdy-transport": "^3.0.0" + }, + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/spdy-transport": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/spdy-transport/-/spdy-transport-3.0.0.tgz", + "integrity": "sha512-hsLVFE5SjA6TCisWeJXFKniGGOpBgMLmerfO2aCyCU5s7nJ/rpAepqmFifv/GCbSbueEeAJJnmSQ2rKC/g8Fcw==", + "dev": true, + "dependencies": { + "debug": "^4.1.0", + "detect-node": "^2.0.4", + "hpack.js": "^2.1.6", + "obuf": "^1.1.2", + "readable-stream": "^3.0.6", + "wbuf": "^1.7.3" + } + }, + "node_modules/spdy-transport/node_modules/debug": { + "version": "4.3.5", + "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.5.tgz", + "integrity": "sha512-pt0bNEmneDIvdL1Xsd9oDQ/wrQRkXDT4AUWlNZNPKvW5x/jyO9VFXkJUP07vQ2upmw5PlaITaPKc31jK13V+jg==", + "dev": true, + "dependencies": { + "ms": "2.1.2" + }, + "engines": { + "node": ">=6.0" + }, + "peerDependenciesMeta": { + "supports-color": { + "optional": true + } + } + }, + "node_modules/spdy-transport/node_modules/ms": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", + "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==", + "dev": true + }, + "node_modules/spdy-transport/node_modules/readable-stream": { + "version": "3.6.2", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz", + "integrity": "sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==", + "dev": true, + "dependencies": { + "inherits": "^2.0.3", + "string_decoder": "^1.1.1", + "util-deprecate": "^1.0.1" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/spdy/node_modules/debug": { + "version": "4.3.5", + "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.5.tgz", + "integrity": "sha512-pt0bNEmneDIvdL1Xsd9oDQ/wrQRkXDT4AUWlNZNPKvW5x/jyO9VFXkJUP07vQ2upmw5PlaITaPKc31jK13V+jg==", + "dev": true, + "dependencies": { + "ms": "2.1.2" + }, + "engines": { + "node": ">=6.0" + }, + "peerDependenciesMeta": { + "supports-color": { + "optional": true + } + } + }, + "node_modules/spdy/node_modules/ms": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", + "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==", + "dev": true + }, + "node_modules/stable": { + "version": "0.1.8", + "resolved": "https://registry.npmjs.org/stable/-/stable-0.1.8.tgz", + "integrity": "sha512-ji9qxRnOVfcuLDySj9qzhGSEFVobyt1kIOSkj1qZzYLzq7Tos/oUUWvotUPQLlrsidqsK6tBH89Bc9kL5zHA6w==", + "deprecated": "Modern JS already guarantees Array#sort() is a stable sort, so this library is deprecated. See the compatibility table on MDN: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/sort#browser_compatibility", + "dev": true + }, + "node_modules/statuses": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/statuses/-/statuses-2.0.1.tgz", + "integrity": "sha512-RwNA9Z/7PrK06rYLIzFMlaF+l73iwpzsqRIFgbMLbTcLD6cOao82TaWefPXQvB2fOC4AjuYSEndS7N/mTCbkdQ==", + "dev": true, + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/std-env": { + "version": "3.7.0", + "resolved": "https://registry.npmjs.org/std-env/-/std-env-3.7.0.tgz", + "integrity": "sha512-JPbdCEQLj1w5GilpiHAx3qJvFndqybBysA3qUOnznweH4QbNYUsW/ea8QzSrnh0vNsezMMw5bcVool8lM0gwzg==", + "dev": true + }, + "node_modules/stream-browserify": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/stream-browserify/-/stream-browserify-2.0.2.tgz", + "integrity": "sha512-nX6hmklHs/gr2FuxYDltq8fJA1GDlxKQCz8O/IM4atRqBH8OORmBNgfvW5gG10GT/qQ9u0CzIvr2X5Pkt6ntqg==", + "dev": true, + "dependencies": { + "inherits": "~2.0.1", + "readable-stream": "^2.0.2" + } + }, + "node_modules/stream-http": { + "version": "2.8.3", + "resolved": "https://registry.npmjs.org/stream-http/-/stream-http-2.8.3.tgz", + "integrity": "sha512-+TSkfINHDo4J+ZobQLWiMouQYB+UVYFttRA94FpEzzJ7ZdqcL4uUUQ7WkdkI4DSozGmgBUE/a47L+38PenXhUw==", + "dev": true, + "dependencies": { + "builtin-status-codes": "^3.0.0", + "inherits": "^2.0.1", + "readable-stream": "^2.3.6", + "to-arraybuffer": "^1.0.0", + "xtend": "^4.0.0" + } + }, + "node_modules/string_decoder": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", + "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", + "dev": true, + "dependencies": { + "safe-buffer": "~5.1.0" + } + }, + "node_modules/string-width": { + "version": "4.2.3", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", + "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", + "dev": true, + "dependencies": { + "emoji-regex": "^8.0.0", + "is-fullwidth-code-point": "^3.0.0", + "strip-ansi": "^6.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/strip-ansi": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", + "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", + "dev": true, + "dependencies": { + "ansi-regex": "^5.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/strip-final-newline": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/strip-final-newline/-/strip-final-newline-2.0.0.tgz", + "integrity": "sha512-BrpvfNAE3dcvq7ll3xVumzjKjZQ5tI1sEUIKr3Uoks0XUl45St3FlatVqef9prk4jRDzhW6WZg+3bk93y6pLjA==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/style-loader": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/style-loader/-/style-loader-2.0.0.tgz", + "integrity": "sha512-Z0gYUJmzZ6ZdRUqpg1r8GsaFKypE+3xAzuFeMuoHgjc9KZv3wMyCRjQIWEbhoFSq7+7yoHXySDJyyWQaPajeiQ==", + "dev": true, + "dependencies": { + "loader-utils": "^2.0.0", + "schema-utils": "^3.0.0" + }, + "engines": { + "node": ">= 10.13.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/webpack" + }, + "peerDependencies": { + "webpack": "^4.0.0 || ^5.0.0" + } + }, + "node_modules/style-loader/node_modules/loader-utils": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/loader-utils/-/loader-utils-2.0.4.tgz", + "integrity": "sha512-xXqpXoINfFhgua9xiqD8fPFHgkoq1mmmpE92WlDbm9rNRd/EbRb+Gqf908T2DMfuHjjJlksiK2RbHVOdD/MqSw==", + "dev": true, + "dependencies": { + "big.js": "^5.2.2", + "emojis-list": "^3.0.0", + "json5": "^2.1.2" + }, + "engines": { + "node": ">=8.9.0" + } + }, + "node_modules/style-loader/node_modules/schema-utils": { + "version": "3.3.0", + "resolved": "https://registry.npmjs.org/schema-utils/-/schema-utils-3.3.0.tgz", + "integrity": "sha512-pN/yOAvcC+5rQ5nERGuwrjLlYvLTbCibnZ1I7B1LaiAz9BRBlE9GMgE/eqV30P7aJQUf7Ddimy/RsbYO/GrVGg==", + "dev": true, + "dependencies": { + "@types/json-schema": "^7.0.8", + "ajv": "^6.12.5", + "ajv-keywords": "^3.5.2" + }, + "engines": { + "node": ">= 10.13.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/webpack" + } + }, + "node_modules/stylehacks": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/stylehacks/-/stylehacks-5.1.1.tgz", + "integrity": "sha512-sBpcd5Hx7G6seo7b1LkpttvTz7ikD0LlH5RmdcBNb6fFR0Fl7LQwHDFr300q4cwUqi+IYrFGmsIHieMBfnN/Bw==", + "dev": true, + "dependencies": { + "browserslist": "^4.21.4", + "postcss-selector-parser": "^6.0.4" + }, + "engines": { + "node": "^10 || ^12 || >=14.0" + }, + "peerDependencies": { + "postcss": "^8.2.15" + } + }, + "node_modules/supports-color": { + "version": "5.5.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", + "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", + "dev": true, + "dependencies": { + "has-flag": "^3.0.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/supports-preserve-symlinks-flag": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz", + "integrity": "sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==", + "dev": true, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/svgo": { + "version": "2.8.0", + "resolved": "https://registry.npmjs.org/svgo/-/svgo-2.8.0.tgz", + "integrity": "sha512-+N/Q9kV1+F+UeWYoSiULYo4xYSDQlTgb+ayMobAXPwMnLvop7oxKMo9OzIrX5x3eS4L4f2UHhc9axXwY8DpChg==", + "dev": true, + "dependencies": { + "@trysound/sax": "0.2.0", + "commander": "^7.2.0", + "css-select": "^4.1.3", + "css-tree": "^1.1.3", + "csso": "^4.2.0", + "picocolors": "^1.0.0", + "stable": "^0.1.8" + }, + "bin": { + "svgo": "bin/svgo" + }, + "engines": { + "node": ">=10.13.0" + } + }, + "node_modules/svgo/node_modules/commander": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/commander/-/commander-7.2.0.tgz", + "integrity": "sha512-QrWXB+ZQSVPmIWIhtEO9H+gwHaMGYiF5ChvoJ+K9ZGHG/sVsa6yiesAD1GC/x46sET00Xlwo1u49RVVVzvcSkw==", + "dev": true, + "engines": { + "node": ">= 10" + } + }, + "node_modules/tapable": { + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/tapable/-/tapable-2.2.1.tgz", + "integrity": "sha512-GNzQvQTOIP6RyTfE2Qxb8ZVlNmw0n88vp1szwWRimP02mnTsx3Wtn5qRdqY9w2XduFNUgvOwhNnQsjwCp+kqaQ==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/terser": { + "version": "5.31.1", + "resolved": "https://registry.npmjs.org/terser/-/terser-5.31.1.tgz", + "integrity": "sha512-37upzU1+viGvuFtBo9NPufCb9dwM0+l9hMxYyWfBA+fbwrPqNJAhbZ6W47bBFnZHKHTUBnMvi87434qq+qnxOg==", + "dev": true, + "dependencies": { + "@jridgewell/source-map": "^0.3.3", + "acorn": "^8.8.2", + "commander": "^2.20.0", + "source-map-support": "~0.5.20" + }, + "bin": { + "terser": "bin/terser" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/terser-webpack-plugin": { + "version": "5.3.10", + "resolved": "https://registry.npmjs.org/terser-webpack-plugin/-/terser-webpack-plugin-5.3.10.tgz", + "integrity": "sha512-BKFPWlPDndPs+NGGCr1U59t0XScL5317Y0UReNrHaw9/FwhPENlq6bfgs+4yPfyP51vqC1bQ4rp1EfXW5ZSH9w==", + "dev": true, + "dependencies": { + "@jridgewell/trace-mapping": "^0.3.20", + "jest-worker": "^27.4.5", + "schema-utils": "^3.1.1", + "serialize-javascript": "^6.0.1", + "terser": "^5.26.0" + }, + "engines": { + "node": ">= 10.13.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/webpack" + }, + "peerDependencies": { + "webpack": "^5.1.0" + }, + "peerDependenciesMeta": { + "@swc/core": { + "optional": true + }, + "esbuild": { + "optional": true + }, + "uglify-js": { + "optional": true + } + } + }, + "node_modules/terser-webpack-plugin/node_modules/@jridgewell/trace-mapping": { + "version": "0.3.25", + "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.25.tgz", + "integrity": "sha512-vNk6aEwybGtawWmy/PzwnGDOjCkLWSD2wqvjGGAgOAwCGWySYXfYoxt00IJkTF+8Lb57DwOb3Aa0o9CApepiYQ==", + "dev": true, + "dependencies": { + "@jridgewell/resolve-uri": "^3.1.0", + "@jridgewell/sourcemap-codec": "^1.4.14" + } + }, + "node_modules/terser-webpack-plugin/node_modules/schema-utils": { + "version": "3.3.0", + "resolved": "https://registry.npmjs.org/schema-utils/-/schema-utils-3.3.0.tgz", + "integrity": "sha512-pN/yOAvcC+5rQ5nERGuwrjLlYvLTbCibnZ1I7B1LaiAz9BRBlE9GMgE/eqV30P7aJQUf7Ddimy/RsbYO/GrVGg==", + "dev": true, + "dependencies": { + "@types/json-schema": "^7.0.8", + "ajv": "^6.12.5", + "ajv-keywords": "^3.5.2" + }, + "engines": { + "node": ">= 10.13.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/webpack" + } + }, + "node_modules/thunky": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/thunky/-/thunky-1.1.0.tgz", + "integrity": "sha512-eHY7nBftgThBqOyHGVN+l8gF0BucP09fMo0oO/Lb0w1OF80dJv+lDVpXG60WMQvkcxAkNybKsrEIE3ZtKGmPrA==", + "dev": true + }, + "node_modules/timers-browserify": { + "version": "2.0.12", + "resolved": "https://registry.npmjs.org/timers-browserify/-/timers-browserify-2.0.12.tgz", + "integrity": "sha512-9phl76Cqm6FhSX9Xe1ZUAMLtm1BLkKj2Qd5ApyWkXzsMRaA7dgr81kf4wJmQf/hAvg8EEyJxDo3du/0KlhPiKQ==", + "dev": true, + "dependencies": { + "setimmediate": "^1.0.4" + }, + "engines": { + "node": ">=0.6.0" + } + }, + "node_modules/to-arraybuffer": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/to-arraybuffer/-/to-arraybuffer-1.0.1.tgz", + "integrity": "sha1-fSKbH8xjfkZsoIEYCDanqr/4P0M=", + "dev": true + }, + "node_modules/to-fast-properties": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/to-fast-properties/-/to-fast-properties-2.0.0.tgz", + "integrity": "sha1-3F5pjL0HkmW8c+A3doGk5Og/YW4=", + "dev": true, + "engines": { + "node": ">=4" + } + }, + "node_modules/to-regex-range": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz", + "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==", + "dev": true, + "dependencies": { + "is-number": "^7.0.0" + }, + "engines": { + "node": ">=8.0" + } + }, + "node_modules/toidentifier": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/toidentifier/-/toidentifier-1.0.1.tgz", + "integrity": "sha512-o5sSPKEkg/DIQNmH43V0/uerLrpzVedkUh8tGNvaeXpfpuwjKenlSox/2O/BTlZUtEe+JG7s5YhEz608PlAHRA==", + "dev": true, + "engines": { + "node": ">=0.6" + } + }, + "node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "dev": true + }, + "node_modules/tty-browserify": { + "version": "0.0.0", + "resolved": "https://registry.npmjs.org/tty-browserify/-/tty-browserify-0.0.0.tgz", + "integrity": "sha1-oVe6QC2iTpv5V/mqadUk7tQpAaY=", + "dev": true + }, + "node_modules/type": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/type/-/type-1.2.0.tgz", + "integrity": "sha512-+5nt5AAniqsCnu2cEQQdpzCAh33kVx8n0VoFidKpB1dVVLAN/F+bgVOqOJqOnEnrhp222clB5p3vUlD+1QAnfg==", + "dev": true + }, + "node_modules/type-is": { + "version": "1.6.18", + "resolved": "https://registry.npmjs.org/type-is/-/type-is-1.6.18.tgz", + "integrity": "sha512-TkRKr9sUTxEH8MdfuCSP7VizJyzRNMjj2J2do2Jr3Kym598JVdEksuzPQCnlFPW4ky9Q+iA+ma9BGm06XQBy8g==", + "dev": true, + "dependencies": { + "media-typer": "0.3.0", + "mime-types": "~2.1.24" + }, + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/undici-types": { + "version": "5.26.5", + "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-5.26.5.tgz", + "integrity": "sha512-JlCMO+ehdEIKqlFxk6IfVoAUVmgz7cU7zD/h9XZ0qzeosSHmUJVOzSQvvYSYWXkFXC+IfLKSIffhv0sVZup6pA==", + "dev": true + }, + "node_modules/unicode-canonical-property-names-ecmascript": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/unicode-canonical-property-names-ecmascript/-/unicode-canonical-property-names-ecmascript-2.0.0.tgz", + "integrity": "sha512-yY5PpDlfVIU5+y/BSCxAJRBIS1Zc2dDG3Ujq+sR0U+JjUevW2JhocOF+soROYDSaAezOzOKuyyixhD6mBknSmQ==", + "dev": true, + "engines": { + "node": ">=4" + } + }, + "node_modules/unicode-match-property-ecmascript": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/unicode-match-property-ecmascript/-/unicode-match-property-ecmascript-2.0.0.tgz", + "integrity": "sha512-5kaZCrbp5mmbz5ulBkDkbY0SsPOjKqVS35VpL9ulMPfSl0J0Xsm+9Evphv9CoIZFwre7aJoa94AY6seMKGVN5Q==", + "dev": true, + "dependencies": { + "unicode-canonical-property-names-ecmascript": "^2.0.0", + "unicode-property-aliases-ecmascript": "^2.0.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/unicode-match-property-value-ecmascript": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/unicode-match-property-value-ecmascript/-/unicode-match-property-value-ecmascript-2.0.0.tgz", + "integrity": "sha512-7Yhkc0Ye+t4PNYzOGKedDhXbYIBe1XEQYQxOPyhcXNMJ0WCABqqj6ckydd6pWRZTHV4GuCPKdBAUiMc60tsKVw==", + "dev": true, + "engines": { + "node": ">=4" + } + }, + "node_modules/unicode-property-aliases-ecmascript": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/unicode-property-aliases-ecmascript/-/unicode-property-aliases-ecmascript-2.0.0.tgz", + "integrity": "sha512-5Zfuy9q/DFr4tfO7ZPeVXb1aPoeQSdeFMLpYuFebehDAhbuevLs5yxSZmIFN1tP5F9Wl4IpJrYojg85/zgyZHQ==", + "dev": true, + "engines": { + "node": ">=4" + } + }, + "node_modules/universalify": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/universalify/-/universalify-2.0.1.tgz", + "integrity": "sha512-gptHNQghINnc/vTGIk0SOFGFNXw7JVrlRUtConJRlvaw6DuX0wO5Jeko9sWrMBhh+PsYAZ7oXAiOnf/UKogyiw==", + "dev": true, + "engines": { + "node": ">= 10.0.0" + } + }, + "node_modules/unpipe": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/unpipe/-/unpipe-1.0.0.tgz", + "integrity": "sha512-pjy2bYhSsufwWlKwPc+l3cN7+wuJlK6uz0YdJEOlQDbl6jo/YlPi4mb8agUkVC8BF7V8NuzeyPNqRksA3hztKQ==", + "dev": true, + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/update-browserslist-db": { + "version": "1.0.16", + "resolved": "https://registry.npmjs.org/update-browserslist-db/-/update-browserslist-db-1.0.16.tgz", + "integrity": "sha512-KVbTxlBYlckhF5wgfyZXTWnMn7MMZjMu9XG8bPlliUOP9ThaF4QnhP8qrjrH7DRzHfSk0oQv1wToW+iA5GajEQ==", + "dev": true, + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/browserslist" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/browserslist" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "dependencies": { + "escalade": "^3.1.2", + "picocolors": "^1.0.1" + }, + "bin": { + "update-browserslist-db": "cli.js" + }, + "peerDependencies": { + "browserslist": ">= 4.21.0" + } + }, + "node_modules/uri-js": { + "version": "4.4.1", + "resolved": "https://registry.npmjs.org/uri-js/-/uri-js-4.4.1.tgz", + "integrity": "sha512-7rKUyy33Q1yc98pQ1DAmLtwX109F7TIfWlW1Ydo8Wl1ii1SeHieeh0HHfPeL2fMXK6z0s8ecKs9frCuLJvndBg==", + "dev": true, + "dependencies": { + "punycode": "^2.1.0" + } + }, + "node_modules/urix": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/urix/-/urix-0.1.0.tgz", + "integrity": "sha1-2pN/emLiH+wf0Y1Js1wpNQZ6bHI=", + "deprecated": "Please see https://github.com/lydell/urix#deprecated", + "dev": true + }, + "node_modules/url": { + "version": "0.11.0", + "resolved": "https://registry.npmjs.org/url/-/url-0.11.0.tgz", + "integrity": "sha1-ODjpfPxgUh63PFJajlW/3Z4uKPE=", + "dev": true, + "dependencies": { + "punycode": "1.3.2", + "querystring": "0.2.0" + } + }, + "node_modules/url/node_modules/punycode": { + "version": "1.3.2", + "resolved": "https://registry.npmjs.org/punycode/-/punycode-1.3.2.tgz", + "integrity": "sha1-llOgNvt8HuQjQvIyXM7v6jkmxI0=", + "dev": true + }, + "node_modules/util": { + "version": "0.11.1", + "resolved": "https://registry.npmjs.org/util/-/util-0.11.1.tgz", + "integrity": "sha512-HShAsny+zS2TZfaXxD9tYj4HQGlBezXZMZuM/S5PKLLoZkShZiGk9o5CzukI1LVHZvjdvZ2Sj1aW/Ndn2NB/HQ==", + "dev": true, + "dependencies": { + "inherits": "2.0.3" + } + }, + "node_modules/util-deprecate": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", + "integrity": "sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8=", + "dev": true + }, + "node_modules/util/node_modules/inherits": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.3.tgz", + "integrity": "sha1-Yzwsg+PaQqUC9SRmAiSA9CCCYd4=", + "dev": true + }, + "node_modules/utils-merge": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/utils-merge/-/utils-merge-1.0.1.tgz", + "integrity": "sha512-pMZTvIkT1d+TFGvDOqodOclx0QWkkgi6Tdoa8gC8ffGAAqz9pzPTZWAybbsHHoED/ztMtkv/VoYTYyShUn81hA==", + "dev": true, + "engines": { + "node": ">= 0.4.0" + } + }, + "node_modules/uuid": { + "version": "8.3.2", + "resolved": "https://registry.npmjs.org/uuid/-/uuid-8.3.2.tgz", + "integrity": "sha512-+NYs2QeMWy+GWFOEm9xnn6HCDp0l7QBD7ml8zLUmJ+93Q5NF0NocErnwkTkXVFNiX3/fpC6afS8Dhb/gz7R7eg==", + "dev": true, + "bin": { + "uuid": "dist/bin/uuid" + } + }, + "node_modules/vary": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/vary/-/vary-1.1.2.tgz", + "integrity": "sha512-BNGbWLfd0eUPabhkXUVm0j8uuvREyTh5ovRa/dyow/BqAbZJyC+5fU+IzQOzmAKzYqYRAISoRhdQr3eIZ/PXqg==", + "dev": true, + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/vm-browserify": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/vm-browserify/-/vm-browserify-1.1.2.tgz", + "integrity": "sha512-2ham8XPWTONajOR0ohOKOHXkm3+gaBmGut3SRuu75xLd/RRaY6vqgh8NBYYk7+RW3u5AtzPQZG8F10LHkl0lAQ==", + "dev": true + }, + "node_modules/vue-style-loader": { + "version": "4.1.3", + "resolved": "https://registry.npmjs.org/vue-style-loader/-/vue-style-loader-4.1.3.tgz", + "integrity": "sha512-sFuh0xfbtpRlKfm39ss/ikqs9AbKCoXZBpHeVZ8Tx650o0k0q/YCM7FRvigtxpACezfq6af+a7JeqVTWvncqDg==", + "dev": true, + "dependencies": { + "hash-sum": "^1.0.2", + "loader-utils": "^1.0.2" + } + }, + "node_modules/vue-template-compiler": { + "version": "2.6.14", + "resolved": "https://registry.npmjs.org/vue-template-compiler/-/vue-template-compiler-2.6.14.tgz", + "integrity": "sha512-ODQS1SyMbjKoO1JBJZojSw6FE4qnh9rIpUZn2EUT86FKizx9uH5z6uXiIrm4/Nb/gwxTi/o17ZDEGWAXHvtC7g==", + "dev": true, + "dependencies": { + "de-indent": "^1.0.2", + "he": "^1.1.0" + } + }, + "node_modules/watchpack": { + "version": "2.4.1", + "resolved": "https://registry.npmjs.org/watchpack/-/watchpack-2.4.1.tgz", + "integrity": "sha512-8wrBCMtVhqcXP2Sup1ctSkga6uc2Bx0IIvKyT7yTFier5AXHooSI+QyQQAtTb7+E0IUCCKyTFmXqdqgum2XWGg==", + "dev": true, + "dependencies": { + "glob-to-regexp": "^0.4.1", + "graceful-fs": "^4.1.2" + }, + "engines": { + "node": ">=10.13.0" + } + }, + "node_modules/wbuf": { + "version": "1.7.3", + "resolved": "https://registry.npmjs.org/wbuf/-/wbuf-1.7.3.tgz", + "integrity": "sha512-O84QOnr0icsbFGLS0O3bI5FswxzRr8/gHwWkDlQFskhSPryQXvrTMxjxGP4+iWYoauLoBvfDpkrOauZ+0iZpDA==", + "dev": true, + "dependencies": { + "minimalistic-assert": "^1.0.0" + } + }, + "node_modules/webpack": { + "version": "5.92.0", + "resolved": "https://registry.npmjs.org/webpack/-/webpack-5.92.0.tgz", + "integrity": "sha512-Bsw2X39MYIgxouNATyVpCNVWBCuUwDgWtN78g6lSdPJRLaQ/PUVm/oXcaRAyY/sMFoKFQrsPeqvTizWtq7QPCA==", + "dev": true, + "dependencies": { + "@types/eslint-scope": "^3.7.3", + "@types/estree": "^1.0.5", + "@webassemblyjs/ast": "^1.12.1", + "@webassemblyjs/wasm-edit": "^1.12.1", + "@webassemblyjs/wasm-parser": "^1.12.1", + "acorn": "^8.7.1", + "acorn-import-attributes": "^1.9.5", + "browserslist": "^4.21.10", + "chrome-trace-event": "^1.0.2", + "enhanced-resolve": "^5.17.0", + "es-module-lexer": "^1.2.1", + "eslint-scope": "5.1.1", + "events": "^3.2.0", + "glob-to-regexp": "^0.4.1", + "graceful-fs": "^4.2.11", + "json-parse-even-better-errors": "^2.3.1", + "loader-runner": "^4.2.0", + "mime-types": "^2.1.27", + "neo-async": "^2.6.2", + "schema-utils": "^3.2.0", + "tapable": "^2.1.1", + "terser-webpack-plugin": "^5.3.10", + "watchpack": "^2.4.1", + "webpack-sources": "^3.2.3" + }, + "bin": { + "webpack": "bin/webpack.js" + }, + "engines": { + "node": ">=10.13.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/webpack" + }, + "peerDependenciesMeta": { + "webpack-cli": { + "optional": true + } + } + }, + "node_modules/webpack-cli": { + "version": "4.10.0", + "resolved": "https://registry.npmjs.org/webpack-cli/-/webpack-cli-4.10.0.tgz", + "integrity": "sha512-NLhDfH/h4O6UOy+0LSso42xvYypClINuMNBVVzX4vX98TmTaTUxwRbXdhucbFMd2qLaCTcLq/PdYrvi8onw90w==", + "dev": true, + "dependencies": { + "@discoveryjs/json-ext": "^0.5.0", + "@webpack-cli/configtest": "^1.2.0", + "@webpack-cli/info": "^1.5.0", + "@webpack-cli/serve": "^1.7.0", + "colorette": "^2.0.14", + "commander": "^7.0.0", + "cross-spawn": "^7.0.3", + "fastest-levenshtein": "^1.0.12", + "import-local": "^3.0.2", + "interpret": "^2.2.0", + "rechoir": "^0.7.0", + "webpack-merge": "^5.7.3" + }, + "bin": { + "webpack-cli": "bin/cli.js" + }, + "engines": { + "node": ">=10.13.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/webpack" + }, + "peerDependencies": { + "webpack": "4.x.x || 5.x.x" + }, + "peerDependenciesMeta": { + "@webpack-cli/generators": { + "optional": true + }, + "@webpack-cli/migrate": { + "optional": true + }, + "webpack-bundle-analyzer": { + "optional": true + }, + "webpack-dev-server": { + "optional": true + } + } + }, + "node_modules/webpack-cli/node_modules/commander": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/commander/-/commander-7.2.0.tgz", + "integrity": "sha512-QrWXB+ZQSVPmIWIhtEO9H+gwHaMGYiF5ChvoJ+K9ZGHG/sVsa6yiesAD1GC/x46sET00Xlwo1u49RVVVzvcSkw==", + "dev": true, + "engines": { + "node": ">= 10" + } + }, + "node_modules/webpack-dev-middleware": { + "version": "5.3.4", + "resolved": "https://registry.npmjs.org/webpack-dev-middleware/-/webpack-dev-middleware-5.3.4.tgz", + "integrity": "sha512-BVdTqhhs+0IfoeAf7EoH5WE+exCmqGerHfDM0IL096Px60Tq2Mn9MAbnaGUe6HiMa41KMCYF19gyzZmBcq/o4Q==", + "dev": true, + "dependencies": { + "colorette": "^2.0.10", + "memfs": "^3.4.3", + "mime-types": "^2.1.31", + "range-parser": "^1.2.1", + "schema-utils": "^4.0.0" + }, + "engines": { + "node": ">= 12.13.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/webpack" + }, + "peerDependencies": { + "webpack": "^4.0.0 || ^5.0.0" + } + }, + "node_modules/webpack-dev-middleware/node_modules/ajv": { + "version": "8.16.0", + "resolved": "https://registry.npmjs.org/ajv/-/ajv-8.16.0.tgz", + "integrity": "sha512-F0twR8U1ZU67JIEtekUcLkXkoO5mMMmgGD8sK/xUFzJ805jxHQl92hImFAqqXMyMYjSPOyUPAwHYhB72g5sTXw==", + "dev": true, + "dependencies": { + "fast-deep-equal": "^3.1.3", + "json-schema-traverse": "^1.0.0", + "require-from-string": "^2.0.2", + "uri-js": "^4.4.1" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/epoberezkin" + } + }, + "node_modules/webpack-dev-middleware/node_modules/ajv-keywords": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/ajv-keywords/-/ajv-keywords-5.1.0.tgz", + "integrity": "sha512-YCS/JNFAUyr5vAuhk1DWm1CBxRHW9LbJ2ozWeemrIqpbsqKjHVxYPyi5GC0rjZIT5JxJ3virVTS8wk4i/Z+krw==", + "dev": true, + "dependencies": { + "fast-deep-equal": "^3.1.3" + }, + "peerDependencies": { + "ajv": "^8.8.2" + } + }, + "node_modules/webpack-dev-middleware/node_modules/json-schema-traverse": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz", + "integrity": "sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==", + "dev": true + }, + "node_modules/webpack-dev-middleware/node_modules/schema-utils": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/schema-utils/-/schema-utils-4.2.0.tgz", + "integrity": "sha512-L0jRsrPpjdckP3oPug3/VxNKt2trR8TcabrM6FOAAlvC/9Phcmm+cuAgTlxBqdBR1WJx7Naj9WHw+aOmheSVbw==", + "dev": true, + "dependencies": { + "@types/json-schema": "^7.0.9", + "ajv": "^8.9.0", + "ajv-formats": "^2.1.1", + "ajv-keywords": "^5.1.0" + }, + "engines": { + "node": ">= 12.13.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/webpack" + } + }, + "node_modules/webpack-dev-server": { + "version": "4.15.2", + "resolved": "https://registry.npmjs.org/webpack-dev-server/-/webpack-dev-server-4.15.2.tgz", + "integrity": "sha512-0XavAZbNJ5sDrCbkpWL8mia0o5WPOd2YGtxrEiZkBK9FjLppIUK2TgxK6qGD2P3hUXTJNNPVibrerKcx5WkR1g==", + "dev": true, + "dependencies": { + "@types/bonjour": "^3.5.9", + "@types/connect-history-api-fallback": "^1.3.5", + "@types/express": "^4.17.13", + "@types/serve-index": "^1.9.1", + "@types/serve-static": "^1.13.10", + "@types/sockjs": "^0.3.33", + "@types/ws": "^8.5.5", + "ansi-html-community": "^0.0.8", + "bonjour-service": "^1.0.11", + "chokidar": "^3.5.3", + "colorette": "^2.0.10", + "compression": "^1.7.4", + "connect-history-api-fallback": "^2.0.0", + "default-gateway": "^6.0.3", + "express": "^4.17.3", + "graceful-fs": "^4.2.6", + "html-entities": "^2.3.2", + "http-proxy-middleware": "^2.0.3", + "ipaddr.js": "^2.0.1", + "launch-editor": "^2.6.0", + "open": "^8.0.9", + "p-retry": "^4.5.0", + "rimraf": "^3.0.2", + "schema-utils": "^4.0.0", + "selfsigned": "^2.1.1", + "serve-index": "^1.9.1", + "sockjs": "^0.3.24", + "spdy": "^4.0.2", + "webpack-dev-middleware": "^5.3.4", + "ws": "^8.13.0" + }, + "bin": { + "webpack-dev-server": "bin/webpack-dev-server.js" + }, + "engines": { + "node": ">= 12.13.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/webpack" + }, + "peerDependencies": { + "webpack": "^4.37.0 || ^5.0.0" + }, + "peerDependenciesMeta": { + "webpack": { + "optional": true + }, + "webpack-cli": { + "optional": true + } + } + }, + "node_modules/webpack-dev-server/node_modules/ajv": { + "version": "8.16.0", + "resolved": "https://registry.npmjs.org/ajv/-/ajv-8.16.0.tgz", + "integrity": "sha512-F0twR8U1ZU67JIEtekUcLkXkoO5mMMmgGD8sK/xUFzJ805jxHQl92hImFAqqXMyMYjSPOyUPAwHYhB72g5sTXw==", + "dev": true, + "dependencies": { + "fast-deep-equal": "^3.1.3", + "json-schema-traverse": "^1.0.0", + "require-from-string": "^2.0.2", + "uri-js": "^4.4.1" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/epoberezkin" + } + }, + "node_modules/webpack-dev-server/node_modules/ajv-keywords": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/ajv-keywords/-/ajv-keywords-5.1.0.tgz", + "integrity": "sha512-YCS/JNFAUyr5vAuhk1DWm1CBxRHW9LbJ2ozWeemrIqpbsqKjHVxYPyi5GC0rjZIT5JxJ3virVTS8wk4i/Z+krw==", + "dev": true, + "dependencies": { + "fast-deep-equal": "^3.1.3" + }, + "peerDependencies": { + "ajv": "^8.8.2" + } + }, + "node_modules/webpack-dev-server/node_modules/json-schema-traverse": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz", + "integrity": "sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==", + "dev": true + }, + "node_modules/webpack-dev-server/node_modules/schema-utils": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/schema-utils/-/schema-utils-4.2.0.tgz", + "integrity": "sha512-L0jRsrPpjdckP3oPug3/VxNKt2trR8TcabrM6FOAAlvC/9Phcmm+cuAgTlxBqdBR1WJx7Naj9WHw+aOmheSVbw==", + "dev": true, + "dependencies": { + "@types/json-schema": "^7.0.9", + "ajv": "^8.9.0", + "ajv-formats": "^2.1.1", + "ajv-keywords": "^5.1.0" + }, + "engines": { + "node": ">= 12.13.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/webpack" + } + }, + "node_modules/webpack-merge": { + "version": "5.10.0", + "resolved": "https://registry.npmjs.org/webpack-merge/-/webpack-merge-5.10.0.tgz", + "integrity": "sha512-+4zXKdx7UnO+1jaN4l2lHVD+mFvnlZQP/6ljaJVb4SZiwIKeUnrT5l0gkT8z+n4hKpC+jpOv6O9R+gLtag7pSA==", + "dev": true, + "dependencies": { + "clone-deep": "^4.0.1", + "flat": "^5.0.2", + "wildcard": "^2.0.0" + }, + "engines": { + "node": ">=10.0.0" + } + }, + "node_modules/webpack-notifier": { + "version": "1.15.0", + "resolved": "https://registry.npmjs.org/webpack-notifier/-/webpack-notifier-1.15.0.tgz", + "integrity": "sha512-N2V8UMgRB5komdXQRavBsRpw0hPhJq2/SWNOGuhrXpIgRhcMexzkGQysUyGStHLV5hkUlgpRiF7IUXoBqyMmzQ==", + "dev": true, + "dependencies": { + "node-notifier": "^9.0.0", + "strip-ansi": "^6.0.0" + }, + "peerDependencies": { + "@types/webpack": ">4.41.31" + }, + "peerDependenciesMeta": { + "@types/webpack": { + "optional": true + } + } + }, + "node_modules/webpack-sources": { + "version": "1.4.3", + "resolved": "https://registry.npmjs.org/webpack-sources/-/webpack-sources-1.4.3.tgz", + "integrity": "sha512-lgTS3Xhv1lCOKo7SA5TjKXMjpSM4sBjNV5+q2bqesbSPs5FjGmU6jjtBSkX9b4qW87vDIsCIlUPOEhbZrMdjeQ==", + "dev": true, + "dependencies": { + "source-list-map": "^2.0.0", + "source-map": "~0.6.1" + } + }, + "node_modules/webpack/node_modules/schema-utils": { + "version": "3.3.0", + "resolved": "https://registry.npmjs.org/schema-utils/-/schema-utils-3.3.0.tgz", + "integrity": "sha512-pN/yOAvcC+5rQ5nERGuwrjLlYvLTbCibnZ1I7B1LaiAz9BRBlE9GMgE/eqV30P7aJQUf7Ddimy/RsbYO/GrVGg==", + "dev": true, + "dependencies": { + "@types/json-schema": "^7.0.8", + "ajv": "^6.12.5", + "ajv-keywords": "^3.5.2" + }, + "engines": { + "node": ">= 10.13.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/webpack" + } + }, + "node_modules/webpack/node_modules/webpack-sources": { + "version": "3.2.3", + "resolved": "https://registry.npmjs.org/webpack-sources/-/webpack-sources-3.2.3.tgz", + "integrity": "sha512-/DyMEOrDgLKKIG0fmvtz+4dUX/3Ghozwgm6iPp8KRhvn+eQf9+Q7GWxVNMk3+uCPWfdXYC4ExGBckIXdFEfH1w==", + "dev": true, + "engines": { + "node": ">=10.13.0" + } + }, + "node_modules/webpackbar": { + "version": "5.0.2", + "resolved": "https://registry.npmjs.org/webpackbar/-/webpackbar-5.0.2.tgz", + "integrity": "sha512-BmFJo7veBDgQzfWXl/wwYXr/VFus0614qZ8i9znqcl9fnEdiVkdbi0TedLQ6xAK92HZHDJ0QmyQ0fmuZPAgCYQ==", + "dev": true, + "dependencies": { + "chalk": "^4.1.0", + "consola": "^2.15.3", + "pretty-time": "^1.1.0", + "std-env": "^3.0.1" + }, + "engines": { + "node": ">=12" + }, + "peerDependencies": { + "webpack": "3 || 4 || 5" + } + }, + "node_modules/webpackbar/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dev": true, + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/webpackbar/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dev": true, + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/webpackbar/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/webpackbar/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true + }, + "node_modules/webpackbar/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/webpackbar/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dev": true, + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/websocket-driver": { + "version": "0.7.4", + "resolved": "https://registry.npmjs.org/websocket-driver/-/websocket-driver-0.7.4.tgz", + "integrity": "sha512-b17KeDIQVjvb0ssuSDF2cYXSg2iztliJ4B9WdsuB6J952qCPKmnVq4DyW5motImXHDC1cBT/1UezrJVsKw5zjg==", + "dev": true, + "dependencies": { + "http-parser-js": ">=0.5.1", + "safe-buffer": ">=5.1.0", + "websocket-extensions": ">=0.1.1" + }, + "engines": { + "node": ">=0.8.0" + } + }, + "node_modules/websocket-extensions": { + "version": "0.1.4", + "resolved": "https://registry.npmjs.org/websocket-extensions/-/websocket-extensions-0.1.4.tgz", + "integrity": "sha512-OqedPIGOfsDlo31UNwYbCFMSaO9m9G/0faIHj5/dZFDMFqPTcx6UwqyOy3COEaEOg/9VsGIpdqn62W5KhoKSpg==", + "dev": true, + "engines": { + "node": ">=0.8.0" + } + }, + "node_modules/which": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", + "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==", + "dev": true, + "dependencies": { + "isexe": "^2.0.0" + }, + "bin": { + "node-which": "bin/node-which" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/wildcard": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/wildcard/-/wildcard-2.0.1.tgz", + "integrity": "sha512-CC1bOL87PIWSBhDcTrdeLo6eGT7mCFtrg0uIJtqJUFyK+eJnzl8A1niH56uu7KMa5XFrtiV+AQuHO3n7DsHnLQ==", + "dev": true + }, + "node_modules/wrap-ansi": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-7.0.0.tgz", + "integrity": "sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==", + "dev": true, + "dependencies": { + "ansi-styles": "^4.0.0", + "string-width": "^4.1.0", + "strip-ansi": "^6.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/wrap-ansi?sponsor=1" + } + }, + "node_modules/wrap-ansi/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dev": true, + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/wrap-ansi/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/wrap-ansi/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true + }, + "node_modules/wrappy": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", + "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=", + "dev": true + }, + "node_modules/ws": { + "version": "8.17.1", + "resolved": "https://registry.npmjs.org/ws/-/ws-8.17.1.tgz", + "integrity": "sha512-6XQFvXTkbfUOZOKKILFG1PDK2NDQs4azKQl26T0YS5CxqWLgXajbPZ+h4gZekJyRqFU8pvnbAbbs/3TgRPy+GQ==", + "dev": true, + "engines": { + "node": ">=10.0.0" + }, + "peerDependencies": { + "bufferutil": "^4.0.1", + "utf-8-validate": ">=5.0.2" + }, + "peerDependenciesMeta": { + "bufferutil": { + "optional": true + }, + "utf-8-validate": { + "optional": true + } + } + }, + "node_modules/xtend": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/xtend/-/xtend-4.0.2.tgz", + "integrity": "sha512-LKYU1iAXJXUgAXn9URjiu+MWhyUXHsvfp7mcuYm9dSUKK0/CjtrUwFAxD82/mCWbtLsGjFIad0wIsod4zrTAEQ==", + "dev": true, + "engines": { + "node": ">=0.4" + } + }, + "node_modules/y18n": { + "version": "5.0.8", + "resolved": "https://registry.npmjs.org/y18n/-/y18n-5.0.8.tgz", + "integrity": "sha512-0pfFzegeDWJHJIAmTLRP2DwHjdF5s7jo9tuztdQxAhINCdvS+3nGINqPd00AphqJR/0LhANUS6/+7SCb98YOfA==", + "dev": true, + "engines": { + "node": ">=10" + } + }, + "node_modules/yaml": { + "version": "1.10.2", + "resolved": "https://registry.npmjs.org/yaml/-/yaml-1.10.2.tgz", + "integrity": "sha512-r3vXyErRCYJ7wg28yvBY5VSoAF8ZvlcW9/BwUzEtUsjvX/DKs24dIkuwjtuprwJJHsbyUbLApepYTR1BN4uHrg==", + "dev": true, + "engines": { + "node": ">= 6" + } + }, + "node_modules/yargs": { + "version": "17.7.2", + "resolved": "https://registry.npmjs.org/yargs/-/yargs-17.7.2.tgz", + "integrity": "sha512-7dSzzRQ++CKnNI/krKnYRV7JKKPUXMEh61soaHKg9mrWEhzFWhFnxPxGl+69cD1Ou63C13NUPCnmIcrvqCuM6w==", + "dev": true, + "dependencies": { + "cliui": "^8.0.1", + "escalade": "^3.1.1", + "get-caller-file": "^2.0.5", + "require-directory": "^2.1.1", + "string-width": "^4.2.3", + "y18n": "^5.0.5", + "yargs-parser": "^21.1.1" + }, + "engines": { + "node": ">=12" + } + }, + "node_modules/yargs-parser": { + "version": "21.1.1", + "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-21.1.1.tgz", + "integrity": "sha512-tVpsJW7DdjecAiFpbIB1e3qxIQsE6NoPc5/eTdrbbIC4h0LVsWhnoa3g+m2HclBIujHzsxZ4VJVA+GUuc2/LBw==", + "dev": true, + "engines": { + "node": ">=12" + } + } + } +} diff --git a/package.json b/package.json new file mode 100755 index 0000000..3bbf90d --- /dev/null +++ b/package.json @@ -0,0 +1,27 @@ +{ + "private": true, + "scripts": { + "dev": "npm run development", + "development": "cross-env NODE_ENV=development node_modules/webpack/bin/webpack.js --progress --config=node_modules/laravel-mix/setup/webpack.config.js", + "watch": "npm run development -- --watch", + "watch-poll": "npm run watch -- --watch-poll", + "hot": "cross-env NODE_ENV=development node_modules/webpack-dev-server/bin/webpack-dev-server.js --inline --hot --disable-host-check --config=node_modules/laravel-mix/setup/webpack.config.js", + "prod": "npm run production", + "production": "cross-env NODE_ENV=production node_modules/webpack/bin/webpack.js --no-progress --config=node_modules/laravel-mix/setup/webpack.config.js" + }, + "devDependencies": { + "@prettier/plugin-php": "^0.19.4", + "axios": "^1.7.2", + "bootstrap": "^4.0.0", + "cross-env": "^7.0", + "jquery": "^3.2", + "laravel-mix": "^6.0.49", + "lodash": "^4.17.19", + "popper.js": "^1.12", + "prettier": "^2.8.7", + "resolve-url-loader": "^3.1.0", + "sass": "^1.15.2", + "sass-loader": "^8.0.0", + "vue-template-compiler": "^2.6.14" + } +} diff --git a/phpunit.xml b/phpunit.xml new file mode 100755 index 0000000..76f2246 --- /dev/null +++ b/phpunit.xml @@ -0,0 +1,31 @@ + + + + + ./tests/Unit + + + ./tests/Feature + + + + + ./app + + + + + + + + + + + + + + diff --git a/public/.htaccess b/public/.htaccess new file mode 100755 index 0000000..3aec5e2 --- /dev/null +++ b/public/.htaccess @@ -0,0 +1,21 @@ + + + Options -MultiViews -Indexes + + + RewriteEngine On + + # Handle Authorization Header + RewriteCond %{HTTP:Authorization} . + RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}] + + # Redirect Trailing Slashes If Not A Folder... + RewriteCond %{REQUEST_FILENAME} !-d + RewriteCond %{REQUEST_URI} (.+)/$ + RewriteRule ^ %1 [L,R=301] + + # Send Requests To Front Controller... + RewriteCond %{REQUEST_FILENAME} !-d + RewriteCond %{REQUEST_FILENAME} !-f + RewriteRule ^ index.php [L] + diff --git a/public/Auth/css/style.css b/public/Auth/css/style.css new file mode 100755 index 0000000..bf62533 --- /dev/null +++ b/public/Auth/css/style.css @@ -0,0 +1,607 @@ +/* @extend display-flex; */ +display-flex, .display-flex, .display-flex-center, .signup-content, .signin-content, .social-login, .socials { +display: flex; +display: -webkit-flex; } + +/* @extend list-type-ulli; */ +list-type-ulli, .socials { +list-style-type: none; +margin: 0; +padding: 0; } + +/* poppins-300 - latin */ +@font-face { +font-family: 'Poppins'; +font-style: normal; +font-weight: 300; +src: url("../fonts/poppins/poppins-v5-latin-300.eot"); +/* IE9 Compat Modes */ +src: local("Poppins Light"), local("Poppins-Light"), url("../fonts/poppins/poppins-v5-latin-300.eot?#iefix") format("embedded-opentype"), url("../fonts/poppins/poppins-v5-latin-300.woff2") format("woff2"), url("../fonts/poppins/poppins-v5-latin-300.woff") format("woff"), url("../fonts/poppins/poppins-v5-latin-300.ttf") format("truetype"), url("../fonts/poppins/poppins-v5-latin-300.svg#Poppins") format("svg"); +/* Legacy iOS */ } +/* poppins-300italic - latin */ +@font-face { +font-family: 'Poppins'; +font-style: italic; +font-weight: 300; +src: url("../fonts/poppins/poppins-v5-latin-300italic.eot"); +/* IE9 Compat Modes */ +src: local("Poppins Light Italic"), local("Poppins-LightItalic"), url("../fonts/poppins/poppins-v5-latin-300italic.eot?#iefix") format("embedded-opentype"), url("../fonts/poppins/poppins-v5-latin-300italic.woff2") format("woff2"), url("../fonts/poppins/poppins-v5-latin-300italic.woff") format("woff"), url("../fonts/poppins/poppins-v5-latin-300italic.ttf") format("truetype"), url("../fonts/poppins/poppins-v5-latin-300italic.svg#Poppins") format("svg"); +/* Legacy iOS */ } +/* poppins-regular - latin */ +@font-face { +font-family: 'Poppins'; +font-style: normal; +font-weight: 400; +src: url("../fonts/poppins/poppins-v5-latin-regular.eot"); +/* IE9 Compat Modes */ +src: local("Poppins Regular"), local("Poppins-Regular"), url("../fonts/poppins/poppins-v5-latin-regular.eot?#iefix") format("embedded-opentype"), url("../fonts/poppins/poppins-v5-latin-regular.woff2") format("woff2"), url("../fonts/poppins/poppins-v5-latin-regular.woff") format("woff"), url("../fonts/poppins/poppins-v5-latin-regular.ttf") format("truetype"), url("../fonts/poppins/poppins-v5-latin-regular.svg#Poppins") format("svg"); +/* Legacy iOS */ } +/* poppins-italic - latin */ +@font-face { +font-family: 'Poppins'; +font-style: italic; +font-weight: 400; +src: url("../fonts/poppins/poppins-v5-latin-italic.eot"); +/* IE9 Compat Modes */ +src: local("Poppins Italic"), local("Poppins-Italic"), url("../fonts/poppins/poppins-v5-latin-italic.eot?#iefix") format("embedded-opentype"), url("../fonts/poppins/poppins-v5-latin-italic.woff2") format("woff2"), url("../fonts/poppins/poppins-v5-latin-italic.woff") format("woff"), url("../fonts/poppins/poppins-v5-latin-italic.ttf") format("truetype"), url("../fonts/poppins/poppins-v5-latin-italic.svg#Poppins") format("svg"); +/* Legacy iOS */ } +/* poppins-500 - latin */ +@font-face { +font-family: 'Poppins'; +font-style: normal; +font-weight: 500; +src: url("../fonts/poppins/poppins-v5-latin-500.eot"); +/* IE9 Compat Modes */ +src: local("Poppins Medium"), local("Poppins-Medium"), url("../fonts/poppins/poppins-v5-latin-500.eot?#iefix") format("embedded-opentype"), url("../fonts/poppins/poppins-v5-latin-500.woff2") format("woff2"), url("../fonts/poppins/poppins-v5-latin-500.woff") format("woff"), url("../fonts/poppins/poppins-v5-latin-500.ttf") format("truetype"), url("../fonts/poppins/poppins-v5-latin-500.svg#Poppins") format("svg"); +/* Legacy iOS */ } +/* poppins-500italic - latin */ +@font-face { +font-family: 'Poppins'; +font-style: italic; +font-weight: 500; +src: url("../fonts/poppins/poppins-v5-latin-500italic.eot"); +/* IE9 Compat Modes */ +src: local("Poppins Medium Italic"), local("Poppins-MediumItalic"), url("../fonts/poppins/poppins-v5-latin-500italic.eot?#iefix") format("embedded-opentype"), url("../fonts/poppins/poppins-v5-latin-500italic.woff2") format("woff2"), url("../fonts/poppins/poppins-v5-latin-500italic.woff") format("woff"), url("../fonts/poppins/poppins-v5-latin-500italic.ttf") format("truetype"), url("../fonts/poppins/poppins-v5-latin-500italic.svg#Poppins") format("svg"); +/* Legacy iOS */ } +/* poppins-600 - latin */ +@font-face { +font-family: 'Poppins'; +font-style: normal; +font-weight: 600; +src: url("../fonts/poppins/poppins-v5-latin-600.eot"); +/* IE9 Compat Modes */ +src: local("Poppins SemiBold"), local("Poppins-SemiBold"), url("../fonts/poppins/poppins-v5-latin-600.eot?#iefix") format("embedded-opentype"), url("../fonts/poppins/poppins-v5-latin-600.woff2") format("woff2"), url("../fonts/poppins/poppins-v5-latin-600.woff") format("woff"), url("../fonts/poppins/poppins-v5-latin-600.ttf") format("truetype"), url("../fonts/poppins/poppins-v5-latin-600.svg#Poppins") format("svg"); +/* Legacy iOS */ } +/* poppins-700 - latin */ +@font-face { +font-family: 'Poppins'; +font-style: normal; +font-weight: 700; +src: url("../fonts/poppins/poppins-v5-latin-700.eot"); +/* IE9 Compat Modes */ +src: local("Poppins Bold"), local("Poppins-Bold"), url("../fonts/poppins/poppins-v5-latin-700.eot?#iefix") format("embedded-opentype"), url("../fonts/poppins/poppins-v5-latin-700.woff2") format("woff2"), url("../fonts/poppins/poppins-v5-latin-700.woff") format("woff"), url("../fonts/poppins/poppins-v5-latin-700.ttf") format("truetype"), url("../fonts/poppins/poppins-v5-latin-700.svg#Poppins") format("svg"); +/* Legacy iOS */ } +/* poppins-700italic - latin */ +@font-face { +font-family: 'Poppins'; +font-style: italic; +font-weight: 700; +src: url("../fonts/poppins/poppins-v5-latin-700italic.eot"); +/* IE9 Compat Modes */ +src: local("Poppins Bold Italic"), local("Poppins-BoldItalic"), url("../fonts/poppins/poppins-v5-latin-700italic.eot?#iefix") format("embedded-opentype"), url("../fonts/poppins/poppins-v5-latin-700italic.woff2") format("woff2"), url("../fonts/poppins/poppins-v5-latin-700italic.woff") format("woff"), url("../fonts/poppins/poppins-v5-latin-700italic.ttf") format("truetype"), url("../fonts/poppins/poppins-v5-latin-700italic.svg#Poppins") format("svg"); +/* Legacy iOS */ } +/* poppins-800 - latin */ +@font-face { +font-family: 'Poppins'; +font-style: normal; +font-weight: 800; +src: url("../fonts/poppins/poppins-v5-latin-800.eot"); +/* IE9 Compat Modes */ +src: local("Poppins ExtraBold"), local("Poppins-ExtraBold"), url("../fonts/poppins/poppins-v5-latin-800.eot?#iefix") format("embedded-opentype"), url("../fonts/poppins/poppins-v5-latin-800.woff2") format("woff2"), url("../fonts/poppins/poppins-v5-latin-800.woff") format("woff"), url("../fonts/poppins/poppins-v5-latin-800.ttf") format("truetype"), url("../fonts/poppins/poppins-v5-latin-800.svg#Poppins") format("svg"); +/* Legacy iOS */ } +/* poppins-800italic - latin */ +@font-face { +font-family: 'Poppins'; +font-style: italic; +font-weight: 800; +src: url("../fonts/poppins/poppins-v5-latin-800italic.eot"); +/* IE9 Compat Modes */ +src: local("Poppins ExtraBold Italic"), local("Poppins-ExtraBoldItalic"), url("../fonts/poppins/poppins-v5-latin-800italic.eot?#iefix") format("embedded-opentype"), url("../fonts/poppins/poppins-v5-latin-800italic.woff2") format("woff2"), url("../fonts/poppins/poppins-v5-latin-800italic.woff") format("woff"), url("../fonts/poppins/poppins-v5-latin-800italic.ttf") format("truetype"), url("../fonts/poppins/poppins-v5-latin-800italic.svg#Poppins") format("svg"); +/* Legacy iOS */ } +/* poppins-900 - latin */ +@font-face { +font-family: 'Poppins'; +font-style: normal; +font-weight: 900; +src: url("../fonts/poppins/poppins-v5-latin-900.eot"); +/* IE9 Compat Modes */ +src: local("Poppins Black"), local("Poppins-Black"), url("../fonts/poppins/poppins-v5-latin-900.eot?#iefix") format("embedded-opentype"), url("../fonts/poppins/poppins-v5-latin-900.woff2") format("woff2"), url("../fonts/poppins/poppins-v5-latin-900.woff") format("woff"), url("../fonts/poppins/poppins-v5-latin-900.ttf") format("truetype"), url("../fonts/poppins/poppins-v5-latin-900.svg#Poppins") format("svg"); +/* Legacy iOS */ } +a:focus, a:active { +text-decoration: none; +outline: none; +transition: all 300ms ease 0s; +-moz-transition: all 300ms ease 0s; +-webkit-transition: all 300ms ease 0s; +-o-transition: all 300ms ease 0s; +-ms-transition: all 300ms ease 0s; } + +input, select, textarea { +outline: none; +appearance: unset !important; +-moz-appearance: unset !important; +-webkit-appearance: unset !important; +-o-appearance: unset !important; +-ms-appearance: unset !important; } + +input::-webkit-outer-spin-button, input::-webkit-inner-spin-button { +appearance: none !important; +-moz-appearance: none !important; +-webkit-appearance: none !important; +-o-appearance: none !important; +-ms-appearance: none !important; +margin: 0; } + +input:focus, select:focus, textarea:focus { +outline: none; +box-shadow: none !important; +-moz-box-shadow: none !important; +-webkit-box-shadow: none !important; +-o-box-shadow: none !important; +-ms-box-shadow: none !important; } + +input[type=checkbox] { +appearance: checkbox !important; +-moz-appearance: checkbox !important; +-webkit-appearance: checkbox !important; +-o-appearance: checkbox !important; +-ms-appearance: checkbox !important; } + +input[type=radio] { +appearance: radio !important; +-moz-appearance: radio !important; +-webkit-appearance: radio !important; +-o-appearance: radio !important; +-ms-appearance: radio !important; } + +img { +max-width: 100%; +height: auto; } + +figure { +margin: 0; } + +p { +margin-bottom: 0px; +font-size: 15px; +color: #777; } + +h2 { +line-height: 1.66; +margin: 0; +padding: 0; +font-weight: bold; +color: #222; +font-family: Poppins; +font-size: 36px; } + +.main { +background: #f8f8f8; +padding: 150px 0; } + +.clear { +clear: both; } + +body { +font-size: 13px; +line-height: 1.8; +color: #222; +background: #f8f8f8; +font-weight: 400; +font-family: Poppins; } + +.container { +width: 900px; +background: #fff; +margin: 0 auto; +box-shadow: 0px 15px 16.83px 0.17px rgba(0, 0, 0, 0.05); +-moz-box-shadow: 0px 15px 16.83px 0.17px rgba(0, 0, 0, 0.05); +-webkit-box-shadow: 0px 15px 16.83px 0.17px rgba(0, 0, 0, 0.05); +-o-box-shadow: 0px 15px 16.83px 0.17px rgba(0, 0, 0, 0.05); +-ms-box-shadow: 0px 15px 16.83px 0.17px rgba(0, 0, 0, 0.05); +border-radius: 20px; +-moz-border-radius: 20px; +-webkit-border-radius: 20px; +-o-border-radius: 20px; +-ms-border-radius: 20px; } + +.display-flex { +justify-content: space-between; +-moz-justify-content: space-between; +-webkit-justify-content: space-between; +-o-justify-content: space-between; +-ms-justify-content: space-between; +align-items: center; +-moz-align-items: center; +-webkit-align-items: center; +-o-align-items: center; +-ms-align-items: center; } + +.display-flex-center { +justify-content: center; +-moz-justify-content: center; +-webkit-justify-content: center; +-o-justify-content: center; +-ms-justify-content: center; +align-items: center; +-moz-align-items: center; +-webkit-align-items: center; +-o-align-items: center; +-ms-align-items: center; } + +.position-center { +position: absolute; +top: 50%; +left: 50%; +transform: translate(-50%, -50%); +-moz-transform: translate(-50%, -50%); +-webkit-transform: translate(-50%, -50%); +-o-transform: translate(-50%, -50%); +-ms-transform: translate(-50%, -50%); } + +.signup { +margin-bottom: 150px; } + +.signup-content { +padding: 75px 0; } + +.signup-form, .signup-image, .signin-form, .signin-image { +width: 50%; +overflow: hidden; } + +.signup-image { +margin: 0 55px; } + +.form-title { + font-size: 2rem; + margin-bottom: 33px; + line-height: 1.4; +} + +.signup-image { +margin-top: 45px; } + +figure { +margin-bottom: 50px; +text-align: center; } + +.form-submit { +display: inline-block; +background: #f26e6f; +color: #fff; +border-bottom: none; +width: auto; +/* padding: 15px 39px; */ +border-radius: 5px; +-moz-border-radius: 5px; +-webkit-border-radius: 5px; +-o-border-radius: 5px; +-ms-border-radius: 5px; +/* margin-top: 25px; */ +cursor: pointer; } +.form-submit:hover { + background: #d22118; } + +#signin { +margin-top: 16px; } + +.signup-image-link { +font-size: 14px; +color: #222; +display: block; +text-align: center; } + +.term-service { +font-size: 13px; +color: #222; } + +.signup-form { +margin-left: 75px; +margin-right: 75px; +padding-left: 34px; } + +.register-form { +width: 100%; } + +.form-group { +position: relative; +margin-bottom: 25px; +overflow: hidden; } +.form-group:last-child { + margin-bottom: 0px; } + +input { +width: 100%; +display: block; +border: none; +border-bottom: 1px solid #999; +padding: 6px 30px; +font-family: Poppins; +box-sizing: border-box; } +input::-webkit-input-placeholder { + color: #999; } +input::-moz-placeholder { + color: #999; } +input:-ms-input-placeholder { + color: #999; } +input:-moz-placeholder { + color: #999; } +input:focus { + border-bottom: 1px solid #222; } + input:focus::-webkit-input-placeholder { + color: #222; } + input:focus::-moz-placeholder { + color: #222; } + input:focus:-ms-input-placeholder { + color: #222; } + input:focus:-moz-placeholder { + color: #222; } + +input[type=checkbox]:not(old) { +width: 2em; +margin: 0; +padding: 0; +font-size: 1em; +display: none; } + +input[type=checkbox]:not(old) + label { +display: inline-block; +line-height: 1.5em; +margin-top: 6px; } + +input[type=checkbox]:not(old) + label > span { +display: inline-block; +width: 13px; +height: 13px; +margin-right: 15px; +margin-bottom: 3px; +border: 1px solid #999; +border-radius: 2px; +-moz-border-radius: 2px; +-webkit-border-radius: 2px; +-o-border-radius: 2px; +-ms-border-radius: 2px; +background: white; +background-image: -moz-linear-gradient(white, white); +background-image: -ms-linear-gradient(white, white); +background-image: -o-linear-gradient(white, white); +background-image: -webkit-linear-gradient(white, white); +background-image: linear-gradient(white, white); +vertical-align: bottom; } + +input[type=checkbox]:not(old):checked + label > span { +background-image: -moz-linear-gradient(white, white); +background-image: -ms-linear-gradient(white, white); +background-image: -o-linear-gradient(white, white); +background-image: -webkit-linear-gradient(white, white); +background-image: linear-gradient(white, white); } + +input[type=checkbox]:not(old):checked + label > span:before { +content: '\f26b'; +display: block; +color: #222; +font-size: 11px; +line-height: 1.2; +text-align: center; +font-family: 'Material-Design-Iconic-Font'; +font-weight: bold; } + +.agree-term { +display: inline-block; +width: auto; } + +label { +position: absolute; +left: 0; +top: 50%; +transform: translateY(-50%); +-moz-transform: translateY(-50%); +-webkit-transform: translateY(-50%); +-o-transform: translateY(-50%); +-ms-transform: translateY(-50%); +color: #222; } + +.label-has-error { +top: 22%; } + +label.error { +position: relative; +background: url("../images/unchecked.gif") no-repeat; +background-position-y: 3px; +padding-left: 20px; +display: block; +margin-top: 20px; } + +label.valid { +display: block; +position: absolute; +right: 0; +left: auto; +margin-top: -6px; +width: 20px; +height: 20px; +background: transparent; } +label.valid:after { + font-family: 'Material-Design-Iconic-Font'; + content: '\f269'; + width: 100%; + height: 100%; + position: absolute; + /* right: 0; */ + font-size: 16px; + color: green; } + +.label-agree-term { +position: relative; +top: 0%; +transform: translateY(0); +-moz-transform: translateY(0); +-webkit-transform: translateY(0); +-o-transform: translateY(0); +-ms-transform: translateY(0); } + +.material-icons-name { +font-size: 18px; } + +.signin-content { +padding-top: 67px; +padding-bottom: 87px; + display: flex; + align-items: center; } + +.social-login { +align-items: center; +-moz-align-items: center; +-webkit-align-items: center; +-o-align-items: center; +-ms-align-items: center; +margin-top: 80px; } + +.social-label { +display: inline-block; +margin-right: 15px; } + +.socials li { +padding: 5px; } +.socials li:last-child { + margin-right: 0px; } +.socials li a { + text-decoration: none; } + .socials li a i { + width: 30px; + height: 30px; + color: #fff; + font-size: 14px; + border-radius: 5px; + -moz-border-radius: 5px; + -webkit-border-radius: 5px; + -o-border-radius: 5px; + -ms-border-radius: 5px; + transform: translateZ(0); + -moz-transform: translateZ(0); + -webkit-transform: translateZ(0); + -o-transform: translateZ(0); + -ms-transform: translateZ(0); + -webkit-transition-duration: 0.3s; + transition-duration: 0.3s; + -webkit-transition-property: transform; + transition-property: transform; + -webkit-transition-timing-function: ease-out; + transition-timing-function: ease-out; } +.socials li:hover a i { + -webkit-transform: scale(1.3) translateZ(0); + transform: scale(1.3) translateZ(0); } + +.zmdi-facebook { +background: #3b5998; } + +.zmdi-twitter { +background: #1da0f2; } + +.zmdi-google { +background: #e72734; } + +.signin-form { +margin-right: 60px; +margin-left: 30px; } + +.signin-image { +/* margin-left: 110px; */ +margin-left: 60px; +margin-right: 30px; +margin-top: 10px; } + +@media screen and (max-width: 1200px) { +.container { + width: calc( 100% - 30px); + max-width: 100%; } } +@media screen and (min-width: 1024px) { +.container { + max-width: 1200px; } } +@media screen and (max-width: 768px) { +.signup-content, .signin-content { + flex-direction: column; + -moz-flex-direction: column; + -webkit-flex-direction: column; + -o-flex-direction: column; + -ms-flex-direction: column; + justify-content: center; + -moz-justify-content: center; + -webkit-justify-content: center; + -o-justify-content: center; + -ms-justify-content: center; } + +.signup-form { + margin-left: 0px; + margin-right: 0px; + padding-left: 0px; + /* box-sizing: border-box; */ + padding: 0 30px; } + +.signin-image { + margin-left: 0px; + margin-right: 0px; + margin-top: 50px; + order: 2; + -moz-order: 2; + -webkit-order: 2; + -o-order: 2; + -ms-order: 2; + display: none; +} + +.signup-form, .signup-image, .signin-form, .signin-image { + width: auto; } + +.social-login { + justify-content: center; + -moz-justify-content: center; + -webkit-justify-content: center; + -o-justify-content: center; + -ms-justify-content: center; } + +.form-button { + text-align: center; } + +.signin-form { + order: 1; + -moz-order: 1; + -webkit-order: 1; + -o-order: 1; + -ms-order: 1; + margin-right: 0px; + margin-left: 0px; + padding: 0 30px; } + +.form-title { + text-align: center; } +.logo-wrapper { + text-align: center;} +} +@media screen and (max-width: 400px) { +.social-login { + flex-direction: column; + -moz-flex-direction: column; + -webkit-flex-direction: column; + -o-flex-direction: column; + -ms-flex-direction: column; } + +.social-label { + margin-right: 0px; + margin-bottom: 10px; } } + +/*# sourceMappingURL=style.css.map */ +.text-dark { + color: #222; + font-weight: 600; +} diff --git a/public/Auth/css/style.css.map b/public/Auth/css/style.css.map new file mode 100755 index 0000000..35f8133 --- /dev/null +++ b/public/Auth/css/style.css.map @@ -0,0 +1,7 @@ +{ +"version": 3, +"mappings": "AAAA,2BAA2B;AAC3B,4GAAa;EACT,OAAO,EAAE,IAAI;EACb,OAAO,EAAE,YAAY;;AAEzB,6BAA6B;AAC7B,wBAAe;EACX,eAAe,EAAE,IAAI;EACrB,MAAM,EAAE,CAAC;EACT,OAAO,EAAE,CAAC;;ACTd,yBAAyB;AACzB,UAWG;EAVC,WAAW,EAAE,SAAS;EACtB,UAAU,EAAE,MAAM;EAClB,WAAW,EAAE,GAAG;EAChB,GAAG,EAAE,gDAAgD;EAAE,sBAAsB;EAC7E,GAAG,EAAE,sZAKsE;EAAE,gBAAgB;AAE/F,+BAA+B;AAC/B,UAWC;EAVC,WAAW,EAAE,SAAS;EACtB,UAAU,EAAE,MAAM;EAClB,WAAW,EAAE,GAAG;EAChB,GAAG,EAAE,sDAAsD;EAAE,sBAAsB;EACnF,GAAG,EAAE,icAK4E;EAAE,gBAAgB;AAErG,6BAA6B;AAC7B,UAWG;EAVC,WAAW,EAAE,SAAS;EACtB,UAAU,EAAE,MAAM;EAClB,WAAW,EAAE,GAAG;EAChB,GAAG,EAAE,oDAAoD;EAAE,sBAAsB;EACjF,GAAG,EAAE,8aAK0E;EAAE,gBAAgB;AAEnG,4BAA4B;AAC5B,UAWC;EAVC,WAAW,EAAE,SAAS;EACtB,UAAU,EAAE,MAAM;EAClB,WAAW,EAAE,GAAG;EAChB,GAAG,EAAE,mDAAmD;EAAE,sBAAsB;EAChF,GAAG,EAAE,uaAKyE;EAAE,gBAAgB;AAElG,yBAAyB;AACzB,UAWC;EAVC,WAAW,EAAE,SAAS;EACtB,UAAU,EAAE,MAAM;EAClB,WAAW,EAAE,GAAG;EAChB,GAAG,EAAE,gDAAgD;EAAE,sBAAsB;EAC7E,GAAG,EAAE,wZAKsE;EAAE,gBAAgB;AAE/F,+BAA+B;AAC/B,UAWC;EAVC,WAAW,EAAE,SAAS;EACtB,UAAU,EAAE,MAAM;EAClB,WAAW,EAAE,GAAG;EAChB,GAAG,EAAE,sDAAsD;EAAE,sBAAsB;EACnF,GAAG,EAAE,mcAK4E;EAAE,gBAAgB;AAErG,yBAAyB;AACzB,UAWC;EAVC,WAAW,EAAE,SAAS;EACtB,UAAU,EAAE,MAAM;EAClB,WAAW,EAAE,GAAG;EAChB,GAAG,EAAE,gDAAgD;EAAE,sBAAsB;EAC7E,GAAG,EAAE,4ZAKsE;EAAE,gBAAgB;AAE/F,yBAAyB;AACzB,UAWC;EAVC,WAAW,EAAE,SAAS;EACtB,UAAU,EAAE,MAAM;EAClB,WAAW,EAAE,GAAG;EAChB,GAAG,EAAE,gDAAgD;EAAE,sBAAsB;EAC7E,GAAG,EAAE,oZAKsE;EAAE,gBAAgB;AAE/F,+BAA+B;AAC/B,UAWC;EAVC,WAAW,EAAE,SAAS;EACtB,UAAU,EAAE,MAAM;EAClB,WAAW,EAAE,GAAG;EAChB,GAAG,EAAE,sDAAsD;EAAE,sBAAsB;EACnF,GAAG,EAAE,+bAK4E;EAAE,gBAAgB;AAErG,yBAAyB;AACzB,UAWC;EAVC,WAAW,EAAE,SAAS;EACtB,UAAU,EAAE,MAAM;EAClB,WAAW,EAAE,GAAG;EAChB,GAAG,EAAE,gDAAgD;EAAE,sBAAsB;EAC7E,GAAG,EAAE,8ZAKsE;EAAE,gBAAgB;AAE/F,+BAA+B;AAC/B,UAWC;EAVC,WAAW,EAAE,SAAS;EACtB,UAAU,EAAE,MAAM;EAClB,WAAW,EAAE,GAAG;EAChB,GAAG,EAAE,sDAAsD;EAAE,sBAAsB;EACnF,GAAG,EAAE,ycAK4E;EAAE,gBAAgB;AAErG,yBAAyB;AACzB,UAWC;EAVC,WAAW,EAAE,SAAS;EACtB,UAAU,EAAE,MAAM;EAClB,WAAW,EAAE,GAAG;EAChB,GAAG,EAAE,gDAAgD;EAAE,sBAAsB;EAC7E,GAAG,EAAE,sZAKsE;EAAE,gBAAgB;AC1JlG,iBAAkB;EAAE,eAAe,EAAE,IAAI;EAAE,OAAO,EAAE,IAAI;ECmDxD,UAAU,EDnDoE,iBAAiB;ECoD/F,eAAe,EDpD+D,iBAAiB;ECqD/F,kBAAkB,EDrD4D,iBAAiB;ECsD/F,aAAa,EDtDiE,iBAAiB;ECuD/F,cAAc,EDvDgE,iBAAiB;;AAChG,uBAAwB;EAAE,OAAO,EAAE,IAAI;ECuEtC,UAAU,EAAE,gBAAiB;EAC7B,eAAe,EAAE,gBAAiB;EAClC,kBAAkB,EAAE,gBAAiB;EACrC,aAAa,EAAE,gBAAiB;EAChC,cAAc,EAAE,gBAAiB;;AD1ElC,kEAAmE;ECsElE,UAAU,EAAE,eAAiB;EAC7B,eAAe,EAAE,eAAiB;EAClC,kBAAkB,EAAE,eAAiB;EACrC,aAAa,EAAE,eAAiB;EAChC,cAAc,EAAE,eAAiB;EDxE9B,MAAM,EAAE,CAAC;;AAEb,yCAA0C;EAAE,OAAO,EAAE,IAAI;ECyExD,UAAU,EAAE,eAAiB;EAC7B,eAAe,EAAE,eAAiB;EAClC,kBAAkB,EAAE,eAAiB;EACrC,aAAa,EAAE,eAAiB;EAChC,cAAc,EAAE,eAAiB;;AD5ElC,oBAAqB;ECiEpB,UAAU,EAAE,mBAAiB;EAC7B,eAAe,EAAE,mBAAiB;EAClC,kBAAkB,EAAE,mBAAiB;EACrC,aAAa,EAAE,mBAAiB;EAChC,cAAc,EAAE,mBAAiB;;ADpElC,iBAAkB;ECgEjB,UAAU,EAAE,gBAAiB;EAC7B,eAAe,EAAE,gBAAiB;EAClC,kBAAkB,EAAE,gBAAiB;EACrC,aAAa,EAAE,gBAAiB;EAChC,cAAc,EAAE,gBAAiB;;ADnElC,GAAI;EAAE,SAAS,EAAE,IAAI;EAAE,MAAM,EAAE,IAAI;;AACnC,MAAO;EAAE,MAAM,EAAE,CAAC;;AAClB,CAAE;EAAE,aAAa,EAAE,GAAG;EAAE,SAAS,EAAE,IAAI;EAAE,KAAK,EAAE,IAAI;;AACpD,EAAG;EACC,WAAW,EAAE,IAAI;EACjB,MAAM,EAAE,CAAC;EACT,OAAO,EAAE,CAAC;EACV,WAAW,EAAE,IAAI;EACjB,KAAK,EEjBM,IAAI;EFkBf,WAAW,EAAE,OAAO;EACpB,SAAS,EAAE,IAAI;;AAEnB,KAAM;EACF,UAAU,EAAE,OAAO;EACnB,OAAO,EAAE,OAAO;;AAEpB,MAAO;EAAE,KAAK,EAAE,IAAI;;AACpB,IAAK;EACJ,SAAS,EAAE,IAAI;EACZ,WAAW,EAAE,GAAG;EAChB,KAAK,EE7BM,IAAI;EF8Bf,UAAU,EAAE,OAAO;EACnB,WAAW,EAAE,GAAG;EAChB,WAAW,EAAE,OAAO;;AAExB,UAAW;EACP,KAAK,EAAE,KAAK;EACZ,UAAU,EAAE,IAAI;EAChB,MAAM,EAAE,MAAM;ECAjB,UAAU,EDCa,2CAA2C;ECAlE,eAAe,EDAQ,2CAA2C;ECClE,kBAAkB,EDDK,2CAA2C;ECElE,aAAa,EDFU,2CAA2C;ECGlE,cAAc,EDHS,2CAA2C;ECpC/D,aAAa,EDqCU,IAAI;ECpC3B,kBAAkB,EDoCK,IAAI;ECnC3B,qBAAqB,EDmCE,IAAI;EClC3B,gBAAgB,EDkCO,IAAI;ECjC3B,iBAAiB,EDiCM,IAAI;;AAG/B,aAAe;ECmEd,eAAe,EDjEa,aAAa;ECkEzC,oBAAoB,EDlEQ,aAAa;ECmEzC,uBAAuB,EDnEK,aAAa;ECoEzC,kBAAkB,EDpEU,aAAa;ECqEzC,mBAAmB,EDrES,aAAa;ECwEzC,WAAW,EDvEa,MAAM;ECwE9B,gBAAgB,EDxEQ,MAAM;ECyE9B,mBAAmB,EDzEK,MAAM;EC0E9B,cAAc,ED1EU,MAAM;EC2E9B,eAAe,ED3ES,MAAM;;AAG/B,oBAAsB;EC6DrB,eAAe,ED3Da,MAAM;EC4DlC,oBAAoB,ED5DQ,MAAM;EC6DlC,uBAAuB,ED7DK,MAAM;EC8DlC,kBAAkB,ED9DU,MAAM;EC+DlC,mBAAmB,ED/DS,MAAM;ECkElC,WAAW,EDjEa,MAAM;ECkE9B,gBAAgB,EDlEQ,MAAM;ECmE9B,mBAAmB,EDnEK,MAAM;ECoE9B,cAAc,EDpEU,MAAM;ECqE9B,eAAe,EDrES,MAAM;;AAG/B,gBAAiB;EACb,QAAQ,EAAE,QAAQ;EAClB,GAAG,EAAE,GAAG;EACR,IAAI,EAAE,GAAG;EC3BZ,SAAS,EAAE,qBAAM;EACjB,cAAc,EAAE,qBAAM;EACtB,iBAAiB,EAAE,qBAAM;EACzB,YAAY,EAAE,qBAAM;EACpB,aAAa,EAAE,qBAAM;;AElCtB,OAAQ;EACJ,aAAa,EAAE,KAAK;;AAExB,eAAgB;EAEZ,OAAO,EAAE,MAAM;;AAGnB,wDAAwD;EACpD,KAAK,EAAE,GAAG;EACV,QAAQ,EAAE,MAAM;;AAEpB,aAAc;EACV,MAAM,EAAE,MAAM;;AAElB,WAAY;EACR,aAAa,EAAE,IAAI;;AAEvB,aAAc;EACV,UAAU,EAAE,IAAI;;AAEpB,MAAO;EACH,aAAa,EAAE,IAAI;EACnB,UAAU,EAAE,MAAM;;AAEtB,YAAa;EACT,OAAO,EAAE,YAAY;EACrB,UAAU,ED1BA,OAAO;EC2BjB,KAAK,EAAE,IAAI;EACX,aAAa,EAAE,IAAI;EACnB,KAAK,EAAE,IAAI;EACX,OAAO,EAAE,SAAS;EF7BlB,aAAa,EE8BU,GAAG;EF7B1B,kBAAkB,EE6BK,GAAG;EF5B1B,qBAAqB,EE4BE,GAAG;EF3B1B,gBAAgB,EE2BO,GAAG;EF1B1B,iBAAiB,EE0BM,GAAG;EAC1B,UAAU,EAAE,IAAI;EAChB,MAAM,EAAE,OAAO;EACf,kBAAQ;IACJ,UAAU,EAAE,OAAwB;;AAI5C,OAAQ;EACJ,UAAU,EAAE,IAAI;;AAEpB,kBAAmB;EACf,SAAS,EAAE,IAAI;EACf,KAAK,ED7CM,IAAI;EC8Cf,OAAO,EAAE,KAAK;EACd,UAAU,EAAE,MAAM;;AAGtB,aAAc;EACV,SAAS,EAAE,IAAI;EACf,KAAK,EDpDM,IAAI;;ACsDnB,YAAa;EACT,WAAW,EAAE,IAAI;EACjB,YAAY,EAAE,IAAI;EAClB,YAAY,EAAE,IAAI;;AAEtB,cAAe;EACX,KAAK,EAAE,IAAI;;AAEf,WAAY;EACR,QAAQ,EAAE,QAAQ;EAClB,aAAa,EAAE,IAAI;EACnB,QAAQ,EAAE,MAAM;EAChB,sBAAa;IACT,aAAa,EAAE,GAAG;;AAI1B,KAAM;EACF,KAAK,EAAE,IAAI;EACX,OAAO,EAAE,KAAK;EACd,MAAM,EAAE,IAAI;EACZ,aAAa,EAAE,cAAqB;EACpC,OAAO,EAAE,QAAQ;EACjB,WAAW,EAAE,OAAO;EACpB,UAAU,EAAE,UAAU;EF6DzB,gCAA6B;IAC5B,KAAK,EC1IM,IAAI;ED4IhB,uBAAoB;IACnB,KAAK,EC7IM,IAAI;ED+IhB,2BAAwB;IACvB,KAAK,EChJM,IAAI;EDkJhB,sBAAmB;IAClB,KAAK,ECnJM,IAAI;EC8Eb,WAAQ;IACJ,aAAa,EAAE,cAAsB;IF0D5C,sCAA6B;MAC5B,KAAK,EC5IQ,IAAI;ID8IlB,6BAAoB;MACnB,KAAK,EC/IQ,IAAI;IDiJlB,iCAAwB;MACvB,KAAK,EClJQ,IAAI;IDoJlB,4BAAmB;MAClB,KAAK,ECrJQ,IAAI;;ACsFnB,6BAA6B;EAC3B,KAAK,EAAO,GAAG;EACf,MAAM,EAAM,CAAC;EACb,OAAO,EAAK,CAAC;EACb,SAAS,EAAG,GAAG;EACf,OAAO,EAAE,IAAI;;AAEf,qCAAqC;EACjC,OAAO,EAAQ,YAAY;EAC3B,WAAW,EAAI,KAAK;EACpB,UAAU,EAAE,GAAG;;AAEnB,4CAA4C;EAC1C,OAAO,EAAY,YAAY;EAC/B,KAAK,EAAc,IAAI;EACvB,MAAM,EAAa,IAAI;EACvB,YAAY,EAAE,IAAI;EAClB,aAAa,EAAE,GAAG;EAClB,MAAM,EAAa,cAAqB;EFtGtC,aAAa,EEuGQ,GAAG;EFtGxB,kBAAkB,EEsGG,GAAG;EFrGxB,qBAAqB,EEqGA,GAAG;EFpGxB,gBAAgB,EEoGK,GAAG;EFnGxB,iBAAiB,EEmGI,GAAG;EAC1B,UAAU,EAAS,KAAgB;EACnC,gBAAgB,EAAM,kCAAuD;EAC7E,gBAAgB,EAAO,iCAAsD;EAC7E,gBAAgB,EAAQ,gCAAqD;EAC7E,gBAAgB,EAAG,qCAA0D;EAC7E,gBAAgB,EAAW,6BAAmD;EAC9E,cAAc,EAAK,MAAM;;AAE3B,oDAAqD;EACjD,gBAAgB,EAAM,kCAAuD;EAC7E,gBAAgB,EAAO,iCAAsD;EAC7E,gBAAgB,EAAQ,gCAAqD;EAC7E,gBAAgB,EAAG,qCAA0D;EAC7E,gBAAgB,EAAW,6BAAmD;;AAElF,2DAA2D;EACvD,OAAO,EAAO,OAAO;EACrB,OAAO,EAAO,KAAK;EACnB,KAAK,ED5HM,IAAI;EC6Hf,SAAS,EAAK,IAAI;EAClB,WAAW,EAAG,GAAG;EACjB,UAAU,EAAI,MAAM;EACpB,WAAW,EAAE,6BAA6B;EAC1C,WAAW,EAAE,IAAI;;AAErB,WAAY;EACR,OAAO,EAAE,YAAY;EACrB,KAAK,EAAE,IAAI;;AAGf,KAAM;EACF,QAAQ,EAAE,QAAQ;EAClB,IAAI,EAAE,CAAC;EACP,GAAG,EAAE,GAAG;EF7GX,SAAS,EAAE,gBAAM;EACjB,cAAc,EAAE,gBAAM;EACtB,iBAAiB,EAAE,gBAAM;EACzB,YAAY,EAAE,gBAAM;EACpB,aAAa,EAAE,gBAAM;EE2GlB,KAAK,ED7IM,IAAI;;AC+InB,gBAAiB;EACb,GAAG,EAAE,GAAG;;AAEZ,WAAY;EACR,QAAQ,EAAE,QAAQ;EAClB,UAAU,EAAE,wCAAwC;EACpD,qBAAqB,EAAE,GAAG;EAC1B,YAAY,EAAE,IAAI;EAClB,OAAO,EAAE,KAAK;EACd,UAAU,EAAE,IAAI;;AAEpB,WAAY;EACR,OAAO,EAAE,KAAK;EAEd,QAAQ,EAAE,QAAQ;EAClB,KAAK,EAAE,CAAC;EACR,IAAI,EAAE,IAAI;EACV,UAAU,EAAE,IAAI;EAChB,KAAK,EAAE,IAAI;EACX,MAAM,EAAE,IAAI;EACZ,UAAU,EAAE,WAAW;EACvB,iBAAQ;IACJ,WAAW,EAAE,6BAA6B;IAC1C,OAAO,EAAE,OAAO;IAChB,KAAK,EAAE,IAAI;IACX,MAAM,EAAE,IAAI;IACZ,QAAQ,EAAE,QAAQ;IAClB,eAAe;IACf,SAAS,EAAE,IAAI;IACf,KAAK,EAAE,KAAK;;AAGpB,iBAAkB;EACd,QAAQ,EAAE,QAAQ;EAClB,GAAG,EAAE,EAAE;EFnJV,SAAS,EAAE,aAAM;EACjB,cAAc,EAAE,aAAM;EACtB,iBAAiB,EAAE,aAAM;EACzB,YAAY,EAAE,aAAM;EACpB,aAAa,EAAE,aAAM;;AEkJtB,oBAAqB;EACjB,SAAS,EAAE,IAAI;;AAMnB,eAAgB;EAEZ,WAAW,EAAE,IAAI;EACjB,cAAc,EAAE,IAAI;;AAGxB,aAAc;EF7Eb,WAAW,EE+Ea,MAAM;EF9E9B,gBAAgB,EE8EQ,MAAM;EF7E9B,mBAAmB,EE6EK,MAAM;EF5E9B,cAAc,EE4EU,MAAM;EF3E9B,eAAe,EE2ES,MAAM;EAC3B,UAAU,EAAE,IAAI;;AAEpB,aAAc;EACV,OAAO,EAAE,YAAY;EACrB,YAAY,EAAE,IAAI;;AAKlB,WAAG;EACC,OAAO,EAAE,GAAG;EACZ,sBAAa;IACT,YAAY,EAAE,GAAG;EAErB,aAAE;IACE,eAAe,EAAE,IAAI;IACrB,eAAE;MACE,KAAK,EAAE,IAAI;MACX,MAAM,EAAE,IAAI;MACZ,KAAK,EAAE,IAAI;MACX,SAAS,EAAE,IAAI;MFtN3B,aAAa,EEuNsB,GAAG;MFtNtC,kBAAkB,EEsNiB,GAAG;MFrNtC,qBAAqB,EEqNc,GAAG;MFpNtC,gBAAgB,EEoNmB,GAAG;MFnNtC,iBAAiB,EEmNkB,GAAG;MF3LzC,SAAS,EAAE,aAAM;MACjB,cAAc,EAAE,aAAM;MACtB,iBAAiB,EAAE,aAAM;MACzB,YAAY,EAAE,aAAM;MACpB,aAAa,EAAE,aAAM;MEyLN,2BAA2B,EAAE,IAAI;MACjC,mBAAmB,EAAE,IAAI;MACzB,2BAA2B,EAAE,SAAS;MACtC,mBAAmB,EAAE,SAAS;MAC9B,kCAAkC,EAAE,QAAQ;MAC5C,0BAA0B,EAAE,QAAQ;EAKpC,qBAAE;IACE,iBAAiB,EAAE,wBAAwB;IAC3C,SAAS,EAAE,wBAAwB;;AAMvD,cAAe;EACX,UAAU,EAAE,OAAO;;AAEvB,aAAc;EACV,UAAU,EAAE,OAAO;;AAEvB,YAAa;EACT,UAAU,EAAE,OAAO;;AAEvB,YAAa;EACT,YAAY,EAAE,IAAI;EAClB,WAAW,EAAE,IAAI;;AAErB,aAAc;EACV,WAAW,EAAE,KAAK;EAClB,YAAY,EAAE,IAAI;EAClB,UAAU,EAAE,IAAI;;ACpPpB,qCAAsC;EAClC,UAAW;IACP,KAAK,EAAE,kBAAkB;IACzB,SAAS,EAAE,IAAI;AAIvB,qCAAsC;EAClC,UAAW;IACP,SAAS,EAAE,MAAM;AAczB,oCAAqC;EAEjC,gCAAiC;IH6DpC,cAAc,EG5DiB,MAAM;IH6DrC,mBAAmB,EG7DY,MAAM;IH8DrC,sBAAsB,EG9DS,MAAM;IH+DrC,iBAAiB,EG/Dc,MAAM;IHgErC,kBAAkB,EGhEa,MAAM;IH0ErC,eAAe,EGzEiB,MAAM;IH0EtC,oBAAoB,EG1EY,MAAM;IH2EtC,uBAAuB,EG3ES,MAAM;IH4EtC,kBAAkB,EG5Ec,MAAM;IH6EtC,mBAAmB,EG7Ea,MAAM;;EAEnC,YAAa;IACT,WAAW,EAAE,GAAG;IAChB,YAAY,EAAE,GAAG;IACjB,YAAY,EAAE,GAAG;IACjB,6BAA6B;IAC7B,OAAO,EAAE,MAAM;;EAEnB,aAAc;IACV,WAAW,EAAE,GAAG;IAChB,YAAY,EAAE,GAAG;IACjB,UAAU,EAAE,IAAI;IH2EvB,KAAK,EG1EiB,CAAC;IH2EvB,UAAU,EG3EY,CAAC;IH4EvB,aAAa,EG5ES,CAAC;IH6EvB,QAAQ,EG7Ec,CAAC;IH8EvB,SAAS,EG9Ea,CAAC;;EAEpB,wDAAyD;IACrD,KAAK,EAAE,IAAI;;EAGf,aAAc;IHsDjB,eAAe,EGrDiB,MAAM;IHsDtC,oBAAoB,EGtDY,MAAM;IHuDtC,uBAAuB,EGvDS,MAAM;IHwDtC,kBAAkB,EGxDc,MAAM;IHyDtC,mBAAmB,EGzDa,MAAM;;EAEnC,YAAa;IACT,UAAU,EAAE,MAAM;;EAEtB,YAAa;IH8DhB,KAAK,EG7DiB,CAAC;IH8DvB,UAAU,EG9DY,CAAC;IH+DvB,aAAa,EG/DS,CAAC;IHgEvB,QAAQ,EGhEc,CAAC;IHiEvB,SAAS,EGjEa,CAAC;IAChB,YAAY,EAAE,GAAG;IACjB,WAAW,EAAE,GAAG;IAChB,OAAO,EAAE,MAAM;;EAEnB,WAAY;IACR,UAAU,EAAE,MAAM;AAoB1B,oCAAqC;EACjC,aAAc;IHMjB,cAAc,EGLiB,MAAM;IHMrC,mBAAmB,EGNY,MAAM;IHOrC,sBAAsB,EGPS,MAAM;IHQrC,iBAAiB,EGRc,MAAM;IHSrC,kBAAkB,EGTa,MAAM;;EAElC,aAAc;IACV,YAAY,EAAE,GAAG;IACjB,aAAa,EAAE,IAAI", +"sources": ["../scss/common/extend.scss","../scss/common/fonts.scss","../scss/common/global.scss","../scss/common/minxi.scss","../scss/common/variables.scss","../scss/layouts/main.scss","../scss/layouts/responsive.scss"], +"names": [], +"file": "style.css" +} \ No newline at end of file diff --git a/public/Auth/fonts/material-icon/css/material-design-iconic-font.css b/public/Auth/fonts/material-icon/css/material-design-iconic-font.css new file mode 100755 index 0000000..2525008 --- /dev/null +++ b/public/Auth/fonts/material-icon/css/material-design-iconic-font.css @@ -0,0 +1,5166 @@ +/*! + * Material Design Iconic Font by Sergey Kupletsky (@zavoloklom) - http://zavoloklom.github.io/material-design-iconic-font/ + * License - http://zavoloklom.github.io/material-design-iconic-font/license (Font: SIL OFL 1.1, CSS: MIT License) + */ +@font-face { + font-family: 'Material-Design-Iconic-Font'; + src: url('../fonts/Material-Design-Iconic-Font.woff2?v=2.2.0') format('woff2'), url('../fonts/Material-Design-Iconic-Font.woff?v=2.2.0') format('woff'), url('../fonts/Material-Design-Iconic-Font.ttf?v=2.2.0') format('truetype'); + font-weight: normal; + font-style: normal; +} +.zmdi { + display: inline-block; + font: normal normal normal 14px/1 'Material-Design-Iconic-Font'; + font-size: inherit; + text-rendering: auto; + -webkit-font-smoothing: antialiased; + -moz-osx-font-smoothing: grayscale; +} +.zmdi-hc-lg { + font-size: 1.33333333em; + line-height: 0.75em; + vertical-align: -15%; +} +.zmdi-hc-2x { + font-size: 2em; +} +.zmdi-hc-3x { + font-size: 3em; +} +.zmdi-hc-4x { + font-size: 4em; +} +.zmdi-hc-5x { + font-size: 5em; +} +.zmdi-hc-fw { + width: 1.28571429em; + text-align: center; +} +.zmdi-hc-ul { + padding-left: 0; + margin-left: 2.14285714em; + list-style-type: none; +} +.zmdi-hc-ul > li { + position: relative; +} +.zmdi-hc-li { + position: absolute; + left: -2.14285714em; + width: 2.14285714em; + top: 0.14285714em; + text-align: center; +} +.zmdi-hc-li.zmdi-hc-lg { + left: -1.85714286em; +} +.zmdi-hc-border { + padding: .1em .25em; + border: solid 0.1em #9e9e9e; + border-radius: 2px; +} +.zmdi-hc-border-circle { + padding: .1em .25em; + border: solid 0.1em #9e9e9e; + border-radius: 50%; +} +.zmdi.pull-left { + float: left; + margin-right: .15em; +} +.zmdi.pull-right { + float: right; + margin-left: .15em; +} +.zmdi-hc-spin { + -webkit-animation: zmdi-spin 1.5s infinite linear; + animation: zmdi-spin 1.5s infinite linear; +} +.zmdi-hc-spin-reverse { + -webkit-animation: zmdi-spin-reverse 1.5s infinite linear; + animation: zmdi-spin-reverse 1.5s infinite linear; +} +@-webkit-keyframes zmdi-spin { + 0% { + -webkit-transform: rotate(0deg); + transform: rotate(0deg); + } + 100% { + -webkit-transform: rotate(359deg); + transform: rotate(359deg); + } +} +@keyframes zmdi-spin { + 0% { + -webkit-transform: rotate(0deg); + transform: rotate(0deg); + } + 100% { + -webkit-transform: rotate(359deg); + transform: rotate(359deg); + } +} +@-webkit-keyframes zmdi-spin-reverse { + 0% { + -webkit-transform: rotate(0deg); + transform: rotate(0deg); + } + 100% { + -webkit-transform: rotate(-359deg); + transform: rotate(-359deg); + } +} +@keyframes zmdi-spin-reverse { + 0% { + -webkit-transform: rotate(0deg); + transform: rotate(0deg); + } + 100% { + -webkit-transform: rotate(-359deg); + transform: rotate(-359deg); + } +} +.zmdi-hc-rotate-90 { + -webkit-transform: rotate(90deg); + -ms-transform: rotate(90deg); + transform: rotate(90deg); +} +.zmdi-hc-rotate-180 { + -webkit-transform: rotate(180deg); + -ms-transform: rotate(180deg); + transform: rotate(180deg); +} +.zmdi-hc-rotate-270 { + -webkit-transform: rotate(270deg); + -ms-transform: rotate(270deg); + transform: rotate(270deg); +} +.zmdi-hc-flip-horizontal { + -webkit-transform: scale(-1, 1); + -ms-transform: scale(-1, 1); + transform: scale(-1, 1); +} +.zmdi-hc-flip-vertical { + -webkit-transform: scale(1, -1); + -ms-transform: scale(1, -1); + transform: scale(1, -1); +} +.zmdi-hc-stack { + position: relative; + display: inline-block; + width: 2em; + height: 2em; + line-height: 2em; + vertical-align: middle; +} +.zmdi-hc-stack-1x, +.zmdi-hc-stack-2x { + position: absolute; + left: 0; + width: 100%; + text-align: center; +} +.zmdi-hc-stack-1x { + line-height: inherit; +} +.zmdi-hc-stack-2x { + font-size: 2em; +} +.zmdi-hc-inverse { + color: #ffffff; +} +/* Material Design Iconic Font uses the Unicode Private Use Area (PUA) to ensure screen + readers do not read off random characters that represent icons */ +.zmdi-3d-rotation:before { + content: '\f101'; +} +.zmdi-airplane-off:before { + content: '\f102'; +} +.zmdi-airplane:before { + content: '\f103'; +} +.zmdi-album:before { + content: '\f104'; +} +.zmdi-archive:before { + content: '\f105'; +} +.zmdi-assignment-account:before { + content: '\f106'; +} +.zmdi-assignment-alert:before { + content: '\f107'; +} +.zmdi-assignment-check:before { + content: '\f108'; +} +.zmdi-assignment-o:before { + content: '\f109'; +} +.zmdi-assignment-return:before { + content: '\f10a'; +} +.zmdi-assignment-returned:before { + content: '\f10b'; +} +.zmdi-assignment:before { + content: '\f10c'; +} +.zmdi-attachment-alt:before { + content: '\f10d'; +} +.zmdi-attachment:before { + content: '\f10e'; +} +.zmdi-audio:before { + content: '\f10f'; +} +.zmdi-badge-check:before { + content: '\f110'; +} +.zmdi-balance-wallet:before { + content: '\f111'; +} +.zmdi-balance:before { + content: '\f112'; +} +.zmdi-battery-alert:before { + content: '\f113'; +} +.zmdi-battery-flash:before { + content: '\f114'; +} +.zmdi-battery-unknown:before { + content: '\f115'; +} +.zmdi-battery:before { + content: '\f116'; +} +.zmdi-bike:before { + content: '\f117'; +} +.zmdi-block-alt:before { + content: '\f118'; +} +.zmdi-block:before { + content: '\f119'; +} +.zmdi-boat:before { + content: '\f11a'; +} +.zmdi-book-image:before { + content: '\f11b'; +} +.zmdi-book:before { + content: '\f11c'; +} +.zmdi-bookmark-outline:before { + content: '\f11d'; +} +.zmdi-bookmark:before { + content: '\f11e'; +} +.zmdi-brush:before { + content: '\f11f'; +} +.zmdi-bug:before { + content: '\f120'; +} +.zmdi-bus:before { + content: '\f121'; +} +.zmdi-cake:before { + content: '\f122'; +} +.zmdi-car-taxi:before { + content: '\f123'; +} +.zmdi-car-wash:before { + content: '\f124'; +} +.zmdi-car:before { + content: '\f125'; +} +.zmdi-card-giftcard:before { + content: '\f126'; +} +.zmdi-card-membership:before { + content: '\f127'; +} +.zmdi-card-travel:before { + content: '\f128'; +} +.zmdi-card:before { + content: '\f129'; +} +.zmdi-case-check:before { + content: '\f12a'; +} +.zmdi-case-download:before { + content: '\f12b'; +} +.zmdi-case-play:before { + content: '\f12c'; +} +.zmdi-case:before { + content: '\f12d'; +} +.zmdi-cast-connected:before { + content: '\f12e'; +} +.zmdi-cast:before { + content: '\f12f'; +} +.zmdi-chart-donut:before { + content: '\f130'; +} +.zmdi-chart:before { + content: '\f131'; +} +.zmdi-city-alt:before { + content: '\f132'; +} +.zmdi-city:before { + content: '\f133'; +} +.zmdi-close-circle-o:before { + content: '\f134'; +} +.zmdi-close-circle:before { + content: '\f135'; +} +.zmdi-close:before { + content: '\f136'; +} +.zmdi-cocktail:before { + content: '\f137'; +} +.zmdi-code-setting:before { + content: '\f138'; +} +.zmdi-code-smartphone:before { + content: '\f139'; +} +.zmdi-code:before { + content: '\f13a'; +} +.zmdi-coffee:before { + content: '\f13b'; +} +.zmdi-collection-bookmark:before { + content: '\f13c'; +} +.zmdi-collection-case-play:before { + content: '\f13d'; +} +.zmdi-collection-folder-image:before { + content: '\f13e'; +} +.zmdi-collection-image-o:before { + content: '\f13f'; +} +.zmdi-collection-image:before { + content: '\f140'; +} +.zmdi-collection-item-1:before { + content: '\f141'; +} +.zmdi-collection-item-2:before { + content: '\f142'; +} +.zmdi-collection-item-3:before { + content: '\f143'; +} +.zmdi-collection-item-4:before { + content: '\f144'; +} +.zmdi-collection-item-5:before { + content: '\f145'; +} +.zmdi-collection-item-6:before { + content: '\f146'; +} +.zmdi-collection-item-7:before { + content: '\f147'; +} +.zmdi-collection-item-8:before { + content: '\f148'; +} +.zmdi-collection-item-9-plus:before { + content: '\f149'; +} +.zmdi-collection-item-9:before { + content: '\f14a'; +} +.zmdi-collection-item:before { + content: '\f14b'; +} +.zmdi-collection-music:before { + content: '\f14c'; +} +.zmdi-collection-pdf:before { + content: '\f14d'; +} +.zmdi-collection-plus:before { + content: '\f14e'; +} +.zmdi-collection-speaker:before { + content: '\f14f'; +} +.zmdi-collection-text:before { + content: '\f150'; +} +.zmdi-collection-video:before { + content: '\f151'; +} +.zmdi-compass:before { + content: '\f152'; +} +.zmdi-cutlery:before { + content: '\f153'; +} +.zmdi-delete:before { + content: '\f154'; +} +.zmdi-dialpad:before { + content: '\f155'; +} +.zmdi-dns:before { + content: '\f156'; +} +.zmdi-drink:before { + content: '\f157'; +} +.zmdi-edit:before { + content: '\f158'; +} +.zmdi-email-open:before { + content: '\f159'; +} +.zmdi-email:before { + content: '\f15a'; +} +.zmdi-eye-off:before { + content: '\f15b'; +} +.zmdi-eye:before { + content: '\f15c'; +} +.zmdi-eyedropper:before { + content: '\f15d'; +} +.zmdi-favorite-outline:before { + content: '\f15e'; +} +.zmdi-favorite:before { + content: '\f15f'; +} +.zmdi-filter-list:before { + content: '\f160'; +} +.zmdi-fire:before { + content: '\f161'; +} +.zmdi-flag:before { + content: '\f162'; +} +.zmdi-flare:before { + content: '\f163'; +} +.zmdi-flash-auto:before { + content: '\f164'; +} +.zmdi-flash-off:before { + content: '\f165'; +} +.zmdi-flash:before { + content: '\f166'; +} +.zmdi-flip:before { + content: '\f167'; +} +.zmdi-flower-alt:before { + content: '\f168'; +} +.zmdi-flower:before { + content: '\f169'; +} +.zmdi-font:before { + content: '\f16a'; +} +.zmdi-fullscreen-alt:before { + content: '\f16b'; +} +.zmdi-fullscreen-exit:before { + content: '\f16c'; +} +.zmdi-fullscreen:before { + content: '\f16d'; +} +.zmdi-functions:before { + content: '\f16e'; +} +.zmdi-gas-station:before { + content: '\f16f'; +} +.zmdi-gesture:before { + content: '\f170'; +} +.zmdi-globe-alt:before { + content: '\f171'; +} +.zmdi-globe-lock:before { + content: '\f172'; +} +.zmdi-globe:before { + content: '\f173'; +} +.zmdi-graduation-cap:before { + content: '\f174'; +} +.zmdi-home:before { + content: '\f175'; +} +.zmdi-hospital-alt:before { + content: '\f176'; +} +.zmdi-hospital:before { + content: '\f177'; +} +.zmdi-hotel:before { + content: '\f178'; +} +.zmdi-hourglass-alt:before { + content: '\f179'; +} +.zmdi-hourglass-outline:before { + content: '\f17a'; +} +.zmdi-hourglass:before { + content: '\f17b'; +} +.zmdi-http:before { + content: '\f17c'; +} +.zmdi-image-alt:before { + content: '\f17d'; +} +.zmdi-image-o:before { + content: '\f17e'; +} +.zmdi-image:before { + content: '\f17f'; +} +.zmdi-inbox:before { + content: '\f180'; +} +.zmdi-invert-colors-off:before { + content: '\f181'; +} +.zmdi-invert-colors:before { + content: '\f182'; +} +.zmdi-key:before { + content: '\f183'; +} +.zmdi-label-alt-outline:before { + content: '\f184'; +} +.zmdi-label-alt:before { + content: '\f185'; +} +.zmdi-label-heart:before { + content: '\f186'; +} +.zmdi-label:before { + content: '\f187'; +} +.zmdi-labels:before { + content: '\f188'; +} +.zmdi-lamp:before { + content: '\f189'; +} +.zmdi-landscape:before { + content: '\f18a'; +} +.zmdi-layers-off:before { + content: '\f18b'; +} +.zmdi-layers:before { + content: '\f18c'; +} +.zmdi-library:before { + content: '\f18d'; +} +.zmdi-link:before { + content: '\f18e'; +} +.zmdi-lock-open:before { + content: '\f18f'; +} +.zmdi-lock-outline:before { + content: '\f190'; +} +.zmdi-lock:before { + content: '\f191'; +} +.zmdi-mail-reply-all:before { + content: '\f192'; +} +.zmdi-mail-reply:before { + content: '\f193'; +} +.zmdi-mail-send:before { + content: '\f194'; +} +.zmdi-mall:before { + content: '\f195'; +} +.zmdi-map:before { + content: '\f196'; +} +.zmdi-menu:before { + content: '\f197'; +} +.zmdi-money-box:before { + content: '\f198'; +} +.zmdi-money-off:before { + content: '\f199'; +} +.zmdi-money:before { + content: '\f19a'; +} +.zmdi-more-vert:before { + content: '\f19b'; +} +.zmdi-more:before { + content: '\f19c'; +} +.zmdi-movie-alt:before { + content: '\f19d'; +} +.zmdi-movie:before { + content: '\f19e'; +} +.zmdi-nature-people:before { + content: '\f19f'; +} +.zmdi-nature:before { + content: '\f1a0'; +} +.zmdi-navigation:before { + content: '\f1a1'; +} +.zmdi-open-in-browser:before { + content: '\f1a2'; +} +.zmdi-open-in-new:before { + content: '\f1a3'; +} +.zmdi-palette:before { + content: '\f1a4'; +} +.zmdi-parking:before { + content: '\f1a5'; +} +.zmdi-pin-account:before { + content: '\f1a6'; +} +.zmdi-pin-assistant:before { + content: '\f1a7'; +} +.zmdi-pin-drop:before { + content: '\f1a8'; +} +.zmdi-pin-help:before { + content: '\f1a9'; +} +.zmdi-pin-off:before { + content: '\f1aa'; +} +.zmdi-pin:before { + content: '\f1ab'; +} +.zmdi-pizza:before { + content: '\f1ac'; +} +.zmdi-plaster:before { + content: '\f1ad'; +} +.zmdi-power-setting:before { + content: '\f1ae'; +} +.zmdi-power:before { + content: '\f1af'; +} +.zmdi-print:before { + content: '\f1b0'; +} +.zmdi-puzzle-piece:before { + content: '\f1b1'; +} +.zmdi-quote:before { + content: '\f1b2'; +} +.zmdi-railway:before { + content: '\f1b3'; +} +.zmdi-receipt:before { + content: '\f1b4'; +} +.zmdi-refresh-alt:before { + content: '\f1b5'; +} +.zmdi-refresh-sync-alert:before { + content: '\f1b6'; +} +.zmdi-refresh-sync-off:before { + content: '\f1b7'; +} +.zmdi-refresh-sync:before { + content: '\f1b8'; +} +.zmdi-refresh:before { + content: '\f1b9'; +} +.zmdi-roller:before { + content: '\f1ba'; +} +.zmdi-ruler:before { + content: '\f1bb'; +} +.zmdi-scissors:before { + content: '\f1bc'; +} +.zmdi-screen-rotation-lock:before { + content: '\f1bd'; +} +.zmdi-screen-rotation:before { + content: '\f1be'; +} +.zmdi-search-for:before { + content: '\f1bf'; +} +.zmdi-search-in-file:before { + content: '\f1c0'; +} +.zmdi-search-in-page:before { + content: '\f1c1'; +} +.zmdi-search-replace:before { + content: '\f1c2'; +} +.zmdi-search:before { + content: '\f1c3'; +} +.zmdi-seat:before { + content: '\f1c4'; +} +.zmdi-settings-square:before { + content: '\f1c5'; +} +.zmdi-settings:before { + content: '\f1c6'; +} +.zmdi-shield-check:before { + content: '\f1c7'; +} +.zmdi-shield-security:before { + content: '\f1c8'; +} +.zmdi-shopping-basket:before { + content: '\f1c9'; +} +.zmdi-shopping-cart-plus:before { + content: '\f1ca'; +} +.zmdi-shopping-cart:before { + content: '\f1cb'; +} +.zmdi-sign-in:before { + content: '\f1cc'; +} +.zmdi-sort-amount-asc:before { + content: '\f1cd'; +} +.zmdi-sort-amount-desc:before { + content: '\f1ce'; +} +.zmdi-sort-asc:before { + content: '\f1cf'; +} +.zmdi-sort-desc:before { + content: '\f1d0'; +} +.zmdi-spellcheck:before { + content: '\f1d1'; +} +.zmdi-storage:before { + content: '\f1d2'; +} +.zmdi-store-24:before { + content: '\f1d3'; +} +.zmdi-store:before { + content: '\f1d4'; +} +.zmdi-subway:before { + content: '\f1d5'; +} +.zmdi-sun:before { + content: '\f1d6'; +} +.zmdi-tab-unselected:before { + content: '\f1d7'; +} +.zmdi-tab:before { + content: '\f1d8'; +} +.zmdi-tag-close:before { + content: '\f1d9'; +} +.zmdi-tag-more:before { + content: '\f1da'; +} +.zmdi-tag:before { + content: '\f1db'; +} +.zmdi-thumb-down:before { + content: '\f1dc'; +} +.zmdi-thumb-up-down:before { + content: '\f1dd'; +} +.zmdi-thumb-up:before { + content: '\f1de'; +} +.zmdi-ticket-star:before { + content: '\f1df'; +} +.zmdi-toll:before { + content: '\f1e0'; +} +.zmdi-toys:before { + content: '\f1e1'; +} +.zmdi-traffic:before { + content: '\f1e2'; +} +.zmdi-translate:before { + content: '\f1e3'; +} +.zmdi-triangle-down:before { + content: '\f1e4'; +} +.zmdi-triangle-up:before { + content: '\f1e5'; +} +.zmdi-truck:before { + content: '\f1e6'; +} +.zmdi-turning-sign:before { + content: '\f1e7'; +} +.zmdi-wallpaper:before { + content: '\f1e8'; +} +.zmdi-washing-machine:before { + content: '\f1e9'; +} +.zmdi-window-maximize:before { + content: '\f1ea'; +} +.zmdi-window-minimize:before { + content: '\f1eb'; +} +.zmdi-window-restore:before { + content: '\f1ec'; +} +.zmdi-wrench:before { + content: '\f1ed'; +} +.zmdi-zoom-in:before { + content: '\f1ee'; +} +.zmdi-zoom-out:before { + content: '\f1ef'; +} +.zmdi-alert-circle-o:before { + content: '\f1f0'; +} +.zmdi-alert-circle:before { + content: '\f1f1'; +} +.zmdi-alert-octagon:before { + content: '\f1f2'; +} +.zmdi-alert-polygon:before { + content: '\f1f3'; +} +.zmdi-alert-triangle:before { + content: '\f1f4'; +} +.zmdi-help-outline:before { + content: '\f1f5'; +} +.zmdi-help:before { + content: '\f1f6'; +} +.zmdi-info-outline:before { + content: '\f1f7'; +} +.zmdi-info:before { + content: '\f1f8'; +} +.zmdi-notifications-active:before { + content: '\f1f9'; +} +.zmdi-notifications-add:before { + content: '\f1fa'; +} +.zmdi-notifications-none:before { + content: '\f1fb'; +} +.zmdi-notifications-off:before { + content: '\f1fc'; +} +.zmdi-notifications-paused:before { + content: '\f1fd'; +} +.zmdi-notifications:before { + content: '\f1fe'; +} +.zmdi-account-add:before { + content: '\f1ff'; +} +.zmdi-account-box-mail:before { + content: '\f200'; +} +.zmdi-account-box-o:before { + content: '\f201'; +} +.zmdi-account-box-phone:before { + content: '\f202'; +} +.zmdi-account-box:before { + content: '\f203'; +} +.zmdi-account-calendar:before { + content: '\f204'; +} +.zmdi-account-circle:before { + content: '\f205'; +} +.zmdi-account-o:before { + content: '\f206'; +} +.zmdi-account:before { + content: '\f207'; +} +.zmdi-accounts-add:before { + content: '\f208'; +} +.zmdi-accounts-alt:before { + content: '\f209'; +} +.zmdi-accounts-list-alt:before { + content: '\f20a'; +} +.zmdi-accounts-list:before { + content: '\f20b'; +} +.zmdi-accounts-outline:before { + content: '\f20c'; +} +.zmdi-accounts:before { + content: '\f20d'; +} +.zmdi-face:before { + content: '\f20e'; +} +.zmdi-female:before { + content: '\f20f'; +} +.zmdi-male-alt:before { + content: '\f210'; +} +.zmdi-male-female:before { + content: '\f211'; +} +.zmdi-male:before { + content: '\f212'; +} +.zmdi-mood-bad:before { + content: '\f213'; +} +.zmdi-mood:before { + content: '\f214'; +} +.zmdi-run:before { + content: '\f215'; +} +.zmdi-walk:before { + content: '\f216'; +} +.zmdi-cloud-box:before { + content: '\f217'; +} +.zmdi-cloud-circle:before { + content: '\f218'; +} +.zmdi-cloud-done:before { + content: '\f219'; +} +.zmdi-cloud-download:before { + content: '\f21a'; +} +.zmdi-cloud-off:before { + content: '\f21b'; +} +.zmdi-cloud-outline-alt:before { + content: '\f21c'; +} +.zmdi-cloud-outline:before { + content: '\f21d'; +} +.zmdi-cloud-upload:before { + content: '\f21e'; +} +.zmdi-cloud:before { + content: '\f21f'; +} +.zmdi-download:before { + content: '\f220'; +} +.zmdi-file-plus:before { + content: '\f221'; +} +.zmdi-file-text:before { + content: '\f222'; +} +.zmdi-file:before { + content: '\f223'; +} +.zmdi-folder-outline:before { + content: '\f224'; +} +.zmdi-folder-person:before { + content: '\f225'; +} +.zmdi-folder-star-alt:before { + content: '\f226'; +} +.zmdi-folder-star:before { + content: '\f227'; +} +.zmdi-folder:before { + content: '\f228'; +} +.zmdi-gif:before { + content: '\f229'; +} +.zmdi-upload:before { + content: '\f22a'; +} +.zmdi-border-all:before { + content: '\f22b'; +} +.zmdi-border-bottom:before { + content: '\f22c'; +} +.zmdi-border-clear:before { + content: '\f22d'; +} +.zmdi-border-color:before { + content: '\f22e'; +} +.zmdi-border-horizontal:before { + content: '\f22f'; +} +.zmdi-border-inner:before { + content: '\f230'; +} +.zmdi-border-left:before { + content: '\f231'; +} +.zmdi-border-outer:before { + content: '\f232'; +} +.zmdi-border-right:before { + content: '\f233'; +} +.zmdi-border-style:before { + content: '\f234'; +} +.zmdi-border-top:before { + content: '\f235'; +} +.zmdi-border-vertical:before { + content: '\f236'; +} +.zmdi-copy:before { + content: '\f237'; +} +.zmdi-crop:before { + content: '\f238'; +} +.zmdi-format-align-center:before { + content: '\f239'; +} +.zmdi-format-align-justify:before { + content: '\f23a'; +} +.zmdi-format-align-left:before { + content: '\f23b'; +} +.zmdi-format-align-right:before { + content: '\f23c'; +} +.zmdi-format-bold:before { + content: '\f23d'; +} +.zmdi-format-clear-all:before { + content: '\f23e'; +} +.zmdi-format-clear:before { + content: '\f23f'; +} +.zmdi-format-color-fill:before { + content: '\f240'; +} +.zmdi-format-color-reset:before { + content: '\f241'; +} +.zmdi-format-color-text:before { + content: '\f242'; +} +.zmdi-format-indent-decrease:before { + content: '\f243'; +} +.zmdi-format-indent-increase:before { + content: '\f244'; +} +.zmdi-format-italic:before { + content: '\f245'; +} +.zmdi-format-line-spacing:before { + content: '\f246'; +} +.zmdi-format-list-bulleted:before { + content: '\f247'; +} +.zmdi-format-list-numbered:before { + content: '\f248'; +} +.zmdi-format-ltr:before { + content: '\f249'; +} +.zmdi-format-rtl:before { + content: '\f24a'; +} +.zmdi-format-size:before { + content: '\f24b'; +} +.zmdi-format-strikethrough-s:before { + content: '\f24c'; +} +.zmdi-format-strikethrough:before { + content: '\f24d'; +} +.zmdi-format-subject:before { + content: '\f24e'; +} +.zmdi-format-underlined:before { + content: '\f24f'; +} +.zmdi-format-valign-bottom:before { + content: '\f250'; +} +.zmdi-format-valign-center:before { + content: '\f251'; +} +.zmdi-format-valign-top:before { + content: '\f252'; +} +.zmdi-redo:before { + content: '\f253'; +} +.zmdi-select-all:before { + content: '\f254'; +} +.zmdi-space-bar:before { + content: '\f255'; +} +.zmdi-text-format:before { + content: '\f256'; +} +.zmdi-transform:before { + content: '\f257'; +} +.zmdi-undo:before { + content: '\f258'; +} +.zmdi-wrap-text:before { + content: '\f259'; +} +.zmdi-comment-alert:before { + content: '\f25a'; +} +.zmdi-comment-alt-text:before { + content: '\f25b'; +} +.zmdi-comment-alt:before { + content: '\f25c'; +} +.zmdi-comment-edit:before { + content: '\f25d'; +} +.zmdi-comment-image:before { + content: '\f25e'; +} +.zmdi-comment-list:before { + content: '\f25f'; +} +.zmdi-comment-more:before { + content: '\f260'; +} +.zmdi-comment-outline:before { + content: '\f261'; +} +.zmdi-comment-text-alt:before { + content: '\f262'; +} +.zmdi-comment-text:before { + content: '\f263'; +} +.zmdi-comment-video:before { + content: '\f264'; +} +.zmdi-comment:before { + content: '\f265'; +} +.zmdi-comments:before { + content: '\f266'; +} +.zmdi-check-all:before { + content: '\f267'; +} +.zmdi-check-circle-u:before { + content: '\f268'; +} +.zmdi-check-circle:before { + content: '\f269'; +} +.zmdi-check-square:before { + content: '\f26a'; +} +.zmdi-check:before { + content: '\f26b'; +} +.zmdi-circle-o:before { + content: '\f26c'; +} +.zmdi-circle:before { + content: '\f26d'; +} +.zmdi-dot-circle-alt:before { + content: '\f26e'; +} +.zmdi-dot-circle:before { + content: '\f26f'; +} +.zmdi-minus-circle-outline:before { + content: '\f270'; +} +.zmdi-minus-circle:before { + content: '\f271'; +} +.zmdi-minus-square:before { + content: '\f272'; +} +.zmdi-minus:before { + content: '\f273'; +} +.zmdi-plus-circle-o-duplicate:before { + content: '\f274'; +} +.zmdi-plus-circle-o:before { + content: '\f275'; +} +.zmdi-plus-circle:before { + content: '\f276'; +} +.zmdi-plus-square:before { + content: '\f277'; +} +.zmdi-plus:before { + content: '\f278'; +} +.zmdi-square-o:before { + content: '\f279'; +} +.zmdi-star-circle:before { + content: '\f27a'; +} +.zmdi-star-half:before { + content: '\f27b'; +} +.zmdi-star-outline:before { + content: '\f27c'; +} +.zmdi-star:before { + content: '\f27d'; +} +.zmdi-bluetooth-connected:before { + content: '\f27e'; +} +.zmdi-bluetooth-off:before { + content: '\f27f'; +} +.zmdi-bluetooth-search:before { + content: '\f280'; +} +.zmdi-bluetooth-setting:before { + content: '\f281'; +} +.zmdi-bluetooth:before { + content: '\f282'; +} +.zmdi-camera-add:before { + content: '\f283'; +} +.zmdi-camera-alt:before { + content: '\f284'; +} +.zmdi-camera-bw:before { + content: '\f285'; +} +.zmdi-camera-front:before { + content: '\f286'; +} +.zmdi-camera-mic:before { + content: '\f287'; +} +.zmdi-camera-party-mode:before { + content: '\f288'; +} +.zmdi-camera-rear:before { + content: '\f289'; +} +.zmdi-camera-roll:before { + content: '\f28a'; +} +.zmdi-camera-switch:before { + content: '\f28b'; +} +.zmdi-camera:before { + content: '\f28c'; +} +.zmdi-card-alert:before { + content: '\f28d'; +} +.zmdi-card-off:before { + content: '\f28e'; +} +.zmdi-card-sd:before { + content: '\f28f'; +} +.zmdi-card-sim:before { + content: '\f290'; +} +.zmdi-desktop-mac:before { + content: '\f291'; +} +.zmdi-desktop-windows:before { + content: '\f292'; +} +.zmdi-device-hub:before { + content: '\f293'; +} +.zmdi-devices-off:before { + content: '\f294'; +} +.zmdi-devices:before { + content: '\f295'; +} +.zmdi-dock:before { + content: '\f296'; +} +.zmdi-floppy:before { + content: '\f297'; +} +.zmdi-gamepad:before { + content: '\f298'; +} +.zmdi-gps-dot:before { + content: '\f299'; +} +.zmdi-gps-off:before { + content: '\f29a'; +} +.zmdi-gps:before { + content: '\f29b'; +} +.zmdi-headset-mic:before { + content: '\f29c'; +} +.zmdi-headset:before { + content: '\f29d'; +} +.zmdi-input-antenna:before { + content: '\f29e'; +} +.zmdi-input-composite:before { + content: '\f29f'; +} +.zmdi-input-hdmi:before { + content: '\f2a0'; +} +.zmdi-input-power:before { + content: '\f2a1'; +} +.zmdi-input-svideo:before { + content: '\f2a2'; +} +.zmdi-keyboard-hide:before { + content: '\f2a3'; +} +.zmdi-keyboard:before { + content: '\f2a4'; +} +.zmdi-laptop-chromebook:before { + content: '\f2a5'; +} +.zmdi-laptop-mac:before { + content: '\f2a6'; +} +.zmdi-laptop:before { + content: '\f2a7'; +} +.zmdi-mic-off:before { + content: '\f2a8'; +} +.zmdi-mic-outline:before { + content: '\f2a9'; +} +.zmdi-mic-setting:before { + content: '\f2aa'; +} +.zmdi-mic:before { + content: '\f2ab'; +} +.zmdi-mouse:before { + content: '\f2ac'; +} +.zmdi-network-alert:before { + content: '\f2ad'; +} +.zmdi-network-locked:before { + content: '\f2ae'; +} +.zmdi-network-off:before { + content: '\f2af'; +} +.zmdi-network-outline:before { + content: '\f2b0'; +} +.zmdi-network-setting:before { + content: '\f2b1'; +} +.zmdi-network:before { + content: '\f2b2'; +} +.zmdi-phone-bluetooth:before { + content: '\f2b3'; +} +.zmdi-phone-end:before { + content: '\f2b4'; +} +.zmdi-phone-forwarded:before { + content: '\f2b5'; +} +.zmdi-phone-in-talk:before { + content: '\f2b6'; +} +.zmdi-phone-locked:before { + content: '\f2b7'; +} +.zmdi-phone-missed:before { + content: '\f2b8'; +} +.zmdi-phone-msg:before { + content: '\f2b9'; +} +.zmdi-phone-paused:before { + content: '\f2ba'; +} +.zmdi-phone-ring:before { + content: '\f2bb'; +} +.zmdi-phone-setting:before { + content: '\f2bc'; +} +.zmdi-phone-sip:before { + content: '\f2bd'; +} +.zmdi-phone:before { + content: '\f2be'; +} +.zmdi-portable-wifi-changes:before { + content: '\f2bf'; +} +.zmdi-portable-wifi-off:before { + content: '\f2c0'; +} +.zmdi-portable-wifi:before { + content: '\f2c1'; +} +.zmdi-radio:before { + content: '\f2c2'; +} +.zmdi-reader:before { + content: '\f2c3'; +} +.zmdi-remote-control-alt:before { + content: '\f2c4'; +} +.zmdi-remote-control:before { + content: '\f2c5'; +} +.zmdi-router:before { + content: '\f2c6'; +} +.zmdi-scanner:before { + content: '\f2c7'; +} +.zmdi-smartphone-android:before { + content: '\f2c8'; +} +.zmdi-smartphone-download:before { + content: '\f2c9'; +} +.zmdi-smartphone-erase:before { + content: '\f2ca'; +} +.zmdi-smartphone-info:before { + content: '\f2cb'; +} +.zmdi-smartphone-iphone:before { + content: '\f2cc'; +} +.zmdi-smartphone-landscape-lock:before { + content: '\f2cd'; +} +.zmdi-smartphone-landscape:before { + content: '\f2ce'; +} +.zmdi-smartphone-lock:before { + content: '\f2cf'; +} +.zmdi-smartphone-portrait-lock:before { + content: '\f2d0'; +} +.zmdi-smartphone-ring:before { + content: '\f2d1'; +} +.zmdi-smartphone-setting:before { + content: '\f2d2'; +} +.zmdi-smartphone-setup:before { + content: '\f2d3'; +} +.zmdi-smartphone:before { + content: '\f2d4'; +} +.zmdi-speaker:before { + content: '\f2d5'; +} +.zmdi-tablet-android:before { + content: '\f2d6'; +} +.zmdi-tablet-mac:before { + content: '\f2d7'; +} +.zmdi-tablet:before { + content: '\f2d8'; +} +.zmdi-tv-alt-play:before { + content: '\f2d9'; +} +.zmdi-tv-list:before { + content: '\f2da'; +} +.zmdi-tv-play:before { + content: '\f2db'; +} +.zmdi-tv:before { + content: '\f2dc'; +} +.zmdi-usb:before { + content: '\f2dd'; +} +.zmdi-videocam-off:before { + content: '\f2de'; +} +.zmdi-videocam-switch:before { + content: '\f2df'; +} +.zmdi-videocam:before { + content: '\f2e0'; +} +.zmdi-watch:before { + content: '\f2e1'; +} +.zmdi-wifi-alt-2:before { + content: '\f2e2'; +} +.zmdi-wifi-alt:before { + content: '\f2e3'; +} +.zmdi-wifi-info:before { + content: '\f2e4'; +} +.zmdi-wifi-lock:before { + content: '\f2e5'; +} +.zmdi-wifi-off:before { + content: '\f2e6'; +} +.zmdi-wifi-outline:before { + content: '\f2e7'; +} +.zmdi-wifi:before { + content: '\f2e8'; +} +.zmdi-arrow-left-bottom:before { + content: '\f2e9'; +} +.zmdi-arrow-left:before { + content: '\f2ea'; +} +.zmdi-arrow-merge:before { + content: '\f2eb'; +} +.zmdi-arrow-missed:before { + content: '\f2ec'; +} +.zmdi-arrow-right-top:before { + content: '\f2ed'; +} +.zmdi-arrow-right:before { + content: '\f2ee'; +} +.zmdi-arrow-split:before { + content: '\f2ef'; +} +.zmdi-arrows:before { + content: '\f2f0'; +} +.zmdi-caret-down-circle:before { + content: '\f2f1'; +} +.zmdi-caret-down:before { + content: '\f2f2'; +} +.zmdi-caret-left-circle:before { + content: '\f2f3'; +} +.zmdi-caret-left:before { + content: '\f2f4'; +} +.zmdi-caret-right-circle:before { + content: '\f2f5'; +} +.zmdi-caret-right:before { + content: '\f2f6'; +} +.zmdi-caret-up-circle:before { + content: '\f2f7'; +} +.zmdi-caret-up:before { + content: '\f2f8'; +} +.zmdi-chevron-down:before { + content: '\f2f9'; +} +.zmdi-chevron-left:before { + content: '\f2fa'; +} +.zmdi-chevron-right:before { + content: '\f2fb'; +} +.zmdi-chevron-up:before { + content: '\f2fc'; +} +.zmdi-forward:before { + content: '\f2fd'; +} +.zmdi-long-arrow-down:before { + content: '\f2fe'; +} +.zmdi-long-arrow-left:before { + content: '\f2ff'; +} +.zmdi-long-arrow-return:before { + content: '\f300'; +} +.zmdi-long-arrow-right:before { + content: '\f301'; +} +.zmdi-long-arrow-tab:before { + content: '\f302'; +} +.zmdi-long-arrow-up:before { + content: '\f303'; +} +.zmdi-rotate-ccw:before { + content: '\f304'; +} +.zmdi-rotate-cw:before { + content: '\f305'; +} +.zmdi-rotate-left:before { + content: '\f306'; +} +.zmdi-rotate-right:before { + content: '\f307'; +} +.zmdi-square-down:before { + content: '\f308'; +} +.zmdi-square-right:before { + content: '\f309'; +} +.zmdi-swap-alt:before { + content: '\f30a'; +} +.zmdi-swap-vertical-circle:before { + content: '\f30b'; +} +.zmdi-swap-vertical:before { + content: '\f30c'; +} +.zmdi-swap:before { + content: '\f30d'; +} +.zmdi-trending-down:before { + content: '\f30e'; +} +.zmdi-trending-flat:before { + content: '\f30f'; +} +.zmdi-trending-up:before { + content: '\f310'; +} +.zmdi-unfold-less:before { + content: '\f311'; +} +.zmdi-unfold-more:before { + content: '\f312'; +} +.zmdi-apps:before { + content: '\f313'; +} +.zmdi-grid-off:before { + content: '\f314'; +} +.zmdi-grid:before { + content: '\f315'; +} +.zmdi-view-agenda:before { + content: '\f316'; +} +.zmdi-view-array:before { + content: '\f317'; +} +.zmdi-view-carousel:before { + content: '\f318'; +} +.zmdi-view-column:before { + content: '\f319'; +} +.zmdi-view-comfy:before { + content: '\f31a'; +} +.zmdi-view-compact:before { + content: '\f31b'; +} +.zmdi-view-dashboard:before { + content: '\f31c'; +} +.zmdi-view-day:before { + content: '\f31d'; +} +.zmdi-view-headline:before { + content: '\f31e'; +} +.zmdi-view-list-alt:before { + content: '\f31f'; +} +.zmdi-view-list:before { + content: '\f320'; +} +.zmdi-view-module:before { + content: '\f321'; +} +.zmdi-view-quilt:before { + content: '\f322'; +} +.zmdi-view-stream:before { + content: '\f323'; +} +.zmdi-view-subtitles:before { + content: '\f324'; +} +.zmdi-view-toc:before { + content: '\f325'; +} +.zmdi-view-web:before { + content: '\f326'; +} +.zmdi-view-week:before { + content: '\f327'; +} +.zmdi-widgets:before { + content: '\f328'; +} +.zmdi-alarm-check:before { + content: '\f329'; +} +.zmdi-alarm-off:before { + content: '\f32a'; +} +.zmdi-alarm-plus:before { + content: '\f32b'; +} +.zmdi-alarm-snooze:before { + content: '\f32c'; +} +.zmdi-alarm:before { + content: '\f32d'; +} +.zmdi-calendar-alt:before { + content: '\f32e'; +} +.zmdi-calendar-check:before { + content: '\f32f'; +} +.zmdi-calendar-close:before { + content: '\f330'; +} +.zmdi-calendar-note:before { + content: '\f331'; +} +.zmdi-calendar:before { + content: '\f332'; +} +.zmdi-time-countdown:before { + content: '\f333'; +} +.zmdi-time-interval:before { + content: '\f334'; +} +.zmdi-time-restore-setting:before { + content: '\f335'; +} +.zmdi-time-restore:before { + content: '\f336'; +} +.zmdi-time:before { + content: '\f337'; +} +.zmdi-timer-off:before { + content: '\f338'; +} +.zmdi-timer:before { + content: '\f339'; +} +.zmdi-android-alt:before { + content: '\f33a'; +} +.zmdi-android:before { + content: '\f33b'; +} +.zmdi-apple:before { + content: '\f33c'; +} +.zmdi-behance:before { + content: '\f33d'; +} +.zmdi-codepen:before { + content: '\f33e'; +} +.zmdi-dribbble:before { + content: '\f33f'; +} +.zmdi-dropbox:before { + content: '\f340'; +} +.zmdi-evernote:before { + content: '\f341'; +} +.zmdi-facebook-box:before { + content: '\f342'; +} +.zmdi-facebook:before { + content: '\f343'; +} +.zmdi-github-box:before { + content: '\f344'; +} +.zmdi-github:before { + content: '\f345'; +} +.zmdi-google-drive:before { + content: '\f346'; +} +.zmdi-google-earth:before { + content: '\f347'; +} +.zmdi-google-glass:before { + content: '\f348'; +} +.zmdi-google-maps:before { + content: '\f349'; +} +.zmdi-google-pages:before { + content: '\f34a'; +} +.zmdi-google-play:before { + content: '\f34b'; +} +.zmdi-google-plus-box:before { + content: '\f34c'; +} +.zmdi-google-plus:before { + content: '\f34d'; +} +.zmdi-google:before { + content: '\f34e'; +} +.zmdi-instagram:before { + content: '\f34f'; +} +.zmdi-language-css3:before { + content: '\f350'; +} +.zmdi-language-html5:before { + content: '\f351'; +} +.zmdi-language-javascript:before { + content: '\f352'; +} +.zmdi-language-python-alt:before { + content: '\f353'; +} +.zmdi-language-python:before { + content: '\f354'; +} +.zmdi-lastfm:before { + content: '\f355'; +} +.zmdi-linkedin-box:before { + content: '\f356'; +} +.zmdi-paypal:before { + content: '\f357'; +} +.zmdi-pinterest-box:before { + content: '\f358'; +} +.zmdi-pocket:before { + content: '\f359'; +} +.zmdi-polymer:before { + content: '\f35a'; +} +.zmdi-share:before { + content: '\f35b'; +} +.zmdi-stackoverflow:before { + content: '\f35c'; +} +.zmdi-steam-square:before { + content: '\f35d'; +} +.zmdi-steam:before { + content: '\f35e'; +} +.zmdi-twitter-box:before { + content: '\f35f'; +} +.zmdi-twitter:before { + content: '\f360'; +} +.zmdi-vk:before { + content: '\f361'; +} +.zmdi-wikipedia:before { + content: '\f362'; +} +.zmdi-windows:before { + content: '\f363'; +} +.zmdi-aspect-ratio-alt:before { + content: '\f364'; +} +.zmdi-aspect-ratio:before { + content: '\f365'; +} +.zmdi-blur-circular:before { + content: '\f366'; +} +.zmdi-blur-linear:before { + content: '\f367'; +} +.zmdi-blur-off:before { + content: '\f368'; +} +.zmdi-blur:before { + content: '\f369'; +} +.zmdi-brightness-2:before { + content: '\f36a'; +} +.zmdi-brightness-3:before { + content: '\f36b'; +} +.zmdi-brightness-4:before { + content: '\f36c'; +} +.zmdi-brightness-5:before { + content: '\f36d'; +} +.zmdi-brightness-6:before { + content: '\f36e'; +} +.zmdi-brightness-7:before { + content: '\f36f'; +} +.zmdi-brightness-auto:before { + content: '\f370'; +} +.zmdi-brightness-setting:before { + content: '\f371'; +} +.zmdi-broken-image:before { + content: '\f372'; +} +.zmdi-center-focus-strong:before { + content: '\f373'; +} +.zmdi-center-focus-weak:before { + content: '\f374'; +} +.zmdi-compare:before { + content: '\f375'; +} +.zmdi-crop-16-9:before { + content: '\f376'; +} +.zmdi-crop-3-2:before { + content: '\f377'; +} +.zmdi-crop-5-4:before { + content: '\f378'; +} +.zmdi-crop-7-5:before { + content: '\f379'; +} +.zmdi-crop-din:before { + content: '\f37a'; +} +.zmdi-crop-free:before { + content: '\f37b'; +} +.zmdi-crop-landscape:before { + content: '\f37c'; +} +.zmdi-crop-portrait:before { + content: '\f37d'; +} +.zmdi-crop-square:before { + content: '\f37e'; +} +.zmdi-exposure-alt:before { + content: '\f37f'; +} +.zmdi-exposure:before { + content: '\f380'; +} +.zmdi-filter-b-and-w:before { + content: '\f381'; +} +.zmdi-filter-center-focus:before { + content: '\f382'; +} +.zmdi-filter-frames:before { + content: '\f383'; +} +.zmdi-filter-tilt-shift:before { + content: '\f384'; +} +.zmdi-gradient:before { + content: '\f385'; +} +.zmdi-grain:before { + content: '\f386'; +} +.zmdi-graphic-eq:before { + content: '\f387'; +} +.zmdi-hdr-off:before { + content: '\f388'; +} +.zmdi-hdr-strong:before { + content: '\f389'; +} +.zmdi-hdr-weak:before { + content: '\f38a'; +} +.zmdi-hdr:before { + content: '\f38b'; +} +.zmdi-iridescent:before { + content: '\f38c'; +} +.zmdi-leak-off:before { + content: '\f38d'; +} +.zmdi-leak:before { + content: '\f38e'; +} +.zmdi-looks:before { + content: '\f38f'; +} +.zmdi-loupe:before { + content: '\f390'; +} +.zmdi-panorama-horizontal:before { + content: '\f391'; +} +.zmdi-panorama-vertical:before { + content: '\f392'; +} +.zmdi-panorama-wide-angle:before { + content: '\f393'; +} +.zmdi-photo-size-select-large:before { + content: '\f394'; +} +.zmdi-photo-size-select-small:before { + content: '\f395'; +} +.zmdi-picture-in-picture:before { + content: '\f396'; +} +.zmdi-slideshow:before { + content: '\f397'; +} +.zmdi-texture:before { + content: '\f398'; +} +.zmdi-tonality:before { + content: '\f399'; +} +.zmdi-vignette:before { + content: '\f39a'; +} +.zmdi-wb-auto:before { + content: '\f39b'; +} +.zmdi-eject-alt:before { + content: '\f39c'; +} +.zmdi-eject:before { + content: '\f39d'; +} +.zmdi-equalizer:before { + content: '\f39e'; +} +.zmdi-fast-forward:before { + content: '\f39f'; +} +.zmdi-fast-rewind:before { + content: '\f3a0'; +} +.zmdi-forward-10:before { + content: '\f3a1'; +} +.zmdi-forward-30:before { + content: '\f3a2'; +} +.zmdi-forward-5:before { + content: '\f3a3'; +} +.zmdi-hearing:before { + content: '\f3a4'; +} +.zmdi-pause-circle-outline:before { + content: '\f3a5'; +} +.zmdi-pause-circle:before { + content: '\f3a6'; +} +.zmdi-pause:before { + content: '\f3a7'; +} +.zmdi-play-circle-outline:before { + content: '\f3a8'; +} +.zmdi-play-circle:before { + content: '\f3a9'; +} +.zmdi-play:before { + content: '\f3aa'; +} +.zmdi-playlist-audio:before { + content: '\f3ab'; +} +.zmdi-playlist-plus:before { + content: '\f3ac'; +} +.zmdi-repeat-one:before { + content: '\f3ad'; +} +.zmdi-repeat:before { + content: '\f3ae'; +} +.zmdi-replay-10:before { + content: '\f3af'; +} +.zmdi-replay-30:before { + content: '\f3b0'; +} +.zmdi-replay-5:before { + content: '\f3b1'; +} +.zmdi-replay:before { + content: '\f3b2'; +} +.zmdi-shuffle:before { + content: '\f3b3'; +} +.zmdi-skip-next:before { + content: '\f3b4'; +} +.zmdi-skip-previous:before { + content: '\f3b5'; +} +.zmdi-stop:before { + content: '\f3b6'; +} +.zmdi-surround-sound:before { + content: '\f3b7'; +} +.zmdi-tune:before { + content: '\f3b8'; +} +.zmdi-volume-down:before { + content: '\f3b9'; +} +.zmdi-volume-mute:before { + content: '\f3ba'; +} +.zmdi-volume-off:before { + content: '\f3bb'; +} +.zmdi-volume-up:before { + content: '\f3bc'; +} +.zmdi-n-1-square:before { + content: '\f3bd'; +} +.zmdi-n-2-square:before { + content: '\f3be'; +} +.zmdi-n-3-square:before { + content: '\f3bf'; +} +.zmdi-n-4-square:before { + content: '\f3c0'; +} +.zmdi-n-5-square:before { + content: '\f3c1'; +} +.zmdi-n-6-square:before { + content: '\f3c2'; +} +.zmdi-neg-1:before { + content: '\f3c3'; +} +.zmdi-neg-2:before { + content: '\f3c4'; +} +.zmdi-plus-1:before { + content: '\f3c5'; +} +.zmdi-plus-2:before { + content: '\f3c6'; +} +.zmdi-sec-10:before { + content: '\f3c7'; +} +.zmdi-sec-3:before { + content: '\f3c8'; +} +.zmdi-zero:before { + content: '\f3c9'; +} +.zmdi-airline-seat-flat-angled:before { + content: '\f3ca'; +} +.zmdi-airline-seat-flat:before { + content: '\f3cb'; +} +.zmdi-airline-seat-individual-suite:before { + content: '\f3cc'; +} +.zmdi-airline-seat-legroom-extra:before { + content: '\f3cd'; +} +.zmdi-airline-seat-legroom-normal:before { + content: '\f3ce'; +} +.zmdi-airline-seat-legroom-reduced:before { + content: '\f3cf'; +} +.zmdi-airline-seat-recline-extra:before { + content: '\f3d0'; +} +.zmdi-airline-seat-recline-normal:before { + content: '\f3d1'; +} +.zmdi-airplay:before { + content: '\f3d2'; +} +.zmdi-closed-caption:before { + content: '\f3d3'; +} +.zmdi-confirmation-number:before { + content: '\f3d4'; +} +.zmdi-developer-board:before { + content: '\f3d5'; +} +.zmdi-disc-full:before { + content: '\f3d6'; +} +.zmdi-explicit:before { + content: '\f3d7'; +} +.zmdi-flight-land:before { + content: '\f3d8'; +} +.zmdi-flight-takeoff:before { + content: '\f3d9'; +} +.zmdi-flip-to-back:before { + content: '\f3da'; +} +.zmdi-flip-to-front:before { + content: '\f3db'; +} +.zmdi-group-work:before { + content: '\f3dc'; +} +.zmdi-hd:before { + content: '\f3dd'; +} +.zmdi-hq:before { + content: '\f3de'; +} +.zmdi-markunread-mailbox:before { + content: '\f3df'; +} +.zmdi-memory:before { + content: '\f3e0'; +} +.zmdi-nfc:before { + content: '\f3e1'; +} +.zmdi-play-for-work:before { + content: '\f3e2'; +} +.zmdi-power-input:before { + content: '\f3e3'; +} +.zmdi-present-to-all:before { + content: '\f3e4'; +} +.zmdi-satellite:before { + content: '\f3e5'; +} +.zmdi-tap-and-play:before { + content: '\f3e6'; +} +.zmdi-vibration:before { + content: '\f3e7'; +} +.zmdi-voicemail:before { + content: '\f3e8'; +} +.zmdi-group:before { + content: '\f3e9'; +} +.zmdi-rss:before { + content: '\f3ea'; +} +.zmdi-shape:before { + content: '\f3eb'; +} +.zmdi-spinner:before { + content: '\f3ec'; +} +.zmdi-ungroup:before { + content: '\f3ed'; +} +.zmdi-500px:before { + content: '\f3ee'; +} +.zmdi-8tracks:before { + content: '\f3ef'; +} +.zmdi-amazon:before { + content: '\f3f0'; +} +.zmdi-blogger:before { + content: '\f3f1'; +} +.zmdi-delicious:before { + content: '\f3f2'; +} +.zmdi-disqus:before { + content: '\f3f3'; +} +.zmdi-flattr:before { + content: '\f3f4'; +} +.zmdi-flickr:before { + content: '\f3f5'; +} +.zmdi-github-alt:before { + content: '\f3f6'; +} +.zmdi-google-old:before { + content: '\f3f7'; +} +.zmdi-linkedin:before { + content: '\f3f8'; +} +.zmdi-odnoklassniki:before { + content: '\f3f9'; +} +.zmdi-outlook:before { + content: '\f3fa'; +} +.zmdi-paypal-alt:before { + content: '\f3fb'; +} +.zmdi-pinterest:before { + content: '\f3fc'; +} +.zmdi-playstation:before { + content: '\f3fd'; +} +.zmdi-reddit:before { + content: '\f3fe'; +} +.zmdi-skype:before { + content: '\f3ff'; +} +.zmdi-slideshare:before { + content: '\f400'; +} +.zmdi-soundcloud:before { + content: '\f401'; +} +.zmdi-tumblr:before { + content: '\f402'; +} +.zmdi-twitch:before { + content: '\f403'; +} +.zmdi-vimeo:before { + content: '\f404'; +} +.zmdi-whatsapp:before { + content: '\f405'; +} +.zmdi-xbox:before { + content: '\f406'; +} +.zmdi-yahoo:before { + content: '\f407'; +} +.zmdi-youtube-play:before { + content: '\f408'; +} +.zmdi-youtube:before { + content: '\f409'; +} +.zmdi-3d-rotation:before { + content: '\f101'; +} +.zmdi-airplane-off:before { + content: '\f102'; +} +.zmdi-airplane:before { + content: '\f103'; +} +.zmdi-album:before { + content: '\f104'; +} +.zmdi-archive:before { + content: '\f105'; +} +.zmdi-assignment-account:before { + content: '\f106'; +} +.zmdi-assignment-alert:before { + content: '\f107'; +} +.zmdi-assignment-check:before { + content: '\f108'; +} +.zmdi-assignment-o:before { + content: '\f109'; +} +.zmdi-assignment-return:before { + content: '\f10a'; +} +.zmdi-assignment-returned:before { + content: '\f10b'; +} +.zmdi-assignment:before { + content: '\f10c'; +} +.zmdi-attachment-alt:before { + content: '\f10d'; +} +.zmdi-attachment:before { + content: '\f10e'; +} +.zmdi-audio:before { + content: '\f10f'; +} +.zmdi-badge-check:before { + content: '\f110'; +} +.zmdi-balance-wallet:before { + content: '\f111'; +} +.zmdi-balance:before { + content: '\f112'; +} +.zmdi-battery-alert:before { + content: '\f113'; +} +.zmdi-battery-flash:before { + content: '\f114'; +} +.zmdi-battery-unknown:before { + content: '\f115'; +} +.zmdi-battery:before { + content: '\f116'; +} +.zmdi-bike:before { + content: '\f117'; +} +.zmdi-block-alt:before { + content: '\f118'; +} +.zmdi-block:before { + content: '\f119'; +} +.zmdi-boat:before { + content: '\f11a'; +} +.zmdi-book-image:before { + content: '\f11b'; +} +.zmdi-book:before { + content: '\f11c'; +} +.zmdi-bookmark-outline:before { + content: '\f11d'; +} +.zmdi-bookmark:before { + content: '\f11e'; +} +.zmdi-brush:before { + content: '\f11f'; +} +.zmdi-bug:before { + content: '\f120'; +} +.zmdi-bus:before { + content: '\f121'; +} +.zmdi-cake:before { + content: '\f122'; +} +.zmdi-car-taxi:before { + content: '\f123'; +} +.zmdi-car-wash:before { + content: '\f124'; +} +.zmdi-car:before { + content: '\f125'; +} +.zmdi-card-giftcard:before { + content: '\f126'; +} +.zmdi-card-membership:before { + content: '\f127'; +} +.zmdi-card-travel:before { + content: '\f128'; +} +.zmdi-card:before { + content: '\f129'; +} +.zmdi-case-check:before { + content: '\f12a'; +} +.zmdi-case-download:before { + content: '\f12b'; +} +.zmdi-case-play:before { + content: '\f12c'; +} +.zmdi-case:before { + content: '\f12d'; +} +.zmdi-cast-connected:before { + content: '\f12e'; +} +.zmdi-cast:before { + content: '\f12f'; +} +.zmdi-chart-donut:before { + content: '\f130'; +} +.zmdi-chart:before { + content: '\f131'; +} +.zmdi-city-alt:before { + content: '\f132'; +} +.zmdi-city:before { + content: '\f133'; +} +.zmdi-close-circle-o:before { + content: '\f134'; +} +.zmdi-close-circle:before { + content: '\f135'; +} +.zmdi-close:before { + content: '\f136'; +} +.zmdi-cocktail:before { + content: '\f137'; +} +.zmdi-code-setting:before { + content: '\f138'; +} +.zmdi-code-smartphone:before { + content: '\f139'; +} +.zmdi-code:before { + content: '\f13a'; +} +.zmdi-coffee:before { + content: '\f13b'; +} +.zmdi-collection-bookmark:before { + content: '\f13c'; +} +.zmdi-collection-case-play:before { + content: '\f13d'; +} +.zmdi-collection-folder-image:before { + content: '\f13e'; +} +.zmdi-collection-image-o:before { + content: '\f13f'; +} +.zmdi-collection-image:before { + content: '\f140'; +} +.zmdi-collection-item-1:before { + content: '\f141'; +} +.zmdi-collection-item-2:before { + content: '\f142'; +} +.zmdi-collection-item-3:before { + content: '\f143'; +} +.zmdi-collection-item-4:before { + content: '\f144'; +} +.zmdi-collection-item-5:before { + content: '\f145'; +} +.zmdi-collection-item-6:before { + content: '\f146'; +} +.zmdi-collection-item-7:before { + content: '\f147'; +} +.zmdi-collection-item-8:before { + content: '\f148'; +} +.zmdi-collection-item-9-plus:before { + content: '\f149'; +} +.zmdi-collection-item-9:before { + content: '\f14a'; +} +.zmdi-collection-item:before { + content: '\f14b'; +} +.zmdi-collection-music:before { + content: '\f14c'; +} +.zmdi-collection-pdf:before { + content: '\f14d'; +} +.zmdi-collection-plus:before { + content: '\f14e'; +} +.zmdi-collection-speaker:before { + content: '\f14f'; +} +.zmdi-collection-text:before { + content: '\f150'; +} +.zmdi-collection-video:before { + content: '\f151'; +} +.zmdi-compass:before { + content: '\f152'; +} +.zmdi-cutlery:before { + content: '\f153'; +} +.zmdi-delete:before { + content: '\f154'; +} +.zmdi-dialpad:before { + content: '\f155'; +} +.zmdi-dns:before { + content: '\f156'; +} +.zmdi-drink:before { + content: '\f157'; +} +.zmdi-edit:before { + content: '\f158'; +} +.zmdi-email-open:before { + content: '\f159'; +} +.zmdi-email:before { + content: '\f15a'; +} +.zmdi-eye-off:before { + content: '\f15b'; +} +.zmdi-eye:before { + content: '\f15c'; +} +.zmdi-eyedropper:before { + content: '\f15d'; +} +.zmdi-favorite-outline:before { + content: '\f15e'; +} +.zmdi-favorite:before { + content: '\f15f'; +} +.zmdi-filter-list:before { + content: '\f160'; +} +.zmdi-fire:before { + content: '\f161'; +} +.zmdi-flag:before { + content: '\f162'; +} +.zmdi-flare:before { + content: '\f163'; +} +.zmdi-flash-auto:before { + content: '\f164'; +} +.zmdi-flash-off:before { + content: '\f165'; +} +.zmdi-flash:before { + content: '\f166'; +} +.zmdi-flip:before { + content: '\f167'; +} +.zmdi-flower-alt:before { + content: '\f168'; +} +.zmdi-flower:before { + content: '\f169'; +} +.zmdi-font:before { + content: '\f16a'; +} +.zmdi-fullscreen-alt:before { + content: '\f16b'; +} +.zmdi-fullscreen-exit:before { + content: '\f16c'; +} +.zmdi-fullscreen:before { + content: '\f16d'; +} +.zmdi-functions:before { + content: '\f16e'; +} +.zmdi-gas-station:before { + content: '\f16f'; +} +.zmdi-gesture:before { + content: '\f170'; +} +.zmdi-globe-alt:before { + content: '\f171'; +} +.zmdi-globe-lock:before { + content: '\f172'; +} +.zmdi-globe:before { + content: '\f173'; +} +.zmdi-graduation-cap:before { + content: '\f174'; +} +.zmdi-home:before { + content: '\f175'; +} +.zmdi-hospital-alt:before { + content: '\f176'; +} +.zmdi-hospital:before { + content: '\f177'; +} +.zmdi-hotel:before { + content: '\f178'; +} +.zmdi-hourglass-alt:before { + content: '\f179'; +} +.zmdi-hourglass-outline:before { + content: '\f17a'; +} +.zmdi-hourglass:before { + content: '\f17b'; +} +.zmdi-http:before { + content: '\f17c'; +} +.zmdi-image-alt:before { + content: '\f17d'; +} +.zmdi-image-o:before { + content: '\f17e'; +} +.zmdi-image:before { + content: '\f17f'; +} +.zmdi-inbox:before { + content: '\f180'; +} +.zmdi-invert-colors-off:before { + content: '\f181'; +} +.zmdi-invert-colors:before { + content: '\f182'; +} +.zmdi-key:before { + content: '\f183'; +} +.zmdi-label-alt-outline:before { + content: '\f184'; +} +.zmdi-label-alt:before { + content: '\f185'; +} +.zmdi-label-heart:before { + content: '\f186'; +} +.zmdi-label:before { + content: '\f187'; +} +.zmdi-labels:before { + content: '\f188'; +} +.zmdi-lamp:before { + content: '\f189'; +} +.zmdi-landscape:before { + content: '\f18a'; +} +.zmdi-layers-off:before { + content: '\f18b'; +} +.zmdi-layers:before { + content: '\f18c'; +} +.zmdi-library:before { + content: '\f18d'; +} +.zmdi-link:before { + content: '\f18e'; +} +.zmdi-lock-open:before { + content: '\f18f'; +} +.zmdi-lock-outline:before { + content: '\f190'; +} +.zmdi-lock:before { + content: '\f191'; +} +.zmdi-mail-reply-all:before { + content: '\f192'; +} +.zmdi-mail-reply:before { + content: '\f193'; +} +.zmdi-mail-send:before { + content: '\f194'; +} +.zmdi-mall:before { + content: '\f195'; +} +.zmdi-map:before { + content: '\f196'; +} +.zmdi-menu:before { + content: '\f197'; +} +.zmdi-money-box:before { + content: '\f198'; +} +.zmdi-money-off:before { + content: '\f199'; +} +.zmdi-money:before { + content: '\f19a'; +} +.zmdi-more-vert:before { + content: '\f19b'; +} +.zmdi-more:before { + content: '\f19c'; +} +.zmdi-movie-alt:before { + content: '\f19d'; +} +.zmdi-movie:before { + content: '\f19e'; +} +.zmdi-nature-people:before { + content: '\f19f'; +} +.zmdi-nature:before { + content: '\f1a0'; +} +.zmdi-navigation:before { + content: '\f1a1'; +} +.zmdi-open-in-browser:before { + content: '\f1a2'; +} +.zmdi-open-in-new:before { + content: '\f1a3'; +} +.zmdi-palette:before { + content: '\f1a4'; +} +.zmdi-parking:before { + content: '\f1a5'; +} +.zmdi-pin-account:before { + content: '\f1a6'; +} +.zmdi-pin-assistant:before { + content: '\f1a7'; +} +.zmdi-pin-drop:before { + content: '\f1a8'; +} +.zmdi-pin-help:before { + content: '\f1a9'; +} +.zmdi-pin-off:before { + content: '\f1aa'; +} +.zmdi-pin:before { + content: '\f1ab'; +} +.zmdi-pizza:before { + content: '\f1ac'; +} +.zmdi-plaster:before { + content: '\f1ad'; +} +.zmdi-power-setting:before { + content: '\f1ae'; +} +.zmdi-power:before { + content: '\f1af'; +} +.zmdi-print:before { + content: '\f1b0'; +} +.zmdi-puzzle-piece:before { + content: '\f1b1'; +} +.zmdi-quote:before { + content: '\f1b2'; +} +.zmdi-railway:before { + content: '\f1b3'; +} +.zmdi-receipt:before { + content: '\f1b4'; +} +.zmdi-refresh-alt:before { + content: '\f1b5'; +} +.zmdi-refresh-sync-alert:before { + content: '\f1b6'; +} +.zmdi-refresh-sync-off:before { + content: '\f1b7'; +} +.zmdi-refresh-sync:before { + content: '\f1b8'; +} +.zmdi-refresh:before { + content: '\f1b9'; +} +.zmdi-roller:before { + content: '\f1ba'; +} +.zmdi-ruler:before { + content: '\f1bb'; +} +.zmdi-scissors:before { + content: '\f1bc'; +} +.zmdi-screen-rotation-lock:before { + content: '\f1bd'; +} +.zmdi-screen-rotation:before { + content: '\f1be'; +} +.zmdi-search-for:before { + content: '\f1bf'; +} +.zmdi-search-in-file:before { + content: '\f1c0'; +} +.zmdi-search-in-page:before { + content: '\f1c1'; +} +.zmdi-search-replace:before { + content: '\f1c2'; +} +.zmdi-search:before { + content: '\f1c3'; +} +.zmdi-seat:before { + content: '\f1c4'; +} +.zmdi-settings-square:before { + content: '\f1c5'; +} +.zmdi-settings:before { + content: '\f1c6'; +} +.zmdi-shield-check:before { + content: '\f1c7'; +} +.zmdi-shield-security:before { + content: '\f1c8'; +} +.zmdi-shopping-basket:before { + content: '\f1c9'; +} +.zmdi-shopping-cart-plus:before { + content: '\f1ca'; +} +.zmdi-shopping-cart:before { + content: '\f1cb'; +} +.zmdi-sign-in:before { + content: '\f1cc'; +} +.zmdi-sort-amount-asc:before { + content: '\f1cd'; +} +.zmdi-sort-amount-desc:before { + content: '\f1ce'; +} +.zmdi-sort-asc:before { + content: '\f1cf'; +} +.zmdi-sort-desc:before { + content: '\f1d0'; +} +.zmdi-spellcheck:before { + content: '\f1d1'; +} +.zmdi-storage:before { + content: '\f1d2'; +} +.zmdi-store-24:before { + content: '\f1d3'; +} +.zmdi-store:before { + content: '\f1d4'; +} +.zmdi-subway:before { + content: '\f1d5'; +} +.zmdi-sun:before { + content: '\f1d6'; +} +.zmdi-tab-unselected:before { + content: '\f1d7'; +} +.zmdi-tab:before { + content: '\f1d8'; +} +.zmdi-tag-close:before { + content: '\f1d9'; +} +.zmdi-tag-more:before { + content: '\f1da'; +} +.zmdi-tag:before { + content: '\f1db'; +} +.zmdi-thumb-down:before { + content: '\f1dc'; +} +.zmdi-thumb-up-down:before { + content: '\f1dd'; +} +.zmdi-thumb-up:before { + content: '\f1de'; +} +.zmdi-ticket-star:before { + content: '\f1df'; +} +.zmdi-toll:before { + content: '\f1e0'; +} +.zmdi-toys:before { + content: '\f1e1'; +} +.zmdi-traffic:before { + content: '\f1e2'; +} +.zmdi-translate:before { + content: '\f1e3'; +} +.zmdi-triangle-down:before { + content: '\f1e4'; +} +.zmdi-triangle-up:before { + content: '\f1e5'; +} +.zmdi-truck:before { + content: '\f1e6'; +} +.zmdi-turning-sign:before { + content: '\f1e7'; +} +.zmdi-wallpaper:before { + content: '\f1e8'; +} +.zmdi-washing-machine:before { + content: '\f1e9'; +} +.zmdi-window-maximize:before { + content: '\f1ea'; +} +.zmdi-window-minimize:before { + content: '\f1eb'; +} +.zmdi-window-restore:before { + content: '\f1ec'; +} +.zmdi-wrench:before { + content: '\f1ed'; +} +.zmdi-zoom-in:before { + content: '\f1ee'; +} +.zmdi-zoom-out:before { + content: '\f1ef'; +} +.zmdi-alert-circle-o:before { + content: '\f1f0'; +} +.zmdi-alert-circle:before { + content: '\f1f1'; +} +.zmdi-alert-octagon:before { + content: '\f1f2'; +} +.zmdi-alert-polygon:before { + content: '\f1f3'; +} +.zmdi-alert-triangle:before { + content: '\f1f4'; +} +.zmdi-help-outline:before { + content: '\f1f5'; +} +.zmdi-help:before { + content: '\f1f6'; +} +.zmdi-info-outline:before { + content: '\f1f7'; +} +.zmdi-info:before { + content: '\f1f8'; +} +.zmdi-notifications-active:before { + content: '\f1f9'; +} +.zmdi-notifications-add:before { + content: '\f1fa'; +} +.zmdi-notifications-none:before { + content: '\f1fb'; +} +.zmdi-notifications-off:before { + content: '\f1fc'; +} +.zmdi-notifications-paused:before { + content: '\f1fd'; +} +.zmdi-notifications:before { + content: '\f1fe'; +} +.zmdi-account-add:before { + content: '\f1ff'; +} +.zmdi-account-box-mail:before { + content: '\f200'; +} +.zmdi-account-box-o:before { + content: '\f201'; +} +.zmdi-account-box-phone:before { + content: '\f202'; +} +.zmdi-account-box:before { + content: '\f203'; +} +.zmdi-account-calendar:before { + content: '\f204'; +} +.zmdi-account-circle:before { + content: '\f205'; +} +.zmdi-account-o:before { + content: '\f206'; +} +.zmdi-account:before { + content: '\f207'; +} +.zmdi-accounts-add:before { + content: '\f208'; +} +.zmdi-accounts-alt:before { + content: '\f209'; +} +.zmdi-accounts-list-alt:before { + content: '\f20a'; +} +.zmdi-accounts-list:before { + content: '\f20b'; +} +.zmdi-accounts-outline:before { + content: '\f20c'; +} +.zmdi-accounts:before { + content: '\f20d'; +} +.zmdi-face:before { + content: '\f20e'; +} +.zmdi-female:before { + content: '\f20f'; +} +.zmdi-male-alt:before { + content: '\f210'; +} +.zmdi-male-female:before { + content: '\f211'; +} +.zmdi-male:before { + content: '\f212'; +} +.zmdi-mood-bad:before { + content: '\f213'; +} +.zmdi-mood:before { + content: '\f214'; +} +.zmdi-run:before { + content: '\f215'; +} +.zmdi-walk:before { + content: '\f216'; +} +.zmdi-cloud-box:before { + content: '\f217'; +} +.zmdi-cloud-circle:before { + content: '\f218'; +} +.zmdi-cloud-done:before { + content: '\f219'; +} +.zmdi-cloud-download:before { + content: '\f21a'; +} +.zmdi-cloud-off:before { + content: '\f21b'; +} +.zmdi-cloud-outline-alt:before { + content: '\f21c'; +} +.zmdi-cloud-outline:before { + content: '\f21d'; +} +.zmdi-cloud-upload:before { + content: '\f21e'; +} +.zmdi-cloud:before { + content: '\f21f'; +} +.zmdi-download:before { + content: '\f220'; +} +.zmdi-file-plus:before { + content: '\f221'; +} +.zmdi-file-text:before { + content: '\f222'; +} +.zmdi-file:before { + content: '\f223'; +} +.zmdi-folder-outline:before { + content: '\f224'; +} +.zmdi-folder-person:before { + content: '\f225'; +} +.zmdi-folder-star-alt:before { + content: '\f226'; +} +.zmdi-folder-star:before { + content: '\f227'; +} +.zmdi-folder:before { + content: '\f228'; +} +.zmdi-gif:before { + content: '\f229'; +} +.zmdi-upload:before { + content: '\f22a'; +} +.zmdi-border-all:before { + content: '\f22b'; +} +.zmdi-border-bottom:before { + content: '\f22c'; +} +.zmdi-border-clear:before { + content: '\f22d'; +} +.zmdi-border-color:before { + content: '\f22e'; +} +.zmdi-border-horizontal:before { + content: '\f22f'; +} +.zmdi-border-inner:before { + content: '\f230'; +} +.zmdi-border-left:before { + content: '\f231'; +} +.zmdi-border-outer:before { + content: '\f232'; +} +.zmdi-border-right:before { + content: '\f233'; +} +.zmdi-border-style:before { + content: '\f234'; +} +.zmdi-border-top:before { + content: '\f235'; +} +.zmdi-border-vertical:before { + content: '\f236'; +} +.zmdi-copy:before { + content: '\f237'; +} +.zmdi-crop:before { + content: '\f238'; +} +.zmdi-format-align-center:before { + content: '\f239'; +} +.zmdi-format-align-justify:before { + content: '\f23a'; +} +.zmdi-format-align-left:before { + content: '\f23b'; +} +.zmdi-format-align-right:before { + content: '\f23c'; +} +.zmdi-format-bold:before { + content: '\f23d'; +} +.zmdi-format-clear-all:before { + content: '\f23e'; +} +.zmdi-format-clear:before { + content: '\f23f'; +} +.zmdi-format-color-fill:before { + content: '\f240'; +} +.zmdi-format-color-reset:before { + content: '\f241'; +} +.zmdi-format-color-text:before { + content: '\f242'; +} +.zmdi-format-indent-decrease:before { + content: '\f243'; +} +.zmdi-format-indent-increase:before { + content: '\f244'; +} +.zmdi-format-italic:before { + content: '\f245'; +} +.zmdi-format-line-spacing:before { + content: '\f246'; +} +.zmdi-format-list-bulleted:before { + content: '\f247'; +} +.zmdi-format-list-numbered:before { + content: '\f248'; +} +.zmdi-format-ltr:before { + content: '\f249'; +} +.zmdi-format-rtl:before { + content: '\f24a'; +} +.zmdi-format-size:before { + content: '\f24b'; +} +.zmdi-format-strikethrough-s:before { + content: '\f24c'; +} +.zmdi-format-strikethrough:before { + content: '\f24d'; +} +.zmdi-format-subject:before { + content: '\f24e'; +} +.zmdi-format-underlined:before { + content: '\f24f'; +} +.zmdi-format-valign-bottom:before { + content: '\f250'; +} +.zmdi-format-valign-center:before { + content: '\f251'; +} +.zmdi-format-valign-top:before { + content: '\f252'; +} +.zmdi-redo:before { + content: '\f253'; +} +.zmdi-select-all:before { + content: '\f254'; +} +.zmdi-space-bar:before { + content: '\f255'; +} +.zmdi-text-format:before { + content: '\f256'; +} +.zmdi-transform:before { + content: '\f257'; +} +.zmdi-undo:before { + content: '\f258'; +} +.zmdi-wrap-text:before { + content: '\f259'; +} +.zmdi-comment-alert:before { + content: '\f25a'; +} +.zmdi-comment-alt-text:before { + content: '\f25b'; +} +.zmdi-comment-alt:before { + content: '\f25c'; +} +.zmdi-comment-edit:before { + content: '\f25d'; +} +.zmdi-comment-image:before { + content: '\f25e'; +} +.zmdi-comment-list:before { + content: '\f25f'; +} +.zmdi-comment-more:before { + content: '\f260'; +} +.zmdi-comment-outline:before { + content: '\f261'; +} +.zmdi-comment-text-alt:before { + content: '\f262'; +} +.zmdi-comment-text:before { + content: '\f263'; +} +.zmdi-comment-video:before { + content: '\f264'; +} +.zmdi-comment:before { + content: '\f265'; +} +.zmdi-comments:before { + content: '\f266'; +} +.zmdi-check-all:before { + content: '\f267'; +} +.zmdi-check-circle-u:before { + content: '\f268'; +} +.zmdi-check-circle:before { + content: '\f269'; +} +.zmdi-check-square:before { + content: '\f26a'; +} +.zmdi-check:before { + content: '\f26b'; +} +.zmdi-circle-o:before { + content: '\f26c'; +} +.zmdi-circle:before { + content: '\f26d'; +} +.zmdi-dot-circle-alt:before { + content: '\f26e'; +} +.zmdi-dot-circle:before { + content: '\f26f'; +} +.zmdi-minus-circle-outline:before { + content: '\f270'; +} +.zmdi-minus-circle:before { + content: '\f271'; +} +.zmdi-minus-square:before { + content: '\f272'; +} +.zmdi-minus:before { + content: '\f273'; +} +.zmdi-plus-circle-o-duplicate:before { + content: '\f274'; +} +.zmdi-plus-circle-o:before { + content: '\f275'; +} +.zmdi-plus-circle:before { + content: '\f276'; +} +.zmdi-plus-square:before { + content: '\f277'; +} +.zmdi-plus:before { + content: '\f278'; +} +.zmdi-square-o:before { + content: '\f279'; +} +.zmdi-star-circle:before { + content: '\f27a'; +} +.zmdi-star-half:before { + content: '\f27b'; +} +.zmdi-star-outline:before { + content: '\f27c'; +} +.zmdi-star:before { + content: '\f27d'; +} +.zmdi-bluetooth-connected:before { + content: '\f27e'; +} +.zmdi-bluetooth-off:before { + content: '\f27f'; +} +.zmdi-bluetooth-search:before { + content: '\f280'; +} +.zmdi-bluetooth-setting:before { + content: '\f281'; +} +.zmdi-bluetooth:before { + content: '\f282'; +} +.zmdi-camera-add:before { + content: '\f283'; +} +.zmdi-camera-alt:before { + content: '\f284'; +} +.zmdi-camera-bw:before { + content: '\f285'; +} +.zmdi-camera-front:before { + content: '\f286'; +} +.zmdi-camera-mic:before { + content: '\f287'; +} +.zmdi-camera-party-mode:before { + content: '\f288'; +} +.zmdi-camera-rear:before { + content: '\f289'; +} +.zmdi-camera-roll:before { + content: '\f28a'; +} +.zmdi-camera-switch:before { + content: '\f28b'; +} +.zmdi-camera:before { + content: '\f28c'; +} +.zmdi-card-alert:before { + content: '\f28d'; +} +.zmdi-card-off:before { + content: '\f28e'; +} +.zmdi-card-sd:before { + content: '\f28f'; +} +.zmdi-card-sim:before { + content: '\f290'; +} +.zmdi-desktop-mac:before { + content: '\f291'; +} +.zmdi-desktop-windows:before { + content: '\f292'; +} +.zmdi-device-hub:before { + content: '\f293'; +} +.zmdi-devices-off:before { + content: '\f294'; +} +.zmdi-devices:before { + content: '\f295'; +} +.zmdi-dock:before { + content: '\f296'; +} +.zmdi-floppy:before { + content: '\f297'; +} +.zmdi-gamepad:before { + content: '\f298'; +} +.zmdi-gps-dot:before { + content: '\f299'; +} +.zmdi-gps-off:before { + content: '\f29a'; +} +.zmdi-gps:before { + content: '\f29b'; +} +.zmdi-headset-mic:before { + content: '\f29c'; +} +.zmdi-headset:before { + content: '\f29d'; +} +.zmdi-input-antenna:before { + content: '\f29e'; +} +.zmdi-input-composite:before { + content: '\f29f'; +} +.zmdi-input-hdmi:before { + content: '\f2a0'; +} +.zmdi-input-power:before { + content: '\f2a1'; +} +.zmdi-input-svideo:before { + content: '\f2a2'; +} +.zmdi-keyboard-hide:before { + content: '\f2a3'; +} +.zmdi-keyboard:before { + content: '\f2a4'; +} +.zmdi-laptop-chromebook:before { + content: '\f2a5'; +} +.zmdi-laptop-mac:before { + content: '\f2a6'; +} +.zmdi-laptop:before { + content: '\f2a7'; +} +.zmdi-mic-off:before { + content: '\f2a8'; +} +.zmdi-mic-outline:before { + content: '\f2a9'; +} +.zmdi-mic-setting:before { + content: '\f2aa'; +} +.zmdi-mic:before { + content: '\f2ab'; +} +.zmdi-mouse:before { + content: '\f2ac'; +} +.zmdi-network-alert:before { + content: '\f2ad'; +} +.zmdi-network-locked:before { + content: '\f2ae'; +} +.zmdi-network-off:before { + content: '\f2af'; +} +.zmdi-network-outline:before { + content: '\f2b0'; +} +.zmdi-network-setting:before { + content: '\f2b1'; +} +.zmdi-network:before { + content: '\f2b2'; +} +.zmdi-phone-bluetooth:before { + content: '\f2b3'; +} +.zmdi-phone-end:before { + content: '\f2b4'; +} +.zmdi-phone-forwarded:before { + content: '\f2b5'; +} +.zmdi-phone-in-talk:before { + content: '\f2b6'; +} +.zmdi-phone-locked:before { + content: '\f2b7'; +} +.zmdi-phone-missed:before { + content: '\f2b8'; +} +.zmdi-phone-msg:before { + content: '\f2b9'; +} +.zmdi-phone-paused:before { + content: '\f2ba'; +} +.zmdi-phone-ring:before { + content: '\f2bb'; +} +.zmdi-phone-setting:before { + content: '\f2bc'; +} +.zmdi-phone-sip:before { + content: '\f2bd'; +} +.zmdi-phone:before { + content: '\f2be'; +} +.zmdi-portable-wifi-changes:before { + content: '\f2bf'; +} +.zmdi-portable-wifi-off:before { + content: '\f2c0'; +} +.zmdi-portable-wifi:before { + content: '\f2c1'; +} +.zmdi-radio:before { + content: '\f2c2'; +} +.zmdi-reader:before { + content: '\f2c3'; +} +.zmdi-remote-control-alt:before { + content: '\f2c4'; +} +.zmdi-remote-control:before { + content: '\f2c5'; +} +.zmdi-router:before { + content: '\f2c6'; +} +.zmdi-scanner:before { + content: '\f2c7'; +} +.zmdi-smartphone-android:before { + content: '\f2c8'; +} +.zmdi-smartphone-download:before { + content: '\f2c9'; +} +.zmdi-smartphone-erase:before { + content: '\f2ca'; +} +.zmdi-smartphone-info:before { + content: '\f2cb'; +} +.zmdi-smartphone-iphone:before { + content: '\f2cc'; +} +.zmdi-smartphone-landscape-lock:before { + content: '\f2cd'; +} +.zmdi-smartphone-landscape:before { + content: '\f2ce'; +} +.zmdi-smartphone-lock:before { + content: '\f2cf'; +} +.zmdi-smartphone-portrait-lock:before { + content: '\f2d0'; +} +.zmdi-smartphone-ring:before { + content: '\f2d1'; +} +.zmdi-smartphone-setting:before { + content: '\f2d2'; +} +.zmdi-smartphone-setup:before { + content: '\f2d3'; +} +.zmdi-smartphone:before { + content: '\f2d4'; +} +.zmdi-speaker:before { + content: '\f2d5'; +} +.zmdi-tablet-android:before { + content: '\f2d6'; +} +.zmdi-tablet-mac:before { + content: '\f2d7'; +} +.zmdi-tablet:before { + content: '\f2d8'; +} +.zmdi-tv-alt-play:before { + content: '\f2d9'; +} +.zmdi-tv-list:before { + content: '\f2da'; +} +.zmdi-tv-play:before { + content: '\f2db'; +} +.zmdi-tv:before { + content: '\f2dc'; +} +.zmdi-usb:before { + content: '\f2dd'; +} +.zmdi-videocam-off:before { + content: '\f2de'; +} +.zmdi-videocam-switch:before { + content: '\f2df'; +} +.zmdi-videocam:before { + content: '\f2e0'; +} +.zmdi-watch:before { + content: '\f2e1'; +} +.zmdi-wifi-alt-2:before { + content: '\f2e2'; +} +.zmdi-wifi-alt:before { + content: '\f2e3'; +} +.zmdi-wifi-info:before { + content: '\f2e4'; +} +.zmdi-wifi-lock:before { + content: '\f2e5'; +} +.zmdi-wifi-off:before { + content: '\f2e6'; +} +.zmdi-wifi-outline:before { + content: '\f2e7'; +} +.zmdi-wifi:before { + content: '\f2e8'; +} +.zmdi-arrow-left-bottom:before { + content: '\f2e9'; +} +.zmdi-arrow-left:before { + content: '\f2ea'; +} +.zmdi-arrow-merge:before { + content: '\f2eb'; +} +.zmdi-arrow-missed:before { + content: '\f2ec'; +} +.zmdi-arrow-right-top:before { + content: '\f2ed'; +} +.zmdi-arrow-right:before { + content: '\f2ee'; +} +.zmdi-arrow-split:before { + content: '\f2ef'; +} +.zmdi-arrows:before { + content: '\f2f0'; +} +.zmdi-caret-down-circle:before { + content: '\f2f1'; +} +.zmdi-caret-down:before { + content: '\f2f2'; +} +.zmdi-caret-left-circle:before { + content: '\f2f3'; +} +.zmdi-caret-left:before { + content: '\f2f4'; +} +.zmdi-caret-right-circle:before { + content: '\f2f5'; +} +.zmdi-caret-right:before { + content: '\f2f6'; +} +.zmdi-caret-up-circle:before { + content: '\f2f7'; +} +.zmdi-caret-up:before { + content: '\f2f8'; +} +.zmdi-chevron-down:before { + content: '\f2f9'; +} +.zmdi-chevron-left:before { + content: '\f2fa'; +} +.zmdi-chevron-right:before { + content: '\f2fb'; +} +.zmdi-chevron-up:before { + content: '\f2fc'; +} +.zmdi-forward:before { + content: '\f2fd'; +} +.zmdi-long-arrow-down:before { + content: '\f2fe'; +} +.zmdi-long-arrow-left:before { + content: '\f2ff'; +} +.zmdi-long-arrow-return:before { + content: '\f300'; +} +.zmdi-long-arrow-right:before { + content: '\f301'; +} +.zmdi-long-arrow-tab:before { + content: '\f302'; +} +.zmdi-long-arrow-up:before { + content: '\f303'; +} +.zmdi-rotate-ccw:before { + content: '\f304'; +} +.zmdi-rotate-cw:before { + content: '\f305'; +} +.zmdi-rotate-left:before { + content: '\f306'; +} +.zmdi-rotate-right:before { + content: '\f307'; +} +.zmdi-square-down:before { + content: '\f308'; +} +.zmdi-square-right:before { + content: '\f309'; +} +.zmdi-swap-alt:before { + content: '\f30a'; +} +.zmdi-swap-vertical-circle:before { + content: '\f30b'; +} +.zmdi-swap-vertical:before { + content: '\f30c'; +} +.zmdi-swap:before { + content: '\f30d'; +} +.zmdi-trending-down:before { + content: '\f30e'; +} +.zmdi-trending-flat:before { + content: '\f30f'; +} +.zmdi-trending-up:before { + content: '\f310'; +} +.zmdi-unfold-less:before { + content: '\f311'; +} +.zmdi-unfold-more:before { + content: '\f312'; +} +.zmdi-apps:before { + content: '\f313'; +} +.zmdi-grid-off:before { + content: '\f314'; +} +.zmdi-grid:before { + content: '\f315'; +} +.zmdi-view-agenda:before { + content: '\f316'; +} +.zmdi-view-array:before { + content: '\f317'; +} +.zmdi-view-carousel:before { + content: '\f318'; +} +.zmdi-view-column:before { + content: '\f319'; +} +.zmdi-view-comfy:before { + content: '\f31a'; +} +.zmdi-view-compact:before { + content: '\f31b'; +} +.zmdi-view-dashboard:before { + content: '\f31c'; +} +.zmdi-view-day:before { + content: '\f31d'; +} +.zmdi-view-headline:before { + content: '\f31e'; +} +.zmdi-view-list-alt:before { + content: '\f31f'; +} +.zmdi-view-list:before { + content: '\f320'; +} +.zmdi-view-module:before { + content: '\f321'; +} +.zmdi-view-quilt:before { + content: '\f322'; +} +.zmdi-view-stream:before { + content: '\f323'; +} +.zmdi-view-subtitles:before { + content: '\f324'; +} +.zmdi-view-toc:before { + content: '\f325'; +} +.zmdi-view-web:before { + content: '\f326'; +} +.zmdi-view-week:before { + content: '\f327'; +} +.zmdi-widgets:before { + content: '\f328'; +} +.zmdi-alarm-check:before { + content: '\f329'; +} +.zmdi-alarm-off:before { + content: '\f32a'; +} +.zmdi-alarm-plus:before { + content: '\f32b'; +} +.zmdi-alarm-snooze:before { + content: '\f32c'; +} +.zmdi-alarm:before { + content: '\f32d'; +} +.zmdi-calendar-alt:before { + content: '\f32e'; +} +.zmdi-calendar-check:before { + content: '\f32f'; +} +.zmdi-calendar-close:before { + content: '\f330'; +} +.zmdi-calendar-note:before { + content: '\f331'; +} +.zmdi-calendar:before { + content: '\f332'; +} +.zmdi-time-countdown:before { + content: '\f333'; +} +.zmdi-time-interval:before { + content: '\f334'; +} +.zmdi-time-restore-setting:before { + content: '\f335'; +} +.zmdi-time-restore:before { + content: '\f336'; +} +.zmdi-time:before { + content: '\f337'; +} +.zmdi-timer-off:before { + content: '\f338'; +} +.zmdi-timer:before { + content: '\f339'; +} +.zmdi-android-alt:before { + content: '\f33a'; +} +.zmdi-android:before { + content: '\f33b'; +} +.zmdi-apple:before { + content: '\f33c'; +} +.zmdi-behance:before { + content: '\f33d'; +} +.zmdi-codepen:before { + content: '\f33e'; +} +.zmdi-dribbble:before { + content: '\f33f'; +} +.zmdi-dropbox:before { + content: '\f340'; +} +.zmdi-evernote:before { + content: '\f341'; +} +.zmdi-facebook-box:before { + content: '\f342'; +} +.zmdi-facebook:before { + content: '\f343'; +} +.zmdi-github-box:before { + content: '\f344'; +} +.zmdi-github:before { + content: '\f345'; +} +.zmdi-google-drive:before { + content: '\f346'; +} +.zmdi-google-earth:before { + content: '\f347'; +} +.zmdi-google-glass:before { + content: '\f348'; +} +.zmdi-google-maps:before { + content: '\f349'; +} +.zmdi-google-pages:before { + content: '\f34a'; +} +.zmdi-google-play:before { + content: '\f34b'; +} +.zmdi-google-plus-box:before { + content: '\f34c'; +} +.zmdi-google-plus:before { + content: '\f34d'; +} +.zmdi-google:before { + content: '\f34e'; +} +.zmdi-instagram:before { + content: '\f34f'; +} +.zmdi-language-css3:before { + content: '\f350'; +} +.zmdi-language-html5:before { + content: '\f351'; +} +.zmdi-language-javascript:before { + content: '\f352'; +} +.zmdi-language-python-alt:before { + content: '\f353'; +} +.zmdi-language-python:before { + content: '\f354'; +} +.zmdi-lastfm:before { + content: '\f355'; +} +.zmdi-linkedin-box:before { + content: '\f356'; +} +.zmdi-paypal:before { + content: '\f357'; +} +.zmdi-pinterest-box:before { + content: '\f358'; +} +.zmdi-pocket:before { + content: '\f359'; +} +.zmdi-polymer:before { + content: '\f35a'; +} +.zmdi-share:before { + content: '\f35b'; +} +.zmdi-stackoverflow:before { + content: '\f35c'; +} +.zmdi-steam-square:before { + content: '\f35d'; +} +.zmdi-steam:before { + content: '\f35e'; +} +.zmdi-twitter-box:before { + content: '\f35f'; +} +.zmdi-twitter:before { + content: '\f360'; +} +.zmdi-vk:before { + content: '\f361'; +} +.zmdi-wikipedia:before { + content: '\f362'; +} +.zmdi-windows:before { + content: '\f363'; +} +.zmdi-aspect-ratio-alt:before { + content: '\f364'; +} +.zmdi-aspect-ratio:before { + content: '\f365'; +} +.zmdi-blur-circular:before { + content: '\f366'; +} +.zmdi-blur-linear:before { + content: '\f367'; +} +.zmdi-blur-off:before { + content: '\f368'; +} +.zmdi-blur:before { + content: '\f369'; +} +.zmdi-brightness-2:before { + content: '\f36a'; +} +.zmdi-brightness-3:before { + content: '\f36b'; +} +.zmdi-brightness-4:before { + content: '\f36c'; +} +.zmdi-brightness-5:before { + content: '\f36d'; +} +.zmdi-brightness-6:before { + content: '\f36e'; +} +.zmdi-brightness-7:before { + content: '\f36f'; +} +.zmdi-brightness-auto:before { + content: '\f370'; +} +.zmdi-brightness-setting:before { + content: '\f371'; +} +.zmdi-broken-image:before { + content: '\f372'; +} +.zmdi-center-focus-strong:before { + content: '\f373'; +} +.zmdi-center-focus-weak:before { + content: '\f374'; +} +.zmdi-compare:before { + content: '\f375'; +} +.zmdi-crop-16-9:before { + content: '\f376'; +} +.zmdi-crop-3-2:before { + content: '\f377'; +} +.zmdi-crop-5-4:before { + content: '\f378'; +} +.zmdi-crop-7-5:before { + content: '\f379'; +} +.zmdi-crop-din:before { + content: '\f37a'; +} +.zmdi-crop-free:before { + content: '\f37b'; +} +.zmdi-crop-landscape:before { + content: '\f37c'; +} +.zmdi-crop-portrait:before { + content: '\f37d'; +} +.zmdi-crop-square:before { + content: '\f37e'; +} +.zmdi-exposure-alt:before { + content: '\f37f'; +} +.zmdi-exposure:before { + content: '\f380'; +} +.zmdi-filter-b-and-w:before { + content: '\f381'; +} +.zmdi-filter-center-focus:before { + content: '\f382'; +} +.zmdi-filter-frames:before { + content: '\f383'; +} +.zmdi-filter-tilt-shift:before { + content: '\f384'; +} +.zmdi-gradient:before { + content: '\f385'; +} +.zmdi-grain:before { + content: '\f386'; +} +.zmdi-graphic-eq:before { + content: '\f387'; +} +.zmdi-hdr-off:before { + content: '\f388'; +} +.zmdi-hdr-strong:before { + content: '\f389'; +} +.zmdi-hdr-weak:before { + content: '\f38a'; +} +.zmdi-hdr:before { + content: '\f38b'; +} +.zmdi-iridescent:before { + content: '\f38c'; +} +.zmdi-leak-off:before { + content: '\f38d'; +} +.zmdi-leak:before { + content: '\f38e'; +} +.zmdi-looks:before { + content: '\f38f'; +} +.zmdi-loupe:before { + content: '\f390'; +} +.zmdi-panorama-horizontal:before { + content: '\f391'; +} +.zmdi-panorama-vertical:before { + content: '\f392'; +} +.zmdi-panorama-wide-angle:before { + content: '\f393'; +} +.zmdi-photo-size-select-large:before { + content: '\f394'; +} +.zmdi-photo-size-select-small:before { + content: '\f395'; +} +.zmdi-picture-in-picture:before { + content: '\f396'; +} +.zmdi-slideshow:before { + content: '\f397'; +} +.zmdi-texture:before { + content: '\f398'; +} +.zmdi-tonality:before { + content: '\f399'; +} +.zmdi-vignette:before { + content: '\f39a'; +} +.zmdi-wb-auto:before { + content: '\f39b'; +} +.zmdi-eject-alt:before { + content: '\f39c'; +} +.zmdi-eject:before { + content: '\f39d'; +} +.zmdi-equalizer:before { + content: '\f39e'; +} +.zmdi-fast-forward:before { + content: '\f39f'; +} +.zmdi-fast-rewind:before { + content: '\f3a0'; +} +.zmdi-forward-10:before { + content: '\f3a1'; +} +.zmdi-forward-30:before { + content: '\f3a2'; +} +.zmdi-forward-5:before { + content: '\f3a3'; +} +.zmdi-hearing:before { + content: '\f3a4'; +} +.zmdi-pause-circle-outline:before { + content: '\f3a5'; +} +.zmdi-pause-circle:before { + content: '\f3a6'; +} +.zmdi-pause:before { + content: '\f3a7'; +} +.zmdi-play-circle-outline:before { + content: '\f3a8'; +} +.zmdi-play-circle:before { + content: '\f3a9'; +} +.zmdi-play:before { + content: '\f3aa'; +} +.zmdi-playlist-audio:before { + content: '\f3ab'; +} +.zmdi-playlist-plus:before { + content: '\f3ac'; +} +.zmdi-repeat-one:before { + content: '\f3ad'; +} +.zmdi-repeat:before { + content: '\f3ae'; +} +.zmdi-replay-10:before { + content: '\f3af'; +} +.zmdi-replay-30:before { + content: '\f3b0'; +} +.zmdi-replay-5:before { + content: '\f3b1'; +} +.zmdi-replay:before { + content: '\f3b2'; +} +.zmdi-shuffle:before { + content: '\f3b3'; +} +.zmdi-skip-next:before { + content: '\f3b4'; +} +.zmdi-skip-previous:before { + content: '\f3b5'; +} +.zmdi-stop:before { + content: '\f3b6'; +} +.zmdi-surround-sound:before { + content: '\f3b7'; +} +.zmdi-tune:before { + content: '\f3b8'; +} +.zmdi-volume-down:before { + content: '\f3b9'; +} +.zmdi-volume-mute:before { + content: '\f3ba'; +} +.zmdi-volume-off:before { + content: '\f3bb'; +} +.zmdi-volume-up:before { + content: '\f3bc'; +} +.zmdi-n-1-square:before { + content: '\f3bd'; +} +.zmdi-n-2-square:before { + content: '\f3be'; +} +.zmdi-n-3-square:before { + content: '\f3bf'; +} +.zmdi-n-4-square:before { + content: '\f3c0'; +} +.zmdi-n-5-square:before { + content: '\f3c1'; +} +.zmdi-n-6-square:before { + content: '\f3c2'; +} +.zmdi-neg-1:before { + content: '\f3c3'; +} +.zmdi-neg-2:before { + content: '\f3c4'; +} +.zmdi-plus-1:before { + content: '\f3c5'; +} +.zmdi-plus-2:before { + content: '\f3c6'; +} +.zmdi-sec-10:before { + content: '\f3c7'; +} +.zmdi-sec-3:before { + content: '\f3c8'; +} +.zmdi-zero:before { + content: '\f3c9'; +} +.zmdi-airline-seat-flat-angled:before { + content: '\f3ca'; +} +.zmdi-airline-seat-flat:before { + content: '\f3cb'; +} +.zmdi-airline-seat-individual-suite:before { + content: '\f3cc'; +} +.zmdi-airline-seat-legroom-extra:before { + content: '\f3cd'; +} +.zmdi-airline-seat-legroom-normal:before { + content: '\f3ce'; +} +.zmdi-airline-seat-legroom-reduced:before { + content: '\f3cf'; +} +.zmdi-airline-seat-recline-extra:before { + content: '\f3d0'; +} +.zmdi-airline-seat-recline-normal:before { + content: '\f3d1'; +} +.zmdi-airplay:before { + content: '\f3d2'; +} +.zmdi-closed-caption:before { + content: '\f3d3'; +} +.zmdi-confirmation-number:before { + content: '\f3d4'; +} +.zmdi-developer-board:before { + content: '\f3d5'; +} +.zmdi-disc-full:before { + content: '\f3d6'; +} +.zmdi-explicit:before { + content: '\f3d7'; +} +.zmdi-flight-land:before { + content: '\f3d8'; +} +.zmdi-flight-takeoff:before { + content: '\f3d9'; +} +.zmdi-flip-to-back:before { + content: '\f3da'; +} +.zmdi-flip-to-front:before { + content: '\f3db'; +} +.zmdi-group-work:before { + content: '\f3dc'; +} +.zmdi-hd:before { + content: '\f3dd'; +} +.zmdi-hq:before { + content: '\f3de'; +} +.zmdi-markunread-mailbox:before { + content: '\f3df'; +} +.zmdi-memory:before { + content: '\f3e0'; +} +.zmdi-nfc:before { + content: '\f3e1'; +} +.zmdi-play-for-work:before { + content: '\f3e2'; +} +.zmdi-power-input:before { + content: '\f3e3'; +} +.zmdi-present-to-all:before { + content: '\f3e4'; +} +.zmdi-satellite:before { + content: '\f3e5'; +} +.zmdi-tap-and-play:before { + content: '\f3e6'; +} +.zmdi-vibration:before { + content: '\f3e7'; +} +.zmdi-voicemail:before { + content: '\f3e8'; +} +.zmdi-group:before { + content: '\f3e9'; +} +.zmdi-rss:before { + content: '\f3ea'; +} +.zmdi-shape:before { + content: '\f3eb'; +} +.zmdi-spinner:before { + content: '\f3ec'; +} +.zmdi-ungroup:before { + content: '\f3ed'; +} +.zmdi-500px:before { + content: '\f3ee'; +} +.zmdi-8tracks:before { + content: '\f3ef'; +} +.zmdi-amazon:before { + content: '\f3f0'; +} +.zmdi-blogger:before { + content: '\f3f1'; +} +.zmdi-delicious:before { + content: '\f3f2'; +} +.zmdi-disqus:before { + content: '\f3f3'; +} +.zmdi-flattr:before { + content: '\f3f4'; +} +.zmdi-flickr:before { + content: '\f3f5'; +} +.zmdi-github-alt:before { + content: '\f3f6'; +} +.zmdi-google-old:before { + content: '\f3f7'; +} +.zmdi-linkedin:before { + content: '\f3f8'; +} +.zmdi-odnoklassniki:before { + content: '\f3f9'; +} +.zmdi-outlook:before { + content: '\f3fa'; +} +.zmdi-paypal-alt:before { + content: '\f3fb'; +} +.zmdi-pinterest:before { + content: '\f3fc'; +} +.zmdi-playstation:before { + content: '\f3fd'; +} +.zmdi-reddit:before { + content: '\f3fe'; +} +.zmdi-skype:before { + content: '\f3ff'; +} +.zmdi-slideshare:before { + content: '\f400'; +} +.zmdi-soundcloud:before { + content: '\f401'; +} +.zmdi-tumblr:before { + content: '\f402'; +} +.zmdi-twitch:before { + content: '\f403'; +} +.zmdi-vimeo:before { + content: '\f404'; +} +.zmdi-whatsapp:before { + content: '\f405'; +} +.zmdi-xbox:before { + content: '\f406'; +} +.zmdi-yahoo:before { + content: '\f407'; +} +.zmdi-youtube-play:before { + content: '\f408'; +} +.zmdi-youtube:before { + content: '\f409'; +} +.zmdi-import-export:before { + content: '\f30c'; +} +.zmdi-swap-vertical-:before { + content: '\f30c'; +} +.zmdi-airplanemode-inactive:before { + content: '\f102'; +} +.zmdi-airplanemode-active:before { + content: '\f103'; +} +.zmdi-rate-review:before { + content: '\f103'; +} +.zmdi-comment-sign:before { + content: '\f25a'; +} +.zmdi-network-warning:before { + content: '\f2ad'; +} +.zmdi-shopping-cart-add:before { + content: '\f1ca'; +} +.zmdi-file-add:before { + content: '\f221'; +} +.zmdi-network-wifi-scan:before { + content: '\f2e4'; +} +.zmdi-collection-add:before { + content: '\f14e'; +} +.zmdi-format-playlist-add:before { + content: '\f3ac'; +} +.zmdi-format-queue-music:before { + content: '\f3ab'; +} +.zmdi-plus-box:before { + content: '\f277'; +} +.zmdi-tag-backspace:before { + content: '\f1d9'; +} +.zmdi-alarm-add:before { + content: '\f32b'; +} +.zmdi-battery-charging:before { + content: '\f114'; +} +.zmdi-daydream-setting:before { + content: '\f217'; +} +.zmdi-more-horiz:before { + content: '\f19c'; +} +.zmdi-book-photo:before { + content: '\f11b'; +} +.zmdi-incandescent:before { + content: '\f189'; +} +.zmdi-wb-iridescent:before { + content: '\f38c'; +} +.zmdi-calendar-remove:before { + content: '\f330'; +} +.zmdi-refresh-sync-disabled:before { + content: '\f1b7'; +} +.zmdi-refresh-sync-problem:before { + content: '\f1b6'; +} +.zmdi-crop-original:before { + content: '\f17e'; +} +.zmdi-power-off:before { + content: '\f1af'; +} +.zmdi-power-off-setting:before { + content: '\f1ae'; +} +.zmdi-leak-remove:before { + content: '\f38d'; +} +.zmdi-star-border:before { + content: '\f27c'; +} +.zmdi-brightness-low:before { + content: '\f36d'; +} +.zmdi-brightness-medium:before { + content: '\f36e'; +} +.zmdi-brightness-high:before { + content: '\f36f'; +} +.zmdi-smartphone-portrait:before { + content: '\f2d4'; +} +.zmdi-live-tv:before { + content: '\f2d9'; +} +.zmdi-format-textdirection-l-to-r:before { + content: '\f249'; +} +.zmdi-format-textdirection-r-to-l:before { + content: '\f24a'; +} +.zmdi-arrow-back:before { + content: '\f2ea'; +} +.zmdi-arrow-forward:before { + content: '\f2ee'; +} +.zmdi-arrow-in:before { + content: '\f2e9'; +} +.zmdi-arrow-out:before { + content: '\f2ed'; +} +.zmdi-rotate-90-degrees-ccw:before { + content: '\f304'; +} +.zmdi-adb:before { + content: '\f33a'; +} +.zmdi-network-wifi:before { + content: '\f2e8'; +} +.zmdi-network-wifi-alt:before { + content: '\f2e3'; +} +.zmdi-network-wifi-lock:before { + content: '\f2e5'; +} +.zmdi-network-wifi-off:before { + content: '\f2e6'; +} +.zmdi-network-wifi-outline:before { + content: '\f2e7'; +} +.zmdi-network-wifi-info:before { + content: '\f2e4'; +} +.zmdi-layers-clear:before { + content: '\f18b'; +} +.zmdi-colorize:before { + content: '\f15d'; +} +.zmdi-format-paint:before { + content: '\f1ba'; +} +.zmdi-format-quote:before { + content: '\f1b2'; +} +.zmdi-camera-monochrome-photos:before { + content: '\f285'; +} +.zmdi-sort-by-alpha:before { + content: '\f1cf'; +} +.zmdi-folder-shared:before { + content: '\f225'; +} +.zmdi-folder-special:before { + content: '\f226'; +} +.zmdi-comment-dots:before { + content: '\f260'; +} +.zmdi-reorder:before { + content: '\f31e'; +} +.zmdi-dehaze:before { + content: '\f197'; +} +.zmdi-sort:before { + content: '\f1ce'; +} +.zmdi-pages:before { + content: '\f34a'; +} +.zmdi-stack-overflow:before { + content: '\f35c'; +} +.zmdi-calendar-account:before { + content: '\f204'; +} +.zmdi-paste:before { + content: '\f109'; +} +.zmdi-cut:before { + content: '\f1bc'; +} +.zmdi-save:before { + content: '\f297'; +} +.zmdi-smartphone-code:before { + content: '\f139'; +} +.zmdi-directions-bike:before { + content: '\f117'; +} +.zmdi-directions-boat:before { + content: '\f11a'; +} +.zmdi-directions-bus:before { + content: '\f121'; +} +.zmdi-directions-car:before { + content: '\f125'; +} +.zmdi-directions-railway:before { + content: '\f1b3'; +} +.zmdi-directions-run:before { + content: '\f215'; +} +.zmdi-directions-subway:before { + content: '\f1d5'; +} +.zmdi-directions-walk:before { + content: '\f216'; +} +.zmdi-local-hotel:before { + content: '\f178'; +} +.zmdi-local-activity:before { + content: '\f1df'; +} +.zmdi-local-play:before { + content: '\f1df'; +} +.zmdi-local-airport:before { + content: '\f103'; +} +.zmdi-local-atm:before { + content: '\f198'; +} +.zmdi-local-bar:before { + content: '\f137'; +} +.zmdi-local-cafe:before { + content: '\f13b'; +} +.zmdi-local-car-wash:before { + content: '\f124'; +} +.zmdi-local-convenience-store:before { + content: '\f1d3'; +} +.zmdi-local-dining:before { + content: '\f153'; +} +.zmdi-local-drink:before { + content: '\f157'; +} +.zmdi-local-florist:before { + content: '\f168'; +} +.zmdi-local-gas-station:before { + content: '\f16f'; +} +.zmdi-local-grocery-store:before { + content: '\f1cb'; +} +.zmdi-local-hospital:before { + content: '\f177'; +} +.zmdi-local-laundry-service:before { + content: '\f1e9'; +} +.zmdi-local-library:before { + content: '\f18d'; +} +.zmdi-local-mall:before { + content: '\f195'; +} +.zmdi-local-movies:before { + content: '\f19d'; +} +.zmdi-local-offer:before { + content: '\f187'; +} +.zmdi-local-parking:before { + content: '\f1a5'; +} +.zmdi-local-parking:before { + content: '\f1a5'; +} +.zmdi-local-pharmacy:before { + content: '\f176'; +} +.zmdi-local-phone:before { + content: '\f2be'; +} +.zmdi-local-pizza:before { + content: '\f1ac'; +} +.zmdi-local-post-office:before { + content: '\f15a'; +} +.zmdi-local-printshop:before { + content: '\f1b0'; +} +.zmdi-local-see:before { + content: '\f28c'; +} +.zmdi-local-shipping:before { + content: '\f1e6'; +} +.zmdi-local-store:before { + content: '\f1d4'; +} +.zmdi-local-taxi:before { + content: '\f123'; +} +.zmdi-local-wc:before { + content: '\f211'; +} +.zmdi-my-location:before { + content: '\f299'; +} +.zmdi-directions:before { + content: '\f1e7'; +} diff --git a/public/Auth/fonts/material-icon/css/material-design-iconic-font.min.css b/public/Auth/fonts/material-icon/css/material-design-iconic-font.min.css new file mode 100755 index 0000000..e1a58fe --- /dev/null +++ b/public/Auth/fonts/material-icon/css/material-design-iconic-font.min.css @@ -0,0 +1 @@ +@font-face{font-family:Material-Design-Iconic-Font;src:url(../fonts/Material-Design-Iconic-Font.woff2?v=2.2.0) format('woff2'),url(../fonts/Material-Design-Iconic-Font.woff?v=2.2.0) format('woff'),url(../fonts/Material-Design-Iconic-Font.ttf?v=2.2.0) format('truetype')}.zmdi{display:inline-block;font:normal normal normal 14px/1 'Material-Design-Iconic-Font';font-size:inherit;text-rendering:auto;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.zmdi-hc-lg{font-size:1.33333333em;line-height:.75em;vertical-align:-15%}.zmdi-hc-2x{font-size:2em}.zmdi-hc-3x{font-size:3em}.zmdi-hc-4x{font-size:4em}.zmdi-hc-5x{font-size:5em}.zmdi-hc-fw{width:1.28571429em;text-align:center}.zmdi-hc-ul{padding-left:0;margin-left:2.14285714em;list-style-type:none}.zmdi-hc-ul>li{position:relative}.zmdi-hc-li{position:absolute;left:-2.14285714em;width:2.14285714em;top:.14285714em;text-align:center}.zmdi-hc-li.zmdi-hc-lg{left:-1.85714286em}.zmdi-hc-border{padding:.1em .25em;border:solid .1em #9e9e9e;border-radius:2px}.zmdi-hc-border-circle{padding:.1em .25em;border:solid .1em #9e9e9e;border-radius:50%}.zmdi.pull-left{float:left;margin-right:.15em}.zmdi.pull-right{float:right;margin-left:.15em}.zmdi-hc-spin{-webkit-animation:zmdi-spin 1.5s infinite linear;animation:zmdi-spin 1.5s infinite linear}.zmdi-hc-spin-reverse{-webkit-animation:zmdi-spin-reverse 1.5s infinite linear;animation:zmdi-spin-reverse 1.5s infinite linear}@-webkit-keyframes zmdi-spin{0%{-webkit-transform:rotate(0deg);transform:rotate(0deg)}100%{-webkit-transform:rotate(359deg);transform:rotate(359deg)}}@keyframes zmdi-spin{0%{-webkit-transform:rotate(0deg);transform:rotate(0deg)}100%{-webkit-transform:rotate(359deg);transform:rotate(359deg)}}@-webkit-keyframes zmdi-spin-reverse{0%{-webkit-transform:rotate(0deg);transform:rotate(0deg)}100%{-webkit-transform:rotate(-359deg);transform:rotate(-359deg)}}@keyframes zmdi-spin-reverse{0%{-webkit-transform:rotate(0deg);transform:rotate(0deg)}100%{-webkit-transform:rotate(-359deg);transform:rotate(-359deg)}}.zmdi-hc-rotate-90{-webkit-transform:rotate(90deg);-ms-transform:rotate(90deg);transform:rotate(90deg)}.zmdi-hc-rotate-180{-webkit-transform:rotate(180deg);-ms-transform:rotate(180deg);transform:rotate(180deg)}.zmdi-hc-rotate-270{-webkit-transform:rotate(270deg);-ms-transform:rotate(270deg);transform:rotate(270deg)}.zmdi-hc-flip-horizontal{-webkit-transform:scale(-1,1);-ms-transform:scale(-1,1);transform:scale(-1,1)}.zmdi-hc-flip-vertical{-webkit-transform:scale(1,-1);-ms-transform:scale(1,-1);transform:scale(1,-1)}.zmdi-hc-stack{position:relative;display:inline-block;width:2em;height:2em;line-height:2em;vertical-align:middle}.zmdi-hc-stack-1x,.zmdi-hc-stack-2x{position:absolute;left:0;width:100%;text-align:center}.zmdi-hc-stack-1x{line-height:inherit}.zmdi-hc-stack-2x{font-size:2em}.zmdi-hc-inverse{color:#fff}.zmdi-3d-rotation:before{content:'\f101'}.zmdi-airplane-off:before{content:'\f102'}.zmdi-airplane:before{content:'\f103'}.zmdi-album:before{content:'\f104'}.zmdi-archive:before{content:'\f105'}.zmdi-assignment-account:before{content:'\f106'}.zmdi-assignment-alert:before{content:'\f107'}.zmdi-assignment-check:before{content:'\f108'}.zmdi-assignment-o:before{content:'\f109'}.zmdi-assignment-return:before{content:'\f10a'}.zmdi-assignment-returned:before{content:'\f10b'}.zmdi-assignment:before{content:'\f10c'}.zmdi-attachment-alt:before{content:'\f10d'}.zmdi-attachment:before{content:'\f10e'}.zmdi-audio:before{content:'\f10f'}.zmdi-badge-check:before{content:'\f110'}.zmdi-balance-wallet:before{content:'\f111'}.zmdi-balance:before{content:'\f112'}.zmdi-battery-alert:before{content:'\f113'}.zmdi-battery-flash:before{content:'\f114'}.zmdi-battery-unknown:before{content:'\f115'}.zmdi-battery:before{content:'\f116'}.zmdi-bike:before{content:'\f117'}.zmdi-block-alt:before{content:'\f118'}.zmdi-block:before{content:'\f119'}.zmdi-boat:before{content:'\f11a'}.zmdi-book-image:before{content:'\f11b'}.zmdi-book:before{content:'\f11c'}.zmdi-bookmark-outline:before{content:'\f11d'}.zmdi-bookmark:before{content:'\f11e'}.zmdi-brush:before{content:'\f11f'}.zmdi-bug:before{content:'\f120'}.zmdi-bus:before{content:'\f121'}.zmdi-cake:before{content:'\f122'}.zmdi-car-taxi:before{content:'\f123'}.zmdi-car-wash:before{content:'\f124'}.zmdi-car:before{content:'\f125'}.zmdi-card-giftcard:before{content:'\f126'}.zmdi-card-membership:before{content:'\f127'}.zmdi-card-travel:before{content:'\f128'}.zmdi-card:before{content:'\f129'}.zmdi-case-check:before{content:'\f12a'}.zmdi-case-download:before{content:'\f12b'}.zmdi-case-play:before{content:'\f12c'}.zmdi-case:before{content:'\f12d'}.zmdi-cast-connected:before{content:'\f12e'}.zmdi-cast:before{content:'\f12f'}.zmdi-chart-donut:before{content:'\f130'}.zmdi-chart:before{content:'\f131'}.zmdi-city-alt:before{content:'\f132'}.zmdi-city:before{content:'\f133'}.zmdi-close-circle-o:before{content:'\f134'}.zmdi-close-circle:before{content:'\f135'}.zmdi-close:before{content:'\f136'}.zmdi-cocktail:before{content:'\f137'}.zmdi-code-setting:before{content:'\f138'}.zmdi-code-smartphone:before{content:'\f139'}.zmdi-code:before{content:'\f13a'}.zmdi-coffee:before{content:'\f13b'}.zmdi-collection-bookmark:before{content:'\f13c'}.zmdi-collection-case-play:before{content:'\f13d'}.zmdi-collection-folder-image:before{content:'\f13e'}.zmdi-collection-image-o:before{content:'\f13f'}.zmdi-collection-image:before{content:'\f140'}.zmdi-collection-item-1:before{content:'\f141'}.zmdi-collection-item-2:before{content:'\f142'}.zmdi-collection-item-3:before{content:'\f143'}.zmdi-collection-item-4:before{content:'\f144'}.zmdi-collection-item-5:before{content:'\f145'}.zmdi-collection-item-6:before{content:'\f146'}.zmdi-collection-item-7:before{content:'\f147'}.zmdi-collection-item-8:before{content:'\f148'}.zmdi-collection-item-9-plus:before{content:'\f149'}.zmdi-collection-item-9:before{content:'\f14a'}.zmdi-collection-item:before{content:'\f14b'}.zmdi-collection-music:before{content:'\f14c'}.zmdi-collection-pdf:before{content:'\f14d'}.zmdi-collection-plus:before{content:'\f14e'}.zmdi-collection-speaker:before{content:'\f14f'}.zmdi-collection-text:before{content:'\f150'}.zmdi-collection-video:before{content:'\f151'}.zmdi-compass:before{content:'\f152'}.zmdi-cutlery:before{content:'\f153'}.zmdi-delete:before{content:'\f154'}.zmdi-dialpad:before{content:'\f155'}.zmdi-dns:before{content:'\f156'}.zmdi-drink:before{content:'\f157'}.zmdi-edit:before{content:'\f158'}.zmdi-email-open:before{content:'\f159'}.zmdi-email:before{content:'\f15a'}.zmdi-eye-off:before{content:'\f15b'}.zmdi-eye:before{content:'\f15c'}.zmdi-eyedropper:before{content:'\f15d'}.zmdi-favorite-outline:before{content:'\f15e'}.zmdi-favorite:before{content:'\f15f'}.zmdi-filter-list:before{content:'\f160'}.zmdi-fire:before{content:'\f161'}.zmdi-flag:before{content:'\f162'}.zmdi-flare:before{content:'\f163'}.zmdi-flash-auto:before{content:'\f164'}.zmdi-flash-off:before{content:'\f165'}.zmdi-flash:before{content:'\f166'}.zmdi-flip:before{content:'\f167'}.zmdi-flower-alt:before{content:'\f168'}.zmdi-flower:before{content:'\f169'}.zmdi-font:before{content:'\f16a'}.zmdi-fullscreen-alt:before{content:'\f16b'}.zmdi-fullscreen-exit:before{content:'\f16c'}.zmdi-fullscreen:before{content:'\f16d'}.zmdi-functions:before{content:'\f16e'}.zmdi-gas-station:before{content:'\f16f'}.zmdi-gesture:before{content:'\f170'}.zmdi-globe-alt:before{content:'\f171'}.zmdi-globe-lock:before{content:'\f172'}.zmdi-globe:before{content:'\f173'}.zmdi-graduation-cap:before{content:'\f174'}.zmdi-home:before{content:'\f175'}.zmdi-hospital-alt:before{content:'\f176'}.zmdi-hospital:before{content:'\f177'}.zmdi-hotel:before{content:'\f178'}.zmdi-hourglass-alt:before{content:'\f179'}.zmdi-hourglass-outline:before{content:'\f17a'}.zmdi-hourglass:before{content:'\f17b'}.zmdi-http:before{content:'\f17c'}.zmdi-image-alt:before{content:'\f17d'}.zmdi-image-o:before{content:'\f17e'}.zmdi-image:before{content:'\f17f'}.zmdi-inbox:before{content:'\f180'}.zmdi-invert-colors-off:before{content:'\f181'}.zmdi-invert-colors:before{content:'\f182'}.zmdi-key:before{content:'\f183'}.zmdi-label-alt-outline:before{content:'\f184'}.zmdi-label-alt:before{content:'\f185'}.zmdi-label-heart:before{content:'\f186'}.zmdi-label:before{content:'\f187'}.zmdi-labels:before{content:'\f188'}.zmdi-lamp:before{content:'\f189'}.zmdi-landscape:before{content:'\f18a'}.zmdi-layers-off:before{content:'\f18b'}.zmdi-layers:before{content:'\f18c'}.zmdi-library:before{content:'\f18d'}.zmdi-link:before{content:'\f18e'}.zmdi-lock-open:before{content:'\f18f'}.zmdi-lock-outline:before{content:'\f190'}.zmdi-lock:before{content:'\f191'}.zmdi-mail-reply-all:before{content:'\f192'}.zmdi-mail-reply:before{content:'\f193'}.zmdi-mail-send:before{content:'\f194'}.zmdi-mall:before{content:'\f195'}.zmdi-map:before{content:'\f196'}.zmdi-menu:before{content:'\f197'}.zmdi-money-box:before{content:'\f198'}.zmdi-money-off:before{content:'\f199'}.zmdi-money:before{content:'\f19a'}.zmdi-more-vert:before{content:'\f19b'}.zmdi-more:before{content:'\f19c'}.zmdi-movie-alt:before{content:'\f19d'}.zmdi-movie:before{content:'\f19e'}.zmdi-nature-people:before{content:'\f19f'}.zmdi-nature:before{content:'\f1a0'}.zmdi-navigation:before{content:'\f1a1'}.zmdi-open-in-browser:before{content:'\f1a2'}.zmdi-open-in-new:before{content:'\f1a3'}.zmdi-palette:before{content:'\f1a4'}.zmdi-parking:before{content:'\f1a5'}.zmdi-pin-account:before{content:'\f1a6'}.zmdi-pin-assistant:before{content:'\f1a7'}.zmdi-pin-drop:before{content:'\f1a8'}.zmdi-pin-help:before{content:'\f1a9'}.zmdi-pin-off:before{content:'\f1aa'}.zmdi-pin:before{content:'\f1ab'}.zmdi-pizza:before{content:'\f1ac'}.zmdi-plaster:before{content:'\f1ad'}.zmdi-power-setting:before{content:'\f1ae'}.zmdi-power:before{content:'\f1af'}.zmdi-print:before{content:'\f1b0'}.zmdi-puzzle-piece:before{content:'\f1b1'}.zmdi-quote:before{content:'\f1b2'}.zmdi-railway:before{content:'\f1b3'}.zmdi-receipt:before{content:'\f1b4'}.zmdi-refresh-alt:before{content:'\f1b5'}.zmdi-refresh-sync-alert:before{content:'\f1b6'}.zmdi-refresh-sync-off:before{content:'\f1b7'}.zmdi-refresh-sync:before{content:'\f1b8'}.zmdi-refresh:before{content:'\f1b9'}.zmdi-roller:before{content:'\f1ba'}.zmdi-ruler:before{content:'\f1bb'}.zmdi-scissors:before{content:'\f1bc'}.zmdi-screen-rotation-lock:before{content:'\f1bd'}.zmdi-screen-rotation:before{content:'\f1be'}.zmdi-search-for:before{content:'\f1bf'}.zmdi-search-in-file:before{content:'\f1c0'}.zmdi-search-in-page:before{content:'\f1c1'}.zmdi-search-replace:before{content:'\f1c2'}.zmdi-search:before{content:'\f1c3'}.zmdi-seat:before{content:'\f1c4'}.zmdi-settings-square:before{content:'\f1c5'}.zmdi-settings:before{content:'\f1c6'}.zmdi-shield-check:before{content:'\f1c7'}.zmdi-shield-security:before{content:'\f1c8'}.zmdi-shopping-basket:before{content:'\f1c9'}.zmdi-shopping-cart-plus:before{content:'\f1ca'}.zmdi-shopping-cart:before{content:'\f1cb'}.zmdi-sign-in:before{content:'\f1cc'}.zmdi-sort-amount-asc:before{content:'\f1cd'}.zmdi-sort-amount-desc:before{content:'\f1ce'}.zmdi-sort-asc:before{content:'\f1cf'}.zmdi-sort-desc:before{content:'\f1d0'}.zmdi-spellcheck:before{content:'\f1d1'}.zmdi-storage:before{content:'\f1d2'}.zmdi-store-24:before{content:'\f1d3'}.zmdi-store:before{content:'\f1d4'}.zmdi-subway:before{content:'\f1d5'}.zmdi-sun:before{content:'\f1d6'}.zmdi-tab-unselected:before{content:'\f1d7'}.zmdi-tab:before{content:'\f1d8'}.zmdi-tag-close:before{content:'\f1d9'}.zmdi-tag-more:before{content:'\f1da'}.zmdi-tag:before{content:'\f1db'}.zmdi-thumb-down:before{content:'\f1dc'}.zmdi-thumb-up-down:before{content:'\f1dd'}.zmdi-thumb-up:before{content:'\f1de'}.zmdi-ticket-star:before{content:'\f1df'}.zmdi-toll:before{content:'\f1e0'}.zmdi-toys:before{content:'\f1e1'}.zmdi-traffic:before{content:'\f1e2'}.zmdi-translate:before{content:'\f1e3'}.zmdi-triangle-down:before{content:'\f1e4'}.zmdi-triangle-up:before{content:'\f1e5'}.zmdi-truck:before{content:'\f1e6'}.zmdi-turning-sign:before{content:'\f1e7'}.zmdi-wallpaper:before{content:'\f1e8'}.zmdi-washing-machine:before{content:'\f1e9'}.zmdi-window-maximize:before{content:'\f1ea'}.zmdi-window-minimize:before{content:'\f1eb'}.zmdi-window-restore:before{content:'\f1ec'}.zmdi-wrench:before{content:'\f1ed'}.zmdi-zoom-in:before{content:'\f1ee'}.zmdi-zoom-out:before{content:'\f1ef'}.zmdi-alert-circle-o:before{content:'\f1f0'}.zmdi-alert-circle:before{content:'\f1f1'}.zmdi-alert-octagon:before{content:'\f1f2'}.zmdi-alert-polygon:before{content:'\f1f3'}.zmdi-alert-triangle:before{content:'\f1f4'}.zmdi-help-outline:before{content:'\f1f5'}.zmdi-help:before{content:'\f1f6'}.zmdi-info-outline:before{content:'\f1f7'}.zmdi-info:before{content:'\f1f8'}.zmdi-notifications-active:before{content:'\f1f9'}.zmdi-notifications-add:before{content:'\f1fa'}.zmdi-notifications-none:before{content:'\f1fb'}.zmdi-notifications-off:before{content:'\f1fc'}.zmdi-notifications-paused:before{content:'\f1fd'}.zmdi-notifications:before{content:'\f1fe'}.zmdi-account-add:before{content:'\f1ff'}.zmdi-account-box-mail:before{content:'\f200'}.zmdi-account-box-o:before{content:'\f201'}.zmdi-account-box-phone:before{content:'\f202'}.zmdi-account-box:before{content:'\f203'}.zmdi-account-calendar:before{content:'\f204'}.zmdi-account-circle:before{content:'\f205'}.zmdi-account-o:before{content:'\f206'}.zmdi-account:before{content:'\f207'}.zmdi-accounts-add:before{content:'\f208'}.zmdi-accounts-alt:before{content:'\f209'}.zmdi-accounts-list-alt:before{content:'\f20a'}.zmdi-accounts-list:before{content:'\f20b'}.zmdi-accounts-outline:before{content:'\f20c'}.zmdi-accounts:before{content:'\f20d'}.zmdi-face:before{content:'\f20e'}.zmdi-female:before{content:'\f20f'}.zmdi-male-alt:before{content:'\f210'}.zmdi-male-female:before{content:'\f211'}.zmdi-male:before{content:'\f212'}.zmdi-mood-bad:before{content:'\f213'}.zmdi-mood:before{content:'\f214'}.zmdi-run:before{content:'\f215'}.zmdi-walk:before{content:'\f216'}.zmdi-cloud-box:before{content:'\f217'}.zmdi-cloud-circle:before{content:'\f218'}.zmdi-cloud-done:before{content:'\f219'}.zmdi-cloud-download:before{content:'\f21a'}.zmdi-cloud-off:before{content:'\f21b'}.zmdi-cloud-outline-alt:before{content:'\f21c'}.zmdi-cloud-outline:before{content:'\f21d'}.zmdi-cloud-upload:before{content:'\f21e'}.zmdi-cloud:before{content:'\f21f'}.zmdi-download:before{content:'\f220'}.zmdi-file-plus:before{content:'\f221'}.zmdi-file-text:before{content:'\f222'}.zmdi-file:before{content:'\f223'}.zmdi-folder-outline:before{content:'\f224'}.zmdi-folder-person:before{content:'\f225'}.zmdi-folder-star-alt:before{content:'\f226'}.zmdi-folder-star:before{content:'\f227'}.zmdi-folder:before{content:'\f228'}.zmdi-gif:before{content:'\f229'}.zmdi-upload:before{content:'\f22a'}.zmdi-border-all:before{content:'\f22b'}.zmdi-border-bottom:before{content:'\f22c'}.zmdi-border-clear:before{content:'\f22d'}.zmdi-border-color:before{content:'\f22e'}.zmdi-border-horizontal:before{content:'\f22f'}.zmdi-border-inner:before{content:'\f230'}.zmdi-border-left:before{content:'\f231'}.zmdi-border-outer:before{content:'\f232'}.zmdi-border-right:before{content:'\f233'}.zmdi-border-style:before{content:'\f234'}.zmdi-border-top:before{content:'\f235'}.zmdi-border-vertical:before{content:'\f236'}.zmdi-copy:before{content:'\f237'}.zmdi-crop:before{content:'\f238'}.zmdi-format-align-center:before{content:'\f239'}.zmdi-format-align-justify:before{content:'\f23a'}.zmdi-format-align-left:before{content:'\f23b'}.zmdi-format-align-right:before{content:'\f23c'}.zmdi-format-bold:before{content:'\f23d'}.zmdi-format-clear-all:before{content:'\f23e'}.zmdi-format-clear:before{content:'\f23f'}.zmdi-format-color-fill:before{content:'\f240'}.zmdi-format-color-reset:before{content:'\f241'}.zmdi-format-color-text:before{content:'\f242'}.zmdi-format-indent-decrease:before{content:'\f243'}.zmdi-format-indent-increase:before{content:'\f244'}.zmdi-format-italic:before{content:'\f245'}.zmdi-format-line-spacing:before{content:'\f246'}.zmdi-format-list-bulleted:before{content:'\f247'}.zmdi-format-list-numbered:before{content:'\f248'}.zmdi-format-ltr:before{content:'\f249'}.zmdi-format-rtl:before{content:'\f24a'}.zmdi-format-size:before{content:'\f24b'}.zmdi-format-strikethrough-s:before{content:'\f24c'}.zmdi-format-strikethrough:before{content:'\f24d'}.zmdi-format-subject:before{content:'\f24e'}.zmdi-format-underlined:before{content:'\f24f'}.zmdi-format-valign-bottom:before{content:'\f250'}.zmdi-format-valign-center:before{content:'\f251'}.zmdi-format-valign-top:before{content:'\f252'}.zmdi-redo:before{content:'\f253'}.zmdi-select-all:before{content:'\f254'}.zmdi-space-bar:before{content:'\f255'}.zmdi-text-format:before{content:'\f256'}.zmdi-transform:before{content:'\f257'}.zmdi-undo:before{content:'\f258'}.zmdi-wrap-text:before{content:'\f259'}.zmdi-comment-alert:before{content:'\f25a'}.zmdi-comment-alt-text:before{content:'\f25b'}.zmdi-comment-alt:before{content:'\f25c'}.zmdi-comment-edit:before{content:'\f25d'}.zmdi-comment-image:before{content:'\f25e'}.zmdi-comment-list:before{content:'\f25f'}.zmdi-comment-more:before{content:'\f260'}.zmdi-comment-outline:before{content:'\f261'}.zmdi-comment-text-alt:before{content:'\f262'}.zmdi-comment-text:before{content:'\f263'}.zmdi-comment-video:before{content:'\f264'}.zmdi-comment:before{content:'\f265'}.zmdi-comments:before{content:'\f266'}.zmdi-check-all:before{content:'\f267'}.zmdi-check-circle-u:before{content:'\f268'}.zmdi-check-circle:before{content:'\f269'}.zmdi-check-square:before{content:'\f26a'}.zmdi-check:before{content:'\f26b'}.zmdi-circle-o:before{content:'\f26c'}.zmdi-circle:before{content:'\f26d'}.zmdi-dot-circle-alt:before{content:'\f26e'}.zmdi-dot-circle:before{content:'\f26f'}.zmdi-minus-circle-outline:before{content:'\f270'}.zmdi-minus-circle:before{content:'\f271'}.zmdi-minus-square:before{content:'\f272'}.zmdi-minus:before{content:'\f273'}.zmdi-plus-circle-o-duplicate:before{content:'\f274'}.zmdi-plus-circle-o:before{content:'\f275'}.zmdi-plus-circle:before{content:'\f276'}.zmdi-plus-square:before{content:'\f277'}.zmdi-plus:before{content:'\f278'}.zmdi-square-o:before{content:'\f279'}.zmdi-star-circle:before{content:'\f27a'}.zmdi-star-half:before{content:'\f27b'}.zmdi-star-outline:before{content:'\f27c'}.zmdi-star:before{content:'\f27d'}.zmdi-bluetooth-connected:before{content:'\f27e'}.zmdi-bluetooth-off:before{content:'\f27f'}.zmdi-bluetooth-search:before{content:'\f280'}.zmdi-bluetooth-setting:before{content:'\f281'}.zmdi-bluetooth:before{content:'\f282'}.zmdi-camera-add:before{content:'\f283'}.zmdi-camera-alt:before{content:'\f284'}.zmdi-camera-bw:before{content:'\f285'}.zmdi-camera-front:before{content:'\f286'}.zmdi-camera-mic:before{content:'\f287'}.zmdi-camera-party-mode:before{content:'\f288'}.zmdi-camera-rear:before{content:'\f289'}.zmdi-camera-roll:before{content:'\f28a'}.zmdi-camera-switch:before{content:'\f28b'}.zmdi-camera:before{content:'\f28c'}.zmdi-card-alert:before{content:'\f28d'}.zmdi-card-off:before{content:'\f28e'}.zmdi-card-sd:before{content:'\f28f'}.zmdi-card-sim:before{content:'\f290'}.zmdi-desktop-mac:before{content:'\f291'}.zmdi-desktop-windows:before{content:'\f292'}.zmdi-device-hub:before{content:'\f293'}.zmdi-devices-off:before{content:'\f294'}.zmdi-devices:before{content:'\f295'}.zmdi-dock:before{content:'\f296'}.zmdi-floppy:before{content:'\f297'}.zmdi-gamepad:before{content:'\f298'}.zmdi-gps-dot:before{content:'\f299'}.zmdi-gps-off:before{content:'\f29a'}.zmdi-gps:before{content:'\f29b'}.zmdi-headset-mic:before{content:'\f29c'}.zmdi-headset:before{content:'\f29d'}.zmdi-input-antenna:before{content:'\f29e'}.zmdi-input-composite:before{content:'\f29f'}.zmdi-input-hdmi:before{content:'\f2a0'}.zmdi-input-power:before{content:'\f2a1'}.zmdi-input-svideo:before{content:'\f2a2'}.zmdi-keyboard-hide:before{content:'\f2a3'}.zmdi-keyboard:before{content:'\f2a4'}.zmdi-laptop-chromebook:before{content:'\f2a5'}.zmdi-laptop-mac:before{content:'\f2a6'}.zmdi-laptop:before{content:'\f2a7'}.zmdi-mic-off:before{content:'\f2a8'}.zmdi-mic-outline:before{content:'\f2a9'}.zmdi-mic-setting:before{content:'\f2aa'}.zmdi-mic:before{content:'\f2ab'}.zmdi-mouse:before{content:'\f2ac'}.zmdi-network-alert:before{content:'\f2ad'}.zmdi-network-locked:before{content:'\f2ae'}.zmdi-network-off:before{content:'\f2af'}.zmdi-network-outline:before{content:'\f2b0'}.zmdi-network-setting:before{content:'\f2b1'}.zmdi-network:before{content:'\f2b2'}.zmdi-phone-bluetooth:before{content:'\f2b3'}.zmdi-phone-end:before{content:'\f2b4'}.zmdi-phone-forwarded:before{content:'\f2b5'}.zmdi-phone-in-talk:before{content:'\f2b6'}.zmdi-phone-locked:before{content:'\f2b7'}.zmdi-phone-missed:before{content:'\f2b8'}.zmdi-phone-msg:before{content:'\f2b9'}.zmdi-phone-paused:before{content:'\f2ba'}.zmdi-phone-ring:before{content:'\f2bb'}.zmdi-phone-setting:before{content:'\f2bc'}.zmdi-phone-sip:before{content:'\f2bd'}.zmdi-phone:before{content:'\f2be'}.zmdi-portable-wifi-changes:before{content:'\f2bf'}.zmdi-portable-wifi-off:before{content:'\f2c0'}.zmdi-portable-wifi:before{content:'\f2c1'}.zmdi-radio:before{content:'\f2c2'}.zmdi-reader:before{content:'\f2c3'}.zmdi-remote-control-alt:before{content:'\f2c4'}.zmdi-remote-control:before{content:'\f2c5'}.zmdi-router:before{content:'\f2c6'}.zmdi-scanner:before{content:'\f2c7'}.zmdi-smartphone-android:before{content:'\f2c8'}.zmdi-smartphone-download:before{content:'\f2c9'}.zmdi-smartphone-erase:before{content:'\f2ca'}.zmdi-smartphone-info:before{content:'\f2cb'}.zmdi-smartphone-iphone:before{content:'\f2cc'}.zmdi-smartphone-landscape-lock:before{content:'\f2cd'}.zmdi-smartphone-landscape:before{content:'\f2ce'}.zmdi-smartphone-lock:before{content:'\f2cf'}.zmdi-smartphone-portrait-lock:before{content:'\f2d0'}.zmdi-smartphone-ring:before{content:'\f2d1'}.zmdi-smartphone-setting:before{content:'\f2d2'}.zmdi-smartphone-setup:before{content:'\f2d3'}.zmdi-smartphone:before{content:'\f2d4'}.zmdi-speaker:before{content:'\f2d5'}.zmdi-tablet-android:before{content:'\f2d6'}.zmdi-tablet-mac:before{content:'\f2d7'}.zmdi-tablet:before{content:'\f2d8'}.zmdi-tv-alt-play:before{content:'\f2d9'}.zmdi-tv-list:before{content:'\f2da'}.zmdi-tv-play:before{content:'\f2db'}.zmdi-tv:before{content:'\f2dc'}.zmdi-usb:before{content:'\f2dd'}.zmdi-videocam-off:before{content:'\f2de'}.zmdi-videocam-switch:before{content:'\f2df'}.zmdi-videocam:before{content:'\f2e0'}.zmdi-watch:before{content:'\f2e1'}.zmdi-wifi-alt-2:before{content:'\f2e2'}.zmdi-wifi-alt:before{content:'\f2e3'}.zmdi-wifi-info:before{content:'\f2e4'}.zmdi-wifi-lock:before{content:'\f2e5'}.zmdi-wifi-off:before{content:'\f2e6'}.zmdi-wifi-outline:before{content:'\f2e7'}.zmdi-wifi:before{content:'\f2e8'}.zmdi-arrow-left-bottom:before{content:'\f2e9'}.zmdi-arrow-left:before{content:'\f2ea'}.zmdi-arrow-merge:before{content:'\f2eb'}.zmdi-arrow-missed:before{content:'\f2ec'}.zmdi-arrow-right-top:before{content:'\f2ed'}.zmdi-arrow-right:before{content:'\f2ee'}.zmdi-arrow-split:before{content:'\f2ef'}.zmdi-arrows:before{content:'\f2f0'}.zmdi-caret-down-circle:before{content:'\f2f1'}.zmdi-caret-down:before{content:'\f2f2'}.zmdi-caret-left-circle:before{content:'\f2f3'}.zmdi-caret-left:before{content:'\f2f4'}.zmdi-caret-right-circle:before{content:'\f2f5'}.zmdi-caret-right:before{content:'\f2f6'}.zmdi-caret-up-circle:before{content:'\f2f7'}.zmdi-caret-up:before{content:'\f2f8'}.zmdi-chevron-down:before{content:'\f2f9'}.zmdi-chevron-left:before{content:'\f2fa'}.zmdi-chevron-right:before{content:'\f2fb'}.zmdi-chevron-up:before{content:'\f2fc'}.zmdi-forward:before{content:'\f2fd'}.zmdi-long-arrow-down:before{content:'\f2fe'}.zmdi-long-arrow-left:before{content:'\f2ff'}.zmdi-long-arrow-return:before{content:'\f300'}.zmdi-long-arrow-right:before{content:'\f301'}.zmdi-long-arrow-tab:before{content:'\f302'}.zmdi-long-arrow-up:before{content:'\f303'}.zmdi-rotate-ccw:before{content:'\f304'}.zmdi-rotate-cw:before{content:'\f305'}.zmdi-rotate-left:before{content:'\f306'}.zmdi-rotate-right:before{content:'\f307'}.zmdi-square-down:before{content:'\f308'}.zmdi-square-right:before{content:'\f309'}.zmdi-swap-alt:before{content:'\f30a'}.zmdi-swap-vertical-circle:before{content:'\f30b'}.zmdi-swap-vertical:before{content:'\f30c'}.zmdi-swap:before{content:'\f30d'}.zmdi-trending-down:before{content:'\f30e'}.zmdi-trending-flat:before{content:'\f30f'}.zmdi-trending-up:before{content:'\f310'}.zmdi-unfold-less:before{content:'\f311'}.zmdi-unfold-more:before{content:'\f312'}.zmdi-apps:before{content:'\f313'}.zmdi-grid-off:before{content:'\f314'}.zmdi-grid:before{content:'\f315'}.zmdi-view-agenda:before{content:'\f316'}.zmdi-view-array:before{content:'\f317'}.zmdi-view-carousel:before{content:'\f318'}.zmdi-view-column:before{content:'\f319'}.zmdi-view-comfy:before{content:'\f31a'}.zmdi-view-compact:before{content:'\f31b'}.zmdi-view-dashboard:before{content:'\f31c'}.zmdi-view-day:before{content:'\f31d'}.zmdi-view-headline:before{content:'\f31e'}.zmdi-view-list-alt:before{content:'\f31f'}.zmdi-view-list:before{content:'\f320'}.zmdi-view-module:before{content:'\f321'}.zmdi-view-quilt:before{content:'\f322'}.zmdi-view-stream:before{content:'\f323'}.zmdi-view-subtitles:before{content:'\f324'}.zmdi-view-toc:before{content:'\f325'}.zmdi-view-web:before{content:'\f326'}.zmdi-view-week:before{content:'\f327'}.zmdi-widgets:before{content:'\f328'}.zmdi-alarm-check:before{content:'\f329'}.zmdi-alarm-off:before{content:'\f32a'}.zmdi-alarm-plus:before{content:'\f32b'}.zmdi-alarm-snooze:before{content:'\f32c'}.zmdi-alarm:before{content:'\f32d'}.zmdi-calendar-alt:before{content:'\f32e'}.zmdi-calendar-check:before{content:'\f32f'}.zmdi-calendar-close:before{content:'\f330'}.zmdi-calendar-note:before{content:'\f331'}.zmdi-calendar:before{content:'\f332'}.zmdi-time-countdown:before{content:'\f333'}.zmdi-time-interval:before{content:'\f334'}.zmdi-time-restore-setting:before{content:'\f335'}.zmdi-time-restore:before{content:'\f336'}.zmdi-time:before{content:'\f337'}.zmdi-timer-off:before{content:'\f338'}.zmdi-timer:before{content:'\f339'}.zmdi-android-alt:before{content:'\f33a'}.zmdi-android:before{content:'\f33b'}.zmdi-apple:before{content:'\f33c'}.zmdi-behance:before{content:'\f33d'}.zmdi-codepen:before{content:'\f33e'}.zmdi-dribbble:before{content:'\f33f'}.zmdi-dropbox:before{content:'\f340'}.zmdi-evernote:before{content:'\f341'}.zmdi-facebook-box:before{content:'\f342'}.zmdi-facebook:before{content:'\f343'}.zmdi-github-box:before{content:'\f344'}.zmdi-github:before{content:'\f345'}.zmdi-google-drive:before{content:'\f346'}.zmdi-google-earth:before{content:'\f347'}.zmdi-google-glass:before{content:'\f348'}.zmdi-google-maps:before{content:'\f349'}.zmdi-google-pages:before{content:'\f34a'}.zmdi-google-play:before{content:'\f34b'}.zmdi-google-plus-box:before{content:'\f34c'}.zmdi-google-plus:before{content:'\f34d'}.zmdi-google:before{content:'\f34e'}.zmdi-instagram:before{content:'\f34f'}.zmdi-language-css3:before{content:'\f350'}.zmdi-language-html5:before{content:'\f351'}.zmdi-language-javascript:before{content:'\f352'}.zmdi-language-python-alt:before{content:'\f353'}.zmdi-language-python:before{content:'\f354'}.zmdi-lastfm:before{content:'\f355'}.zmdi-linkedin-box:before{content:'\f356'}.zmdi-paypal:before{content:'\f357'}.zmdi-pinterest-box:before{content:'\f358'}.zmdi-pocket:before{content:'\f359'}.zmdi-polymer:before{content:'\f35a'}.zmdi-share:before{content:'\f35b'}.zmdi-stackoverflow:before{content:'\f35c'}.zmdi-steam-square:before{content:'\f35d'}.zmdi-steam:before{content:'\f35e'}.zmdi-twitter-box:before{content:'\f35f'}.zmdi-twitter:before{content:'\f360'}.zmdi-vk:before{content:'\f361'}.zmdi-wikipedia:before{content:'\f362'}.zmdi-windows:before{content:'\f363'}.zmdi-aspect-ratio-alt:before{content:'\f364'}.zmdi-aspect-ratio:before{content:'\f365'}.zmdi-blur-circular:before{content:'\f366'}.zmdi-blur-linear:before{content:'\f367'}.zmdi-blur-off:before{content:'\f368'}.zmdi-blur:before{content:'\f369'}.zmdi-brightness-2:before{content:'\f36a'}.zmdi-brightness-3:before{content:'\f36b'}.zmdi-brightness-4:before{content:'\f36c'}.zmdi-brightness-5:before{content:'\f36d'}.zmdi-brightness-6:before{content:'\f36e'}.zmdi-brightness-7:before{content:'\f36f'}.zmdi-brightness-auto:before{content:'\f370'}.zmdi-brightness-setting:before{content:'\f371'}.zmdi-broken-image:before{content:'\f372'}.zmdi-center-focus-strong:before{content:'\f373'}.zmdi-center-focus-weak:before{content:'\f374'}.zmdi-compare:before{content:'\f375'}.zmdi-crop-16-9:before{content:'\f376'}.zmdi-crop-3-2:before{content:'\f377'}.zmdi-crop-5-4:before{content:'\f378'}.zmdi-crop-7-5:before{content:'\f379'}.zmdi-crop-din:before{content:'\f37a'}.zmdi-crop-free:before{content:'\f37b'}.zmdi-crop-landscape:before{content:'\f37c'}.zmdi-crop-portrait:before{content:'\f37d'}.zmdi-crop-square:before{content:'\f37e'}.zmdi-exposure-alt:before{content:'\f37f'}.zmdi-exposure:before{content:'\f380'}.zmdi-filter-b-and-w:before{content:'\f381'}.zmdi-filter-center-focus:before{content:'\f382'}.zmdi-filter-frames:before{content:'\f383'}.zmdi-filter-tilt-shift:before{content:'\f384'}.zmdi-gradient:before{content:'\f385'}.zmdi-grain:before{content:'\f386'}.zmdi-graphic-eq:before{content:'\f387'}.zmdi-hdr-off:before{content:'\f388'}.zmdi-hdr-strong:before{content:'\f389'}.zmdi-hdr-weak:before{content:'\f38a'}.zmdi-hdr:before{content:'\f38b'}.zmdi-iridescent:before{content:'\f38c'}.zmdi-leak-off:before{content:'\f38d'}.zmdi-leak:before{content:'\f38e'}.zmdi-looks:before{content:'\f38f'}.zmdi-loupe:before{content:'\f390'}.zmdi-panorama-horizontal:before{content:'\f391'}.zmdi-panorama-vertical:before{content:'\f392'}.zmdi-panorama-wide-angle:before{content:'\f393'}.zmdi-photo-size-select-large:before{content:'\f394'}.zmdi-photo-size-select-small:before{content:'\f395'}.zmdi-picture-in-picture:before{content:'\f396'}.zmdi-slideshow:before{content:'\f397'}.zmdi-texture:before{content:'\f398'}.zmdi-tonality:before{content:'\f399'}.zmdi-vignette:before{content:'\f39a'}.zmdi-wb-auto:before{content:'\f39b'}.zmdi-eject-alt:before{content:'\f39c'}.zmdi-eject:before{content:'\f39d'}.zmdi-equalizer:before{content:'\f39e'}.zmdi-fast-forward:before{content:'\f39f'}.zmdi-fast-rewind:before{content:'\f3a0'}.zmdi-forward-10:before{content:'\f3a1'}.zmdi-forward-30:before{content:'\f3a2'}.zmdi-forward-5:before{content:'\f3a3'}.zmdi-hearing:before{content:'\f3a4'}.zmdi-pause-circle-outline:before{content:'\f3a5'}.zmdi-pause-circle:before{content:'\f3a6'}.zmdi-pause:before{content:'\f3a7'}.zmdi-play-circle-outline:before{content:'\f3a8'}.zmdi-play-circle:before{content:'\f3a9'}.zmdi-play:before{content:'\f3aa'}.zmdi-playlist-audio:before{content:'\f3ab'}.zmdi-playlist-plus:before{content:'\f3ac'}.zmdi-repeat-one:before{content:'\f3ad'}.zmdi-repeat:before{content:'\f3ae'}.zmdi-replay-10:before{content:'\f3af'}.zmdi-replay-30:before{content:'\f3b0'}.zmdi-replay-5:before{content:'\f3b1'}.zmdi-replay:before{content:'\f3b2'}.zmdi-shuffle:before{content:'\f3b3'}.zmdi-skip-next:before{content:'\f3b4'}.zmdi-skip-previous:before{content:'\f3b5'}.zmdi-stop:before{content:'\f3b6'}.zmdi-surround-sound:before{content:'\f3b7'}.zmdi-tune:before{content:'\f3b8'}.zmdi-volume-down:before{content:'\f3b9'}.zmdi-volume-mute:before{content:'\f3ba'}.zmdi-volume-off:before{content:'\f3bb'}.zmdi-volume-up:before{content:'\f3bc'}.zmdi-n-1-square:before{content:'\f3bd'}.zmdi-n-2-square:before{content:'\f3be'}.zmdi-n-3-square:before{content:'\f3bf'}.zmdi-n-4-square:before{content:'\f3c0'}.zmdi-n-5-square:before{content:'\f3c1'}.zmdi-n-6-square:before{content:'\f3c2'}.zmdi-neg-1:before{content:'\f3c3'}.zmdi-neg-2:before{content:'\f3c4'}.zmdi-plus-1:before{content:'\f3c5'}.zmdi-plus-2:before{content:'\f3c6'}.zmdi-sec-10:before{content:'\f3c7'}.zmdi-sec-3:before{content:'\f3c8'}.zmdi-zero:before{content:'\f3c9'}.zmdi-airline-seat-flat-angled:before{content:'\f3ca'}.zmdi-airline-seat-flat:before{content:'\f3cb'}.zmdi-airline-seat-individual-suite:before{content:'\f3cc'}.zmdi-airline-seat-legroom-extra:before{content:'\f3cd'}.zmdi-airline-seat-legroom-normal:before{content:'\f3ce'}.zmdi-airline-seat-legroom-reduced:before{content:'\f3cf'}.zmdi-airline-seat-recline-extra:before{content:'\f3d0'}.zmdi-airline-seat-recline-normal:before{content:'\f3d1'}.zmdi-airplay:before{content:'\f3d2'}.zmdi-closed-caption:before{content:'\f3d3'}.zmdi-confirmation-number:before{content:'\f3d4'}.zmdi-developer-board:before{content:'\f3d5'}.zmdi-disc-full:before{content:'\f3d6'}.zmdi-explicit:before{content:'\f3d7'}.zmdi-flight-land:before{content:'\f3d8'}.zmdi-flight-takeoff:before{content:'\f3d9'}.zmdi-flip-to-back:before{content:'\f3da'}.zmdi-flip-to-front:before{content:'\f3db'}.zmdi-group-work:before{content:'\f3dc'}.zmdi-hd:before{content:'\f3dd'}.zmdi-hq:before{content:'\f3de'}.zmdi-markunread-mailbox:before{content:'\f3df'}.zmdi-memory:before{content:'\f3e0'}.zmdi-nfc:before{content:'\f3e1'}.zmdi-play-for-work:before{content:'\f3e2'}.zmdi-power-input:before{content:'\f3e3'}.zmdi-present-to-all:before{content:'\f3e4'}.zmdi-satellite:before{content:'\f3e5'}.zmdi-tap-and-play:before{content:'\f3e6'}.zmdi-vibration:before{content:'\f3e7'}.zmdi-voicemail:before{content:'\f3e8'}.zmdi-group:before{content:'\f3e9'}.zmdi-rss:before{content:'\f3ea'}.zmdi-shape:before{content:'\f3eb'}.zmdi-spinner:before{content:'\f3ec'}.zmdi-ungroup:before{content:'\f3ed'}.zmdi-500px:before{content:'\f3ee'}.zmdi-8tracks:before{content:'\f3ef'}.zmdi-amazon:before{content:'\f3f0'}.zmdi-blogger:before{content:'\f3f1'}.zmdi-delicious:before{content:'\f3f2'}.zmdi-disqus:before{content:'\f3f3'}.zmdi-flattr:before{content:'\f3f4'}.zmdi-flickr:before{content:'\f3f5'}.zmdi-github-alt:before{content:'\f3f6'}.zmdi-google-old:before{content:'\f3f7'}.zmdi-linkedin:before{content:'\f3f8'}.zmdi-odnoklassniki:before{content:'\f3f9'}.zmdi-outlook:before{content:'\f3fa'}.zmdi-paypal-alt:before{content:'\f3fb'}.zmdi-pinterest:before{content:'\f3fc'}.zmdi-playstation:before{content:'\f3fd'}.zmdi-reddit:before{content:'\f3fe'}.zmdi-skype:before{content:'\f3ff'}.zmdi-slideshare:before{content:'\f400'}.zmdi-soundcloud:before{content:'\f401'}.zmdi-tumblr:before{content:'\f402'}.zmdi-twitch:before{content:'\f403'}.zmdi-vimeo:before{content:'\f404'}.zmdi-whatsapp:before{content:'\f405'}.zmdi-xbox:before{content:'\f406'}.zmdi-yahoo:before{content:'\f407'}.zmdi-youtube-play:before{content:'\f408'}.zmdi-youtube:before{content:'\f409'}.zmdi-3d-rotation:before{content:'\f101'}.zmdi-airplane-off:before{content:'\f102'}.zmdi-airplane:before{content:'\f103'}.zmdi-album:before{content:'\f104'}.zmdi-archive:before{content:'\f105'}.zmdi-assignment-account:before{content:'\f106'}.zmdi-assignment-alert:before{content:'\f107'}.zmdi-assignment-check:before{content:'\f108'}.zmdi-assignment-o:before{content:'\f109'}.zmdi-assignment-return:before{content:'\f10a'}.zmdi-assignment-returned:before{content:'\f10b'}.zmdi-assignment:before{content:'\f10c'}.zmdi-attachment-alt:before{content:'\f10d'}.zmdi-attachment:before{content:'\f10e'}.zmdi-audio:before{content:'\f10f'}.zmdi-badge-check:before{content:'\f110'}.zmdi-balance-wallet:before{content:'\f111'}.zmdi-balance:before{content:'\f112'}.zmdi-battery-alert:before{content:'\f113'}.zmdi-battery-flash:before{content:'\f114'}.zmdi-battery-unknown:before{content:'\f115'}.zmdi-battery:before{content:'\f116'}.zmdi-bike:before{content:'\f117'}.zmdi-block-alt:before{content:'\f118'}.zmdi-block:before{content:'\f119'}.zmdi-boat:before{content:'\f11a'}.zmdi-book-image:before{content:'\f11b'}.zmdi-book:before{content:'\f11c'}.zmdi-bookmark-outline:before{content:'\f11d'}.zmdi-bookmark:before{content:'\f11e'}.zmdi-brush:before{content:'\f11f'}.zmdi-bug:before{content:'\f120'}.zmdi-bus:before{content:'\f121'}.zmdi-cake:before{content:'\f122'}.zmdi-car-taxi:before{content:'\f123'}.zmdi-car-wash:before{content:'\f124'}.zmdi-car:before{content:'\f125'}.zmdi-card-giftcard:before{content:'\f126'}.zmdi-card-membership:before{content:'\f127'}.zmdi-card-travel:before{content:'\f128'}.zmdi-card:before{content:'\f129'}.zmdi-case-check:before{content:'\f12a'}.zmdi-case-download:before{content:'\f12b'}.zmdi-case-play:before{content:'\f12c'}.zmdi-case:before{content:'\f12d'}.zmdi-cast-connected:before{content:'\f12e'}.zmdi-cast:before{content:'\f12f'}.zmdi-chart-donut:before{content:'\f130'}.zmdi-chart:before{content:'\f131'}.zmdi-city-alt:before{content:'\f132'}.zmdi-city:before{content:'\f133'}.zmdi-close-circle-o:before{content:'\f134'}.zmdi-close-circle:before{content:'\f135'}.zmdi-close:before{content:'\f136'}.zmdi-cocktail:before{content:'\f137'}.zmdi-code-setting:before{content:'\f138'}.zmdi-code-smartphone:before{content:'\f139'}.zmdi-code:before{content:'\f13a'}.zmdi-coffee:before{content:'\f13b'}.zmdi-collection-bookmark:before{content:'\f13c'}.zmdi-collection-case-play:before{content:'\f13d'}.zmdi-collection-folder-image:before{content:'\f13e'}.zmdi-collection-image-o:before{content:'\f13f'}.zmdi-collection-image:before{content:'\f140'}.zmdi-collection-item-1:before{content:'\f141'}.zmdi-collection-item-2:before{content:'\f142'}.zmdi-collection-item-3:before{content:'\f143'}.zmdi-collection-item-4:before{content:'\f144'}.zmdi-collection-item-5:before{content:'\f145'}.zmdi-collection-item-6:before{content:'\f146'}.zmdi-collection-item-7:before{content:'\f147'}.zmdi-collection-item-8:before{content:'\f148'}.zmdi-collection-item-9-plus:before{content:'\f149'}.zmdi-collection-item-9:before{content:'\f14a'}.zmdi-collection-item:before{content:'\f14b'}.zmdi-collection-music:before{content:'\f14c'}.zmdi-collection-pdf:before{content:'\f14d'}.zmdi-collection-plus:before{content:'\f14e'}.zmdi-collection-speaker:before{content:'\f14f'}.zmdi-collection-text:before{content:'\f150'}.zmdi-collection-video:before{content:'\f151'}.zmdi-compass:before{content:'\f152'}.zmdi-cutlery:before{content:'\f153'}.zmdi-delete:before{content:'\f154'}.zmdi-dialpad:before{content:'\f155'}.zmdi-dns:before{content:'\f156'}.zmdi-drink:before{content:'\f157'}.zmdi-edit:before{content:'\f158'}.zmdi-email-open:before{content:'\f159'}.zmdi-email:before{content:'\f15a'}.zmdi-eye-off:before{content:'\f15b'}.zmdi-eye:before{content:'\f15c'}.zmdi-eyedropper:before{content:'\f15d'}.zmdi-favorite-outline:before{content:'\f15e'}.zmdi-favorite:before{content:'\f15f'}.zmdi-filter-list:before{content:'\f160'}.zmdi-fire:before{content:'\f161'}.zmdi-flag:before{content:'\f162'}.zmdi-flare:before{content:'\f163'}.zmdi-flash-auto:before{content:'\f164'}.zmdi-flash-off:before{content:'\f165'}.zmdi-flash:before{content:'\f166'}.zmdi-flip:before{content:'\f167'}.zmdi-flower-alt:before{content:'\f168'}.zmdi-flower:before{content:'\f169'}.zmdi-font:before{content:'\f16a'}.zmdi-fullscreen-alt:before{content:'\f16b'}.zmdi-fullscreen-exit:before{content:'\f16c'}.zmdi-fullscreen:before{content:'\f16d'}.zmdi-functions:before{content:'\f16e'}.zmdi-gas-station:before{content:'\f16f'}.zmdi-gesture:before{content:'\f170'}.zmdi-globe-alt:before{content:'\f171'}.zmdi-globe-lock:before{content:'\f172'}.zmdi-globe:before{content:'\f173'}.zmdi-graduation-cap:before{content:'\f174'}.zmdi-home:before{content:'\f175'}.zmdi-hospital-alt:before{content:'\f176'}.zmdi-hospital:before{content:'\f177'}.zmdi-hotel:before{content:'\f178'}.zmdi-hourglass-alt:before{content:'\f179'}.zmdi-hourglass-outline:before{content:'\f17a'}.zmdi-hourglass:before{content:'\f17b'}.zmdi-http:before{content:'\f17c'}.zmdi-image-alt:before{content:'\f17d'}.zmdi-image-o:before{content:'\f17e'}.zmdi-image:before{content:'\f17f'}.zmdi-inbox:before{content:'\f180'}.zmdi-invert-colors-off:before{content:'\f181'}.zmdi-invert-colors:before{content:'\f182'}.zmdi-key:before{content:'\f183'}.zmdi-label-alt-outline:before{content:'\f184'}.zmdi-label-alt:before{content:'\f185'}.zmdi-label-heart:before{content:'\f186'}.zmdi-label:before{content:'\f187'}.zmdi-labels:before{content:'\f188'}.zmdi-lamp:before{content:'\f189'}.zmdi-landscape:before{content:'\f18a'}.zmdi-layers-off:before{content:'\f18b'}.zmdi-layers:before{content:'\f18c'}.zmdi-library:before{content:'\f18d'}.zmdi-link:before{content:'\f18e'}.zmdi-lock-open:before{content:'\f18f'}.zmdi-lock-outline:before{content:'\f190'}.zmdi-lock:before{content:'\f191'}.zmdi-mail-reply-all:before{content:'\f192'}.zmdi-mail-reply:before{content:'\f193'}.zmdi-mail-send:before{content:'\f194'}.zmdi-mall:before{content:'\f195'}.zmdi-map:before{content:'\f196'}.zmdi-menu:before{content:'\f197'}.zmdi-money-box:before{content:'\f198'}.zmdi-money-off:before{content:'\f199'}.zmdi-money:before{content:'\f19a'}.zmdi-more-vert:before{content:'\f19b'}.zmdi-more:before{content:'\f19c'}.zmdi-movie-alt:before{content:'\f19d'}.zmdi-movie:before{content:'\f19e'}.zmdi-nature-people:before{content:'\f19f'}.zmdi-nature:before{content:'\f1a0'}.zmdi-navigation:before{content:'\f1a1'}.zmdi-open-in-browser:before{content:'\f1a2'}.zmdi-open-in-new:before{content:'\f1a3'}.zmdi-palette:before{content:'\f1a4'}.zmdi-parking:before{content:'\f1a5'}.zmdi-pin-account:before{content:'\f1a6'}.zmdi-pin-assistant:before{content:'\f1a7'}.zmdi-pin-drop:before{content:'\f1a8'}.zmdi-pin-help:before{content:'\f1a9'}.zmdi-pin-off:before{content:'\f1aa'}.zmdi-pin:before{content:'\f1ab'}.zmdi-pizza:before{content:'\f1ac'}.zmdi-plaster:before{content:'\f1ad'}.zmdi-power-setting:before{content:'\f1ae'}.zmdi-power:before{content:'\f1af'}.zmdi-print:before{content:'\f1b0'}.zmdi-puzzle-piece:before{content:'\f1b1'}.zmdi-quote:before{content:'\f1b2'}.zmdi-railway:before{content:'\f1b3'}.zmdi-receipt:before{content:'\f1b4'}.zmdi-refresh-alt:before{content:'\f1b5'}.zmdi-refresh-sync-alert:before{content:'\f1b6'}.zmdi-refresh-sync-off:before{content:'\f1b7'}.zmdi-refresh-sync:before{content:'\f1b8'}.zmdi-refresh:before{content:'\f1b9'}.zmdi-roller:before{content:'\f1ba'}.zmdi-ruler:before{content:'\f1bb'}.zmdi-scissors:before{content:'\f1bc'}.zmdi-screen-rotation-lock:before{content:'\f1bd'}.zmdi-screen-rotation:before{content:'\f1be'}.zmdi-search-for:before{content:'\f1bf'}.zmdi-search-in-file:before{content:'\f1c0'}.zmdi-search-in-page:before{content:'\f1c1'}.zmdi-search-replace:before{content:'\f1c2'}.zmdi-search:before{content:'\f1c3'}.zmdi-seat:before{content:'\f1c4'}.zmdi-settings-square:before{content:'\f1c5'}.zmdi-settings:before{content:'\f1c6'}.zmdi-shield-check:before{content:'\f1c7'}.zmdi-shield-security:before{content:'\f1c8'}.zmdi-shopping-basket:before{content:'\f1c9'}.zmdi-shopping-cart-plus:before{content:'\f1ca'}.zmdi-shopping-cart:before{content:'\f1cb'}.zmdi-sign-in:before{content:'\f1cc'}.zmdi-sort-amount-asc:before{content:'\f1cd'}.zmdi-sort-amount-desc:before{content:'\f1ce'}.zmdi-sort-asc:before{content:'\f1cf'}.zmdi-sort-desc:before{content:'\f1d0'}.zmdi-spellcheck:before{content:'\f1d1'}.zmdi-storage:before{content:'\f1d2'}.zmdi-store-24:before{content:'\f1d3'}.zmdi-store:before{content:'\f1d4'}.zmdi-subway:before{content:'\f1d5'}.zmdi-sun:before{content:'\f1d6'}.zmdi-tab-unselected:before{content:'\f1d7'}.zmdi-tab:before{content:'\f1d8'}.zmdi-tag-close:before{content:'\f1d9'}.zmdi-tag-more:before{content:'\f1da'}.zmdi-tag:before{content:'\f1db'}.zmdi-thumb-down:before{content:'\f1dc'}.zmdi-thumb-up-down:before{content:'\f1dd'}.zmdi-thumb-up:before{content:'\f1de'}.zmdi-ticket-star:before{content:'\f1df'}.zmdi-toll:before{content:'\f1e0'}.zmdi-toys:before{content:'\f1e1'}.zmdi-traffic:before{content:'\f1e2'}.zmdi-translate:before{content:'\f1e3'}.zmdi-triangle-down:before{content:'\f1e4'}.zmdi-triangle-up:before{content:'\f1e5'}.zmdi-truck:before{content:'\f1e6'}.zmdi-turning-sign:before{content:'\f1e7'}.zmdi-wallpaper:before{content:'\f1e8'}.zmdi-washing-machine:before{content:'\f1e9'}.zmdi-window-maximize:before{content:'\f1ea'}.zmdi-window-minimize:before{content:'\f1eb'}.zmdi-window-restore:before{content:'\f1ec'}.zmdi-wrench:before{content:'\f1ed'}.zmdi-zoom-in:before{content:'\f1ee'}.zmdi-zoom-out:before{content:'\f1ef'}.zmdi-alert-circle-o:before{content:'\f1f0'}.zmdi-alert-circle:before{content:'\f1f1'}.zmdi-alert-octagon:before{content:'\f1f2'}.zmdi-alert-polygon:before{content:'\f1f3'}.zmdi-alert-triangle:before{content:'\f1f4'}.zmdi-help-outline:before{content:'\f1f5'}.zmdi-help:before{content:'\f1f6'}.zmdi-info-outline:before{content:'\f1f7'}.zmdi-info:before{content:'\f1f8'}.zmdi-notifications-active:before{content:'\f1f9'}.zmdi-notifications-add:before{content:'\f1fa'}.zmdi-notifications-none:before{content:'\f1fb'}.zmdi-notifications-off:before{content:'\f1fc'}.zmdi-notifications-paused:before{content:'\f1fd'}.zmdi-notifications:before{content:'\f1fe'}.zmdi-account-add:before{content:'\f1ff'}.zmdi-account-box-mail:before{content:'\f200'}.zmdi-account-box-o:before{content:'\f201'}.zmdi-account-box-phone:before{content:'\f202'}.zmdi-account-box:before{content:'\f203'}.zmdi-account-calendar:before{content:'\f204'}.zmdi-account-circle:before{content:'\f205'}.zmdi-account-o:before{content:'\f206'}.zmdi-account:before{content:'\f207'}.zmdi-accounts-add:before{content:'\f208'}.zmdi-accounts-alt:before{content:'\f209'}.zmdi-accounts-list-alt:before{content:'\f20a'}.zmdi-accounts-list:before{content:'\f20b'}.zmdi-accounts-outline:before{content:'\f20c'}.zmdi-accounts:before{content:'\f20d'}.zmdi-face:before{content:'\f20e'}.zmdi-female:before{content:'\f20f'}.zmdi-male-alt:before{content:'\f210'}.zmdi-male-female:before{content:'\f211'}.zmdi-male:before{content:'\f212'}.zmdi-mood-bad:before{content:'\f213'}.zmdi-mood:before{content:'\f214'}.zmdi-run:before{content:'\f215'}.zmdi-walk:before{content:'\f216'}.zmdi-cloud-box:before{content:'\f217'}.zmdi-cloud-circle:before{content:'\f218'}.zmdi-cloud-done:before{content:'\f219'}.zmdi-cloud-download:before{content:'\f21a'}.zmdi-cloud-off:before{content:'\f21b'}.zmdi-cloud-outline-alt:before{content:'\f21c'}.zmdi-cloud-outline:before{content:'\f21d'}.zmdi-cloud-upload:before{content:'\f21e'}.zmdi-cloud:before{content:'\f21f'}.zmdi-download:before{content:'\f220'}.zmdi-file-plus:before{content:'\f221'}.zmdi-file-text:before{content:'\f222'}.zmdi-file:before{content:'\f223'}.zmdi-folder-outline:before{content:'\f224'}.zmdi-folder-person:before{content:'\f225'}.zmdi-folder-star-alt:before{content:'\f226'}.zmdi-folder-star:before{content:'\f227'}.zmdi-folder:before{content:'\f228'}.zmdi-gif:before{content:'\f229'}.zmdi-upload:before{content:'\f22a'}.zmdi-border-all:before{content:'\f22b'}.zmdi-border-bottom:before{content:'\f22c'}.zmdi-border-clear:before{content:'\f22d'}.zmdi-border-color:before{content:'\f22e'}.zmdi-border-horizontal:before{content:'\f22f'}.zmdi-border-inner:before{content:'\f230'}.zmdi-border-left:before{content:'\f231'}.zmdi-border-outer:before{content:'\f232'}.zmdi-border-right:before{content:'\f233'}.zmdi-border-style:before{content:'\f234'}.zmdi-border-top:before{content:'\f235'}.zmdi-border-vertical:before{content:'\f236'}.zmdi-copy:before{content:'\f237'}.zmdi-crop:before{content:'\f238'}.zmdi-format-align-center:before{content:'\f239'}.zmdi-format-align-justify:before{content:'\f23a'}.zmdi-format-align-left:before{content:'\f23b'}.zmdi-format-align-right:before{content:'\f23c'}.zmdi-format-bold:before{content:'\f23d'}.zmdi-format-clear-all:before{content:'\f23e'}.zmdi-format-clear:before{content:'\f23f'}.zmdi-format-color-fill:before{content:'\f240'}.zmdi-format-color-reset:before{content:'\f241'}.zmdi-format-color-text:before{content:'\f242'}.zmdi-format-indent-decrease:before{content:'\f243'}.zmdi-format-indent-increase:before{content:'\f244'}.zmdi-format-italic:before{content:'\f245'}.zmdi-format-line-spacing:before{content:'\f246'}.zmdi-format-list-bulleted:before{content:'\f247'}.zmdi-format-list-numbered:before{content:'\f248'}.zmdi-format-ltr:before{content:'\f249'}.zmdi-format-rtl:before{content:'\f24a'}.zmdi-format-size:before{content:'\f24b'}.zmdi-format-strikethrough-s:before{content:'\f24c'}.zmdi-format-strikethrough:before{content:'\f24d'}.zmdi-format-subject:before{content:'\f24e'}.zmdi-format-underlined:before{content:'\f24f'}.zmdi-format-valign-bottom:before{content:'\f250'}.zmdi-format-valign-center:before{content:'\f251'}.zmdi-format-valign-top:before{content:'\f252'}.zmdi-redo:before{content:'\f253'}.zmdi-select-all:before{content:'\f254'}.zmdi-space-bar:before{content:'\f255'}.zmdi-text-format:before{content:'\f256'}.zmdi-transform:before{content:'\f257'}.zmdi-undo:before{content:'\f258'}.zmdi-wrap-text:before{content:'\f259'}.zmdi-comment-alert:before{content:'\f25a'}.zmdi-comment-alt-text:before{content:'\f25b'}.zmdi-comment-alt:before{content:'\f25c'}.zmdi-comment-edit:before{content:'\f25d'}.zmdi-comment-image:before{content:'\f25e'}.zmdi-comment-list:before{content:'\f25f'}.zmdi-comment-more:before{content:'\f260'}.zmdi-comment-outline:before{content:'\f261'}.zmdi-comment-text-alt:before{content:'\f262'}.zmdi-comment-text:before{content:'\f263'}.zmdi-comment-video:before{content:'\f264'}.zmdi-comment:before{content:'\f265'}.zmdi-comments:before{content:'\f266'}.zmdi-check-all:before{content:'\f267'}.zmdi-check-circle-u:before{content:'\f268'}.zmdi-check-circle:before{content:'\f269'}.zmdi-check-square:before{content:'\f26a'}.zmdi-check:before{content:'\f26b'}.zmdi-circle-o:before{content:'\f26c'}.zmdi-circle:before{content:'\f26d'}.zmdi-dot-circle-alt:before{content:'\f26e'}.zmdi-dot-circle:before{content:'\f26f'}.zmdi-minus-circle-outline:before{content:'\f270'}.zmdi-minus-circle:before{content:'\f271'}.zmdi-minus-square:before{content:'\f272'}.zmdi-minus:before{content:'\f273'}.zmdi-plus-circle-o-duplicate:before{content:'\f274'}.zmdi-plus-circle-o:before{content:'\f275'}.zmdi-plus-circle:before{content:'\f276'}.zmdi-plus-square:before{content:'\f277'}.zmdi-plus:before{content:'\f278'}.zmdi-square-o:before{content:'\f279'}.zmdi-star-circle:before{content:'\f27a'}.zmdi-star-half:before{content:'\f27b'}.zmdi-star-outline:before{content:'\f27c'}.zmdi-star:before{content:'\f27d'}.zmdi-bluetooth-connected:before{content:'\f27e'}.zmdi-bluetooth-off:before{content:'\f27f'}.zmdi-bluetooth-search:before{content:'\f280'}.zmdi-bluetooth-setting:before{content:'\f281'}.zmdi-bluetooth:before{content:'\f282'}.zmdi-camera-add:before{content:'\f283'}.zmdi-camera-alt:before{content:'\f284'}.zmdi-camera-bw:before{content:'\f285'}.zmdi-camera-front:before{content:'\f286'}.zmdi-camera-mic:before{content:'\f287'}.zmdi-camera-party-mode:before{content:'\f288'}.zmdi-camera-rear:before{content:'\f289'}.zmdi-camera-roll:before{content:'\f28a'}.zmdi-camera-switch:before{content:'\f28b'}.zmdi-camera:before{content:'\f28c'}.zmdi-card-alert:before{content:'\f28d'}.zmdi-card-off:before{content:'\f28e'}.zmdi-card-sd:before{content:'\f28f'}.zmdi-card-sim:before{content:'\f290'}.zmdi-desktop-mac:before{content:'\f291'}.zmdi-desktop-windows:before{content:'\f292'}.zmdi-device-hub:before{content:'\f293'}.zmdi-devices-off:before{content:'\f294'}.zmdi-devices:before{content:'\f295'}.zmdi-dock:before{content:'\f296'}.zmdi-floppy:before{content:'\f297'}.zmdi-gamepad:before{content:'\f298'}.zmdi-gps-dot:before{content:'\f299'}.zmdi-gps-off:before{content:'\f29a'}.zmdi-gps:before{content:'\f29b'}.zmdi-headset-mic:before{content:'\f29c'}.zmdi-headset:before{content:'\f29d'}.zmdi-input-antenna:before{content:'\f29e'}.zmdi-input-composite:before{content:'\f29f'}.zmdi-input-hdmi:before{content:'\f2a0'}.zmdi-input-power:before{content:'\f2a1'}.zmdi-input-svideo:before{content:'\f2a2'}.zmdi-keyboard-hide:before{content:'\f2a3'}.zmdi-keyboard:before{content:'\f2a4'}.zmdi-laptop-chromebook:before{content:'\f2a5'}.zmdi-laptop-mac:before{content:'\f2a6'}.zmdi-laptop:before{content:'\f2a7'}.zmdi-mic-off:before{content:'\f2a8'}.zmdi-mic-outline:before{content:'\f2a9'}.zmdi-mic-setting:before{content:'\f2aa'}.zmdi-mic:before{content:'\f2ab'}.zmdi-mouse:before{content:'\f2ac'}.zmdi-network-alert:before{content:'\f2ad'}.zmdi-network-locked:before{content:'\f2ae'}.zmdi-network-off:before{content:'\f2af'}.zmdi-network-outline:before{content:'\f2b0'}.zmdi-network-setting:before{content:'\f2b1'}.zmdi-network:before{content:'\f2b2'}.zmdi-phone-bluetooth:before{content:'\f2b3'}.zmdi-phone-end:before{content:'\f2b4'}.zmdi-phone-forwarded:before{content:'\f2b5'}.zmdi-phone-in-talk:before{content:'\f2b6'}.zmdi-phone-locked:before{content:'\f2b7'}.zmdi-phone-missed:before{content:'\f2b8'}.zmdi-phone-msg:before{content:'\f2b9'}.zmdi-phone-paused:before{content:'\f2ba'}.zmdi-phone-ring:before{content:'\f2bb'}.zmdi-phone-setting:before{content:'\f2bc'}.zmdi-phone-sip:before{content:'\f2bd'}.zmdi-phone:before{content:'\f2be'}.zmdi-portable-wifi-changes:before{content:'\f2bf'}.zmdi-portable-wifi-off:before{content:'\f2c0'}.zmdi-portable-wifi:before{content:'\f2c1'}.zmdi-radio:before{content:'\f2c2'}.zmdi-reader:before{content:'\f2c3'}.zmdi-remote-control-alt:before{content:'\f2c4'}.zmdi-remote-control:before{content:'\f2c5'}.zmdi-router:before{content:'\f2c6'}.zmdi-scanner:before{content:'\f2c7'}.zmdi-smartphone-android:before{content:'\f2c8'}.zmdi-smartphone-download:before{content:'\f2c9'}.zmdi-smartphone-erase:before{content:'\f2ca'}.zmdi-smartphone-info:before{content:'\f2cb'}.zmdi-smartphone-iphone:before{content:'\f2cc'}.zmdi-smartphone-landscape-lock:before{content:'\f2cd'}.zmdi-smartphone-landscape:before{content:'\f2ce'}.zmdi-smartphone-lock:before{content:'\f2cf'}.zmdi-smartphone-portrait-lock:before{content:'\f2d0'}.zmdi-smartphone-ring:before{content:'\f2d1'}.zmdi-smartphone-setting:before{content:'\f2d2'}.zmdi-smartphone-setup:before{content:'\f2d3'}.zmdi-smartphone:before{content:'\f2d4'}.zmdi-speaker:before{content:'\f2d5'}.zmdi-tablet-android:before{content:'\f2d6'}.zmdi-tablet-mac:before{content:'\f2d7'}.zmdi-tablet:before{content:'\f2d8'}.zmdi-tv-alt-play:before{content:'\f2d9'}.zmdi-tv-list:before{content:'\f2da'}.zmdi-tv-play:before{content:'\f2db'}.zmdi-tv:before{content:'\f2dc'}.zmdi-usb:before{content:'\f2dd'}.zmdi-videocam-off:before{content:'\f2de'}.zmdi-videocam-switch:before{content:'\f2df'}.zmdi-videocam:before{content:'\f2e0'}.zmdi-watch:before{content:'\f2e1'}.zmdi-wifi-alt-2:before{content:'\f2e2'}.zmdi-wifi-alt:before{content:'\f2e3'}.zmdi-wifi-info:before{content:'\f2e4'}.zmdi-wifi-lock:before{content:'\f2e5'}.zmdi-wifi-off:before{content:'\f2e6'}.zmdi-wifi-outline:before{content:'\f2e7'}.zmdi-wifi:before{content:'\f2e8'}.zmdi-arrow-left-bottom:before{content:'\f2e9'}.zmdi-arrow-left:before{content:'\f2ea'}.zmdi-arrow-merge:before{content:'\f2eb'}.zmdi-arrow-missed:before{content:'\f2ec'}.zmdi-arrow-right-top:before{content:'\f2ed'}.zmdi-arrow-right:before{content:'\f2ee'}.zmdi-arrow-split:before{content:'\f2ef'}.zmdi-arrows:before{content:'\f2f0'}.zmdi-caret-down-circle:before{content:'\f2f1'}.zmdi-caret-down:before{content:'\f2f2'}.zmdi-caret-left-circle:before{content:'\f2f3'}.zmdi-caret-left:before{content:'\f2f4'}.zmdi-caret-right-circle:before{content:'\f2f5'}.zmdi-caret-right:before{content:'\f2f6'}.zmdi-caret-up-circle:before{content:'\f2f7'}.zmdi-caret-up:before{content:'\f2f8'}.zmdi-chevron-down:before{content:'\f2f9'}.zmdi-chevron-left:before{content:'\f2fa'}.zmdi-chevron-right:before{content:'\f2fb'}.zmdi-chevron-up:before{content:'\f2fc'}.zmdi-forward:before{content:'\f2fd'}.zmdi-long-arrow-down:before{content:'\f2fe'}.zmdi-long-arrow-left:before{content:'\f2ff'}.zmdi-long-arrow-return:before{content:'\f300'}.zmdi-long-arrow-right:before{content:'\f301'}.zmdi-long-arrow-tab:before{content:'\f302'}.zmdi-long-arrow-up:before{content:'\f303'}.zmdi-rotate-ccw:before{content:'\f304'}.zmdi-rotate-cw:before{content:'\f305'}.zmdi-rotate-left:before{content:'\f306'}.zmdi-rotate-right:before{content:'\f307'}.zmdi-square-down:before{content:'\f308'}.zmdi-square-right:before{content:'\f309'}.zmdi-swap-alt:before{content:'\f30a'}.zmdi-swap-vertical-circle:before{content:'\f30b'}.zmdi-swap-vertical:before{content:'\f30c'}.zmdi-swap:before{content:'\f30d'}.zmdi-trending-down:before{content:'\f30e'}.zmdi-trending-flat:before{content:'\f30f'}.zmdi-trending-up:before{content:'\f310'}.zmdi-unfold-less:before{content:'\f311'}.zmdi-unfold-more:before{content:'\f312'}.zmdi-apps:before{content:'\f313'}.zmdi-grid-off:before{content:'\f314'}.zmdi-grid:before{content:'\f315'}.zmdi-view-agenda:before{content:'\f316'}.zmdi-view-array:before{content:'\f317'}.zmdi-view-carousel:before{content:'\f318'}.zmdi-view-column:before{content:'\f319'}.zmdi-view-comfy:before{content:'\f31a'}.zmdi-view-compact:before{content:'\f31b'}.zmdi-view-dashboard:before{content:'\f31c'}.zmdi-view-day:before{content:'\f31d'}.zmdi-view-headline:before{content:'\f31e'}.zmdi-view-list-alt:before{content:'\f31f'}.zmdi-view-list:before{content:'\f320'}.zmdi-view-module:before{content:'\f321'}.zmdi-view-quilt:before{content:'\f322'}.zmdi-view-stream:before{content:'\f323'}.zmdi-view-subtitles:before{content:'\f324'}.zmdi-view-toc:before{content:'\f325'}.zmdi-view-web:before{content:'\f326'}.zmdi-view-week:before{content:'\f327'}.zmdi-widgets:before{content:'\f328'}.zmdi-alarm-check:before{content:'\f329'}.zmdi-alarm-off:before{content:'\f32a'}.zmdi-alarm-plus:before{content:'\f32b'}.zmdi-alarm-snooze:before{content:'\f32c'}.zmdi-alarm:before{content:'\f32d'}.zmdi-calendar-alt:before{content:'\f32e'}.zmdi-calendar-check:before{content:'\f32f'}.zmdi-calendar-close:before{content:'\f330'}.zmdi-calendar-note:before{content:'\f331'}.zmdi-calendar:before{content:'\f332'}.zmdi-time-countdown:before{content:'\f333'}.zmdi-time-interval:before{content:'\f334'}.zmdi-time-restore-setting:before{content:'\f335'}.zmdi-time-restore:before{content:'\f336'}.zmdi-time:before{content:'\f337'}.zmdi-timer-off:before{content:'\f338'}.zmdi-timer:before{content:'\f339'}.zmdi-android-alt:before{content:'\f33a'}.zmdi-android:before{content:'\f33b'}.zmdi-apple:before{content:'\f33c'}.zmdi-behance:before{content:'\f33d'}.zmdi-codepen:before{content:'\f33e'}.zmdi-dribbble:before{content:'\f33f'}.zmdi-dropbox:before{content:'\f340'}.zmdi-evernote:before{content:'\f341'}.zmdi-facebook-box:before{content:'\f342'}.zmdi-facebook:before{content:'\f343'}.zmdi-github-box:before{content:'\f344'}.zmdi-github:before{content:'\f345'}.zmdi-google-drive:before{content:'\f346'}.zmdi-google-earth:before{content:'\f347'}.zmdi-google-glass:before{content:'\f348'}.zmdi-google-maps:before{content:'\f349'}.zmdi-google-pages:before{content:'\f34a'}.zmdi-google-play:before{content:'\f34b'}.zmdi-google-plus-box:before{content:'\f34c'}.zmdi-google-plus:before{content:'\f34d'}.zmdi-google:before{content:'\f34e'}.zmdi-instagram:before{content:'\f34f'}.zmdi-language-css3:before{content:'\f350'}.zmdi-language-html5:before{content:'\f351'}.zmdi-language-javascript:before{content:'\f352'}.zmdi-language-python-alt:before{content:'\f353'}.zmdi-language-python:before{content:'\f354'}.zmdi-lastfm:before{content:'\f355'}.zmdi-linkedin-box:before{content:'\f356'}.zmdi-paypal:before{content:'\f357'}.zmdi-pinterest-box:before{content:'\f358'}.zmdi-pocket:before{content:'\f359'}.zmdi-polymer:before{content:'\f35a'}.zmdi-share:before{content:'\f35b'}.zmdi-stackoverflow:before{content:'\f35c'}.zmdi-steam-square:before{content:'\f35d'}.zmdi-steam:before{content:'\f35e'}.zmdi-twitter-box:before{content:'\f35f'}.zmdi-twitter:before{content:'\f360'}.zmdi-vk:before{content:'\f361'}.zmdi-wikipedia:before{content:'\f362'}.zmdi-windows:before{content:'\f363'}.zmdi-aspect-ratio-alt:before{content:'\f364'}.zmdi-aspect-ratio:before{content:'\f365'}.zmdi-blur-circular:before{content:'\f366'}.zmdi-blur-linear:before{content:'\f367'}.zmdi-blur-off:before{content:'\f368'}.zmdi-blur:before{content:'\f369'}.zmdi-brightness-2:before{content:'\f36a'}.zmdi-brightness-3:before{content:'\f36b'}.zmdi-brightness-4:before{content:'\f36c'}.zmdi-brightness-5:before{content:'\f36d'}.zmdi-brightness-6:before{content:'\f36e'}.zmdi-brightness-7:before{content:'\f36f'}.zmdi-brightness-auto:before{content:'\f370'}.zmdi-brightness-setting:before{content:'\f371'}.zmdi-broken-image:before{content:'\f372'}.zmdi-center-focus-strong:before{content:'\f373'}.zmdi-center-focus-weak:before{content:'\f374'}.zmdi-compare:before{content:'\f375'}.zmdi-crop-16-9:before{content:'\f376'}.zmdi-crop-3-2:before{content:'\f377'}.zmdi-crop-5-4:before{content:'\f378'}.zmdi-crop-7-5:before{content:'\f379'}.zmdi-crop-din:before{content:'\f37a'}.zmdi-crop-free:before{content:'\f37b'}.zmdi-crop-landscape:before{content:'\f37c'}.zmdi-crop-portrait:before{content:'\f37d'}.zmdi-crop-square:before{content:'\f37e'}.zmdi-exposure-alt:before{content:'\f37f'}.zmdi-exposure:before{content:'\f380'}.zmdi-filter-b-and-w:before{content:'\f381'}.zmdi-filter-center-focus:before{content:'\f382'}.zmdi-filter-frames:before{content:'\f383'}.zmdi-filter-tilt-shift:before{content:'\f384'}.zmdi-gradient:before{content:'\f385'}.zmdi-grain:before{content:'\f386'}.zmdi-graphic-eq:before{content:'\f387'}.zmdi-hdr-off:before{content:'\f388'}.zmdi-hdr-strong:before{content:'\f389'}.zmdi-hdr-weak:before{content:'\f38a'}.zmdi-hdr:before{content:'\f38b'}.zmdi-iridescent:before{content:'\f38c'}.zmdi-leak-off:before{content:'\f38d'}.zmdi-leak:before{content:'\f38e'}.zmdi-looks:before{content:'\f38f'}.zmdi-loupe:before{content:'\f390'}.zmdi-panorama-horizontal:before{content:'\f391'}.zmdi-panorama-vertical:before{content:'\f392'}.zmdi-panorama-wide-angle:before{content:'\f393'}.zmdi-photo-size-select-large:before{content:'\f394'}.zmdi-photo-size-select-small:before{content:'\f395'}.zmdi-picture-in-picture:before{content:'\f396'}.zmdi-slideshow:before{content:'\f397'}.zmdi-texture:before{content:'\f398'}.zmdi-tonality:before{content:'\f399'}.zmdi-vignette:before{content:'\f39a'}.zmdi-wb-auto:before{content:'\f39b'}.zmdi-eject-alt:before{content:'\f39c'}.zmdi-eject:before{content:'\f39d'}.zmdi-equalizer:before{content:'\f39e'}.zmdi-fast-forward:before{content:'\f39f'}.zmdi-fast-rewind:before{content:'\f3a0'}.zmdi-forward-10:before{content:'\f3a1'}.zmdi-forward-30:before{content:'\f3a2'}.zmdi-forward-5:before{content:'\f3a3'}.zmdi-hearing:before{content:'\f3a4'}.zmdi-pause-circle-outline:before{content:'\f3a5'}.zmdi-pause-circle:before{content:'\f3a6'}.zmdi-pause:before{content:'\f3a7'}.zmdi-play-circle-outline:before{content:'\f3a8'}.zmdi-play-circle:before{content:'\f3a9'}.zmdi-play:before{content:'\f3aa'}.zmdi-playlist-audio:before{content:'\f3ab'}.zmdi-playlist-plus:before{content:'\f3ac'}.zmdi-repeat-one:before{content:'\f3ad'}.zmdi-repeat:before{content:'\f3ae'}.zmdi-replay-10:before{content:'\f3af'}.zmdi-replay-30:before{content:'\f3b0'}.zmdi-replay-5:before{content:'\f3b1'}.zmdi-replay:before{content:'\f3b2'}.zmdi-shuffle:before{content:'\f3b3'}.zmdi-skip-next:before{content:'\f3b4'}.zmdi-skip-previous:before{content:'\f3b5'}.zmdi-stop:before{content:'\f3b6'}.zmdi-surround-sound:before{content:'\f3b7'}.zmdi-tune:before{content:'\f3b8'}.zmdi-volume-down:before{content:'\f3b9'}.zmdi-volume-mute:before{content:'\f3ba'}.zmdi-volume-off:before{content:'\f3bb'}.zmdi-volume-up:before{content:'\f3bc'}.zmdi-n-1-square:before{content:'\f3bd'}.zmdi-n-2-square:before{content:'\f3be'}.zmdi-n-3-square:before{content:'\f3bf'}.zmdi-n-4-square:before{content:'\f3c0'}.zmdi-n-5-square:before{content:'\f3c1'}.zmdi-n-6-square:before{content:'\f3c2'}.zmdi-neg-1:before{content:'\f3c3'}.zmdi-neg-2:before{content:'\f3c4'}.zmdi-plus-1:before{content:'\f3c5'}.zmdi-plus-2:before{content:'\f3c6'}.zmdi-sec-10:before{content:'\f3c7'}.zmdi-sec-3:before{content:'\f3c8'}.zmdi-zero:before{content:'\f3c9'}.zmdi-airline-seat-flat-angled:before{content:'\f3ca'}.zmdi-airline-seat-flat:before{content:'\f3cb'}.zmdi-airline-seat-individual-suite:before{content:'\f3cc'}.zmdi-airline-seat-legroom-extra:before{content:'\f3cd'}.zmdi-airline-seat-legroom-normal:before{content:'\f3ce'}.zmdi-airline-seat-legroom-reduced:before{content:'\f3cf'}.zmdi-airline-seat-recline-extra:before{content:'\f3d0'}.zmdi-airline-seat-recline-normal:before{content:'\f3d1'}.zmdi-airplay:before{content:'\f3d2'}.zmdi-closed-caption:before{content:'\f3d3'}.zmdi-confirmation-number:before{content:'\f3d4'}.zmdi-developer-board:before{content:'\f3d5'}.zmdi-disc-full:before{content:'\f3d6'}.zmdi-explicit:before{content:'\f3d7'}.zmdi-flight-land:before{content:'\f3d8'}.zmdi-flight-takeoff:before{content:'\f3d9'}.zmdi-flip-to-back:before{content:'\f3da'}.zmdi-flip-to-front:before{content:'\f3db'}.zmdi-group-work:before{content:'\f3dc'}.zmdi-hd:before{content:'\f3dd'}.zmdi-hq:before{content:'\f3de'}.zmdi-markunread-mailbox:before{content:'\f3df'}.zmdi-memory:before{content:'\f3e0'}.zmdi-nfc:before{content:'\f3e1'}.zmdi-play-for-work:before{content:'\f3e2'}.zmdi-power-input:before{content:'\f3e3'}.zmdi-present-to-all:before{content:'\f3e4'}.zmdi-satellite:before{content:'\f3e5'}.zmdi-tap-and-play:before{content:'\f3e6'}.zmdi-vibration:before{content:'\f3e7'}.zmdi-voicemail:before{content:'\f3e8'}.zmdi-group:before{content:'\f3e9'}.zmdi-rss:before{content:'\f3ea'}.zmdi-shape:before{content:'\f3eb'}.zmdi-spinner:before{content:'\f3ec'}.zmdi-ungroup:before{content:'\f3ed'}.zmdi-500px:before{content:'\f3ee'}.zmdi-8tracks:before{content:'\f3ef'}.zmdi-amazon:before{content:'\f3f0'}.zmdi-blogger:before{content:'\f3f1'}.zmdi-delicious:before{content:'\f3f2'}.zmdi-disqus:before{content:'\f3f3'}.zmdi-flattr:before{content:'\f3f4'}.zmdi-flickr:before{content:'\f3f5'}.zmdi-github-alt:before{content:'\f3f6'}.zmdi-google-old:before{content:'\f3f7'}.zmdi-linkedin:before{content:'\f3f8'}.zmdi-odnoklassniki:before{content:'\f3f9'}.zmdi-outlook:before{content:'\f3fa'}.zmdi-paypal-alt:before{content:'\f3fb'}.zmdi-pinterest:before{content:'\f3fc'}.zmdi-playstation:before{content:'\f3fd'}.zmdi-reddit:before{content:'\f3fe'}.zmdi-skype:before{content:'\f3ff'}.zmdi-slideshare:before{content:'\f400'}.zmdi-soundcloud:before{content:'\f401'}.zmdi-tumblr:before{content:'\f402'}.zmdi-twitch:before{content:'\f403'}.zmdi-vimeo:before{content:'\f404'}.zmdi-whatsapp:before{content:'\f405'}.zmdi-xbox:before{content:'\f406'}.zmdi-yahoo:before{content:'\f407'}.zmdi-youtube-play:before{content:'\f408'}.zmdi-youtube:before{content:'\f409'}.zmdi-import-export:before{content:'\f30c'}.zmdi-swap-vertical-:before{content:'\f30c'}.zmdi-airplanemode-inactive:before{content:'\f102'}.zmdi-airplanemode-active:before{content:'\f103'}.zmdi-rate-review:before{content:'\f103'}.zmdi-comment-sign:before{content:'\f25a'}.zmdi-network-warning:before{content:'\f2ad'}.zmdi-shopping-cart-add:before{content:'\f1ca'}.zmdi-file-add:before{content:'\f221'}.zmdi-network-wifi-scan:before{content:'\f2e4'}.zmdi-collection-add:before{content:'\f14e'}.zmdi-format-playlist-add:before{content:'\f3ac'}.zmdi-format-queue-music:before{content:'\f3ab'}.zmdi-plus-box:before{content:'\f277'}.zmdi-tag-backspace:before{content:'\f1d9'}.zmdi-alarm-add:before{content:'\f32b'}.zmdi-battery-charging:before{content:'\f114'}.zmdi-daydream-setting:before{content:'\f217'}.zmdi-more-horiz:before{content:'\f19c'}.zmdi-book-photo:before{content:'\f11b'}.zmdi-incandescent:before{content:'\f189'}.zmdi-wb-iridescent:before{content:'\f38c'}.zmdi-calendar-remove:before{content:'\f330'}.zmdi-refresh-sync-disabled:before{content:'\f1b7'}.zmdi-refresh-sync-problem:before{content:'\f1b6'}.zmdi-crop-original:before{content:'\f17e'}.zmdi-power-off:before{content:'\f1af'}.zmdi-power-off-setting:before{content:'\f1ae'}.zmdi-leak-remove:before{content:'\f38d'}.zmdi-star-border:before{content:'\f27c'}.zmdi-brightness-low:before{content:'\f36d'}.zmdi-brightness-medium:before{content:'\f36e'}.zmdi-brightness-high:before{content:'\f36f'}.zmdi-smartphone-portrait:before{content:'\f2d4'}.zmdi-live-tv:before{content:'\f2d9'}.zmdi-format-textdirection-l-to-r:before{content:'\f249'}.zmdi-format-textdirection-r-to-l:before{content:'\f24a'}.zmdi-arrow-back:before{content:'\f2ea'}.zmdi-arrow-forward:before{content:'\f2ee'}.zmdi-arrow-in:before{content:'\f2e9'}.zmdi-arrow-out:before{content:'\f2ed'}.zmdi-rotate-90-degrees-ccw:before{content:'\f304'}.zmdi-adb:before{content:'\f33a'}.zmdi-network-wifi:before{content:'\f2e8'}.zmdi-network-wifi-alt:before{content:'\f2e3'}.zmdi-network-wifi-lock:before{content:'\f2e5'}.zmdi-network-wifi-off:before{content:'\f2e6'}.zmdi-network-wifi-outline:before{content:'\f2e7'}.zmdi-network-wifi-info:before{content:'\f2e4'}.zmdi-layers-clear:before{content:'\f18b'}.zmdi-colorize:before{content:'\f15d'}.zmdi-format-paint:before{content:'\f1ba'}.zmdi-format-quote:before{content:'\f1b2'}.zmdi-camera-monochrome-photos:before{content:'\f285'}.zmdi-sort-by-alpha:before{content:'\f1cf'}.zmdi-folder-shared:before{content:'\f225'}.zmdi-folder-special:before{content:'\f226'}.zmdi-comment-dots:before{content:'\f260'}.zmdi-reorder:before{content:'\f31e'}.zmdi-dehaze:before{content:'\f197'}.zmdi-sort:before{content:'\f1ce'}.zmdi-pages:before{content:'\f34a'}.zmdi-stack-overflow:before{content:'\f35c'}.zmdi-calendar-account:before{content:'\f204'}.zmdi-paste:before{content:'\f109'}.zmdi-cut:before{content:'\f1bc'}.zmdi-save:before{content:'\f297'}.zmdi-smartphone-code:before{content:'\f139'}.zmdi-directions-bike:before{content:'\f117'}.zmdi-directions-boat:before{content:'\f11a'}.zmdi-directions-bus:before{content:'\f121'}.zmdi-directions-car:before{content:'\f125'}.zmdi-directions-railway:before{content:'\f1b3'}.zmdi-directions-run:before{content:'\f215'}.zmdi-directions-subway:before{content:'\f1d5'}.zmdi-directions-walk:before{content:'\f216'}.zmdi-local-hotel:before{content:'\f178'}.zmdi-local-activity:before{content:'\f1df'}.zmdi-local-play:before{content:'\f1df'}.zmdi-local-airport:before{content:'\f103'}.zmdi-local-atm:before{content:'\f198'}.zmdi-local-bar:before{content:'\f137'}.zmdi-local-cafe:before{content:'\f13b'}.zmdi-local-car-wash:before{content:'\f124'}.zmdi-local-convenience-store:before{content:'\f1d3'}.zmdi-local-dining:before{content:'\f153'}.zmdi-local-drink:before{content:'\f157'}.zmdi-local-florist:before{content:'\f168'}.zmdi-local-gas-station:before{content:'\f16f'}.zmdi-local-grocery-store:before{content:'\f1cb'}.zmdi-local-hospital:before{content:'\f177'}.zmdi-local-laundry-service:before{content:'\f1e9'}.zmdi-local-library:before{content:'\f18d'}.zmdi-local-mall:before{content:'\f195'}.zmdi-local-movies:before{content:'\f19d'}.zmdi-local-offer:before{content:'\f187'}.zmdi-local-parking:before{content:'\f1a5'}.zmdi-local-parking:before{content:'\f1a5'}.zmdi-local-pharmacy:before{content:'\f176'}.zmdi-local-phone:before{content:'\f2be'}.zmdi-local-pizza:before{content:'\f1ac'}.zmdi-local-post-office:before{content:'\f15a'}.zmdi-local-printshop:before{content:'\f1b0'}.zmdi-local-see:before{content:'\f28c'}.zmdi-local-shipping:before{content:'\f1e6'}.zmdi-local-store:before{content:'\f1d4'}.zmdi-local-taxi:before{content:'\f123'}.zmdi-local-wc:before{content:'\f211'}.zmdi-my-location:before{content:'\f299'}.zmdi-directions:before{content:'\f1e7'} \ No newline at end of file diff --git a/public/Auth/fonts/material-icon/fonts/Material-Design-Iconic-Font.eot b/public/Auth/fonts/material-icon/fonts/Material-Design-Iconic-Font.eot new file mode 100755 index 0000000..5e25191 Binary files /dev/null and b/public/Auth/fonts/material-icon/fonts/Material-Design-Iconic-Font.eot differ diff --git a/public/Auth/fonts/material-icon/fonts/Material-Design-Iconic-Font.svg b/public/Auth/fonts/material-icon/fonts/Material-Design-Iconic-Font.svg new file mode 100755 index 0000000..8cb2673 --- /dev/null +++ b/public/Auth/fonts/material-icon/fonts/Material-Design-Iconic-Font.svg @@ -0,0 +1,787 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/public/Auth/fonts/material-icon/fonts/Material-Design-Iconic-Font.ttf b/public/Auth/fonts/material-icon/fonts/Material-Design-Iconic-Font.ttf new file mode 100755 index 0000000..5d489fd Binary files /dev/null and b/public/Auth/fonts/material-icon/fonts/Material-Design-Iconic-Font.ttf differ diff --git a/public/Auth/fonts/material-icon/fonts/Material-Design-Iconic-Font.woff b/public/Auth/fonts/material-icon/fonts/Material-Design-Iconic-Font.woff new file mode 100755 index 0000000..933b2bf Binary files /dev/null and b/public/Auth/fonts/material-icon/fonts/Material-Design-Iconic-Font.woff differ diff --git a/public/Auth/fonts/material-icon/fonts/Material-Design-Iconic-Font.woff2 b/public/Auth/fonts/material-icon/fonts/Material-Design-Iconic-Font.woff2 new file mode 100755 index 0000000..35970e2 Binary files /dev/null and b/public/Auth/fonts/material-icon/fonts/Material-Design-Iconic-Font.woff2 differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-300.eot b/public/Auth/fonts/poppins/poppins-v5-latin-300.eot new file mode 100755 index 0000000..a34e08f Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-300.eot differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-300.svg b/public/Auth/fonts/poppins/poppins-v5-latin-300.svg new file mode 100755 index 0000000..bda92bb --- /dev/null +++ b/public/Auth/fonts/poppins/poppins-v5-latin-300.svg @@ -0,0 +1,320 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-300.ttf b/public/Auth/fonts/poppins/poppins-v5-latin-300.ttf new file mode 100755 index 0000000..755cac6 Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-300.ttf differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-300.woff b/public/Auth/fonts/poppins/poppins-v5-latin-300.woff new file mode 100755 index 0000000..9d48006 Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-300.woff differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-300.woff2 b/public/Auth/fonts/poppins/poppins-v5-latin-300.woff2 new file mode 100755 index 0000000..ee94627 Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-300.woff2 differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-300italic.eot b/public/Auth/fonts/poppins/poppins-v5-latin-300italic.eot new file mode 100755 index 0000000..1fc068d Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-300italic.eot differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-300italic.svg b/public/Auth/fonts/poppins/poppins-v5-latin-300italic.svg new file mode 100755 index 0000000..ddb13d9 --- /dev/null +++ b/public/Auth/fonts/poppins/poppins-v5-latin-300italic.svg @@ -0,0 +1,342 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-300italic.ttf b/public/Auth/fonts/poppins/poppins-v5-latin-300italic.ttf new file mode 100755 index 0000000..2d422ea Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-300italic.ttf differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-300italic.woff b/public/Auth/fonts/poppins/poppins-v5-latin-300italic.woff new file mode 100755 index 0000000..7754dab Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-300italic.woff differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-300italic.woff2 b/public/Auth/fonts/poppins/poppins-v5-latin-300italic.woff2 new file mode 100755 index 0000000..074e36c Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-300italic.woff2 differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-500.eot b/public/Auth/fonts/poppins/poppins-v5-latin-500.eot new file mode 100755 index 0000000..78f77dc Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-500.eot differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-500.svg b/public/Auth/fonts/poppins/poppins-v5-latin-500.svg new file mode 100755 index 0000000..2e9e363 --- /dev/null +++ b/public/Auth/fonts/poppins/poppins-v5-latin-500.svg @@ -0,0 +1,322 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-500.ttf b/public/Auth/fonts/poppins/poppins-v5-latin-500.ttf new file mode 100755 index 0000000..c624d5e Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-500.ttf differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-500.woff b/public/Auth/fonts/poppins/poppins-v5-latin-500.woff new file mode 100755 index 0000000..decd7fe Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-500.woff differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-500.woff2 b/public/Auth/fonts/poppins/poppins-v5-latin-500.woff2 new file mode 100755 index 0000000..b57f095 Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-500.woff2 differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-500italic.eot b/public/Auth/fonts/poppins/poppins-v5-latin-500italic.eot new file mode 100755 index 0000000..3e544e9 Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-500italic.eot differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-500italic.svg b/public/Auth/fonts/poppins/poppins-v5-latin-500italic.svg new file mode 100755 index 0000000..d4c3c56 --- /dev/null +++ b/public/Auth/fonts/poppins/poppins-v5-latin-500italic.svg @@ -0,0 +1,341 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-500italic.ttf b/public/Auth/fonts/poppins/poppins-v5-latin-500italic.ttf new file mode 100755 index 0000000..b2eb100 Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-500italic.ttf differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-500italic.woff b/public/Auth/fonts/poppins/poppins-v5-latin-500italic.woff new file mode 100755 index 0000000..37995fa Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-500italic.woff differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-500italic.woff2 b/public/Auth/fonts/poppins/poppins-v5-latin-500italic.woff2 new file mode 100755 index 0000000..766570c Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-500italic.woff2 differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-600.eot b/public/Auth/fonts/poppins/poppins-v5-latin-600.eot new file mode 100755 index 0000000..539a16b Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-600.eot differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-600.svg b/public/Auth/fonts/poppins/poppins-v5-latin-600.svg new file mode 100755 index 0000000..ee34278 --- /dev/null +++ b/public/Auth/fonts/poppins/poppins-v5-latin-600.svg @@ -0,0 +1,321 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-600.ttf b/public/Auth/fonts/poppins/poppins-v5-latin-600.ttf new file mode 100755 index 0000000..eb25875 Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-600.ttf differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-600.woff b/public/Auth/fonts/poppins/poppins-v5-latin-600.woff new file mode 100755 index 0000000..b7f4279 Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-600.woff differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-600.woff2 b/public/Auth/fonts/poppins/poppins-v5-latin-600.woff2 new file mode 100755 index 0000000..b418923 Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-600.woff2 differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-700.eot b/public/Auth/fonts/poppins/poppins-v5-latin-700.eot new file mode 100755 index 0000000..5efd4c8 Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-700.eot differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-700.svg b/public/Auth/fonts/poppins/poppins-v5-latin-700.svg new file mode 100755 index 0000000..6c4c4a5 --- /dev/null +++ b/public/Auth/fonts/poppins/poppins-v5-latin-700.svg @@ -0,0 +1,321 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-700.ttf b/public/Auth/fonts/poppins/poppins-v5-latin-700.ttf new file mode 100755 index 0000000..9b6e988 Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-700.ttf differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-700.woff b/public/Auth/fonts/poppins/poppins-v5-latin-700.woff new file mode 100755 index 0000000..ed5b743 Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-700.woff differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-700.woff2 b/public/Auth/fonts/poppins/poppins-v5-latin-700.woff2 new file mode 100755 index 0000000..a2a876f Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-700.woff2 differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-700italic.eot b/public/Auth/fonts/poppins/poppins-v5-latin-700italic.eot new file mode 100755 index 0000000..82ae0a0 Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-700italic.eot differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-700italic.svg b/public/Auth/fonts/poppins/poppins-v5-latin-700italic.svg new file mode 100755 index 0000000..7d45c96 --- /dev/null +++ b/public/Auth/fonts/poppins/poppins-v5-latin-700italic.svg @@ -0,0 +1,340 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-700italic.ttf b/public/Auth/fonts/poppins/poppins-v5-latin-700italic.ttf new file mode 100755 index 0000000..549aba1 Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-700italic.ttf differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-700italic.woff b/public/Auth/fonts/poppins/poppins-v5-latin-700italic.woff new file mode 100755 index 0000000..cd9dfe3 Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-700italic.woff differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-700italic.woff2 b/public/Auth/fonts/poppins/poppins-v5-latin-700italic.woff2 new file mode 100755 index 0000000..7580d15 Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-700italic.woff2 differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-800.eot b/public/Auth/fonts/poppins/poppins-v5-latin-800.eot new file mode 100755 index 0000000..e9977cd Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-800.eot differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-800.svg b/public/Auth/fonts/poppins/poppins-v5-latin-800.svg new file mode 100755 index 0000000..29f08c8 --- /dev/null +++ b/public/Auth/fonts/poppins/poppins-v5-latin-800.svg @@ -0,0 +1,321 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-800.ttf b/public/Auth/fonts/poppins/poppins-v5-latin-800.ttf new file mode 100755 index 0000000..6be78c0 Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-800.ttf differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-800.woff b/public/Auth/fonts/poppins/poppins-v5-latin-800.woff new file mode 100755 index 0000000..53a3afa Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-800.woff differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-800.woff2 b/public/Auth/fonts/poppins/poppins-v5-latin-800.woff2 new file mode 100755 index 0000000..bd102a2 Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-800.woff2 differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-800italic.eot b/public/Auth/fonts/poppins/poppins-v5-latin-800italic.eot new file mode 100755 index 0000000..8d796b3 Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-800italic.eot differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-800italic.svg b/public/Auth/fonts/poppins/poppins-v5-latin-800italic.svg new file mode 100755 index 0000000..68446ce --- /dev/null +++ b/public/Auth/fonts/poppins/poppins-v5-latin-800italic.svg @@ -0,0 +1,341 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-800italic.ttf b/public/Auth/fonts/poppins/poppins-v5-latin-800italic.ttf new file mode 100755 index 0000000..0acf306 Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-800italic.ttf differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-800italic.woff b/public/Auth/fonts/poppins/poppins-v5-latin-800italic.woff new file mode 100755 index 0000000..092e40d Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-800italic.woff differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-800italic.woff2 b/public/Auth/fonts/poppins/poppins-v5-latin-800italic.woff2 new file mode 100755 index 0000000..4da0c36 Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-800italic.woff2 differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-900.eot b/public/Auth/fonts/poppins/poppins-v5-latin-900.eot new file mode 100755 index 0000000..2985e07 Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-900.eot differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-900.svg b/public/Auth/fonts/poppins/poppins-v5-latin-900.svg new file mode 100755 index 0000000..e981031 --- /dev/null +++ b/public/Auth/fonts/poppins/poppins-v5-latin-900.svg @@ -0,0 +1,322 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-900.ttf b/public/Auth/fonts/poppins/poppins-v5-latin-900.ttf new file mode 100755 index 0000000..243c472 Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-900.ttf differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-900.woff b/public/Auth/fonts/poppins/poppins-v5-latin-900.woff new file mode 100755 index 0000000..0e3f44f Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-900.woff differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-900.woff2 b/public/Auth/fonts/poppins/poppins-v5-latin-900.woff2 new file mode 100755 index 0000000..4fa8946 Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-900.woff2 differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-italic.eot b/public/Auth/fonts/poppins/poppins-v5-latin-italic.eot new file mode 100755 index 0000000..94ea117 Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-italic.eot differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-italic.svg b/public/Auth/fonts/poppins/poppins-v5-latin-italic.svg new file mode 100755 index 0000000..e00cd94 --- /dev/null +++ b/public/Auth/fonts/poppins/poppins-v5-latin-italic.svg @@ -0,0 +1,340 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-italic.ttf b/public/Auth/fonts/poppins/poppins-v5-latin-italic.ttf new file mode 100755 index 0000000..6ec9da3 Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-italic.ttf differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-italic.woff b/public/Auth/fonts/poppins/poppins-v5-latin-italic.woff new file mode 100755 index 0000000..56c5ee4 Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-italic.woff differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-italic.woff2 b/public/Auth/fonts/poppins/poppins-v5-latin-italic.woff2 new file mode 100755 index 0000000..5ccb3e4 Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-italic.woff2 differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-regular.eot b/public/Auth/fonts/poppins/poppins-v5-latin-regular.eot new file mode 100755 index 0000000..ff32634 Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-regular.eot differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-regular.svg b/public/Auth/fonts/poppins/poppins-v5-latin-regular.svg new file mode 100755 index 0000000..c3d485c --- /dev/null +++ b/public/Auth/fonts/poppins/poppins-v5-latin-regular.svg @@ -0,0 +1,323 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-regular.ttf b/public/Auth/fonts/poppins/poppins-v5-latin-regular.ttf new file mode 100755 index 0000000..5f2caab Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-regular.ttf differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-regular.woff b/public/Auth/fonts/poppins/poppins-v5-latin-regular.woff new file mode 100755 index 0000000..cfb9c3d Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-regular.woff differ diff --git a/public/Auth/fonts/poppins/poppins-v5-latin-regular.woff2 b/public/Auth/fonts/poppins/poppins-v5-latin-regular.woff2 new file mode 100755 index 0000000..19f70c6 Binary files /dev/null and b/public/Auth/fonts/poppins/poppins-v5-latin-regular.woff2 differ diff --git a/public/Auth/fonts/poppins/roboto-condensed-v16-latin-700.eot b/public/Auth/fonts/poppins/roboto-condensed-v16-latin-700.eot new file mode 100755 index 0000000..2e96810 Binary files /dev/null and b/public/Auth/fonts/poppins/roboto-condensed-v16-latin-700.eot differ diff --git a/public/Auth/fonts/poppins/roboto-condensed-v16-latin-700.svg b/public/Auth/fonts/poppins/roboto-condensed-v16-latin-700.svg new file mode 100755 index 0000000..ab6491b --- /dev/null +++ b/public/Auth/fonts/poppins/roboto-condensed-v16-latin-700.svg @@ -0,0 +1,309 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/public/Auth/fonts/poppins/roboto-condensed-v16-latin-700.ttf b/public/Auth/fonts/poppins/roboto-condensed-v16-latin-700.ttf new file mode 100755 index 0000000..c99c240 Binary files /dev/null and b/public/Auth/fonts/poppins/roboto-condensed-v16-latin-700.ttf differ diff --git a/public/Auth/fonts/poppins/roboto-condensed-v16-latin-700.woff b/public/Auth/fonts/poppins/roboto-condensed-v16-latin-700.woff new file mode 100755 index 0000000..4aa4935 Binary files /dev/null and b/public/Auth/fonts/poppins/roboto-condensed-v16-latin-700.woff differ diff --git a/public/Auth/fonts/poppins/roboto-condensed-v16-latin-700.woff2 b/public/Auth/fonts/poppins/roboto-condensed-v16-latin-700.woff2 new file mode 100755 index 0000000..ba3d4a4 Binary files /dev/null and b/public/Auth/fonts/poppins/roboto-condensed-v16-latin-700.woff2 differ diff --git a/public/Auth/fonts/poppins/roboto-condensed-v16-latin-700italic.eot b/public/Auth/fonts/poppins/roboto-condensed-v16-latin-700italic.eot new file mode 100755 index 0000000..ff460fb Binary files /dev/null and b/public/Auth/fonts/poppins/roboto-condensed-v16-latin-700italic.eot differ diff --git a/public/Auth/fonts/poppins/roboto-condensed-v16-latin-700italic.svg b/public/Auth/fonts/poppins/roboto-condensed-v16-latin-700italic.svg new file mode 100755 index 0000000..fb2e82e --- /dev/null +++ b/public/Auth/fonts/poppins/roboto-condensed-v16-latin-700italic.svg @@ -0,0 +1,322 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/public/Auth/fonts/poppins/roboto-condensed-v16-latin-700italic.ttf b/public/Auth/fonts/poppins/roboto-condensed-v16-latin-700italic.ttf new file mode 100755 index 0000000..17567f2 Binary files /dev/null and b/public/Auth/fonts/poppins/roboto-condensed-v16-latin-700italic.ttf differ diff --git a/public/Auth/fonts/poppins/roboto-condensed-v16-latin-700italic.woff b/public/Auth/fonts/poppins/roboto-condensed-v16-latin-700italic.woff new file mode 100755 index 0000000..a778b54 Binary files /dev/null and b/public/Auth/fonts/poppins/roboto-condensed-v16-latin-700italic.woff differ diff --git a/public/Auth/fonts/poppins/roboto-condensed-v16-latin-700italic.woff2 b/public/Auth/fonts/poppins/roboto-condensed-v16-latin-700italic.woff2 new file mode 100755 index 0000000..ddfaeac Binary files /dev/null and b/public/Auth/fonts/poppins/roboto-condensed-v16-latin-700italic.woff2 differ diff --git a/public/Auth/fonts/poppins/roboto-condensed-v16-latin-italic.eot b/public/Auth/fonts/poppins/roboto-condensed-v16-latin-italic.eot new file mode 100755 index 0000000..64f0cd0 Binary files /dev/null and b/public/Auth/fonts/poppins/roboto-condensed-v16-latin-italic.eot differ diff --git a/public/Auth/fonts/poppins/roboto-condensed-v16-latin-italic.svg b/public/Auth/fonts/poppins/roboto-condensed-v16-latin-italic.svg new file mode 100755 index 0000000..7a01f8d --- /dev/null +++ b/public/Auth/fonts/poppins/roboto-condensed-v16-latin-italic.svg @@ -0,0 +1,326 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/public/Auth/fonts/poppins/roboto-condensed-v16-latin-italic.ttf b/public/Auth/fonts/poppins/roboto-condensed-v16-latin-italic.ttf new file mode 100755 index 0000000..c1d1377 Binary files /dev/null and b/public/Auth/fonts/poppins/roboto-condensed-v16-latin-italic.ttf differ diff --git a/public/Auth/fonts/poppins/roboto-condensed-v16-latin-italic.woff b/public/Auth/fonts/poppins/roboto-condensed-v16-latin-italic.woff new file mode 100755 index 0000000..1cd704c Binary files /dev/null and b/public/Auth/fonts/poppins/roboto-condensed-v16-latin-italic.woff differ diff --git a/public/Auth/fonts/poppins/roboto-condensed-v16-latin-italic.woff2 b/public/Auth/fonts/poppins/roboto-condensed-v16-latin-italic.woff2 new file mode 100755 index 0000000..a19afd4 Binary files /dev/null and b/public/Auth/fonts/poppins/roboto-condensed-v16-latin-italic.woff2 differ diff --git a/public/Auth/fonts/poppins/roboto-condensed-v16-latin-regular.eot b/public/Auth/fonts/poppins/roboto-condensed-v16-latin-regular.eot new file mode 100755 index 0000000..ce6c273 Binary files /dev/null and b/public/Auth/fonts/poppins/roboto-condensed-v16-latin-regular.eot differ diff --git a/public/Auth/fonts/poppins/roboto-condensed-v16-latin-regular.svg b/public/Auth/fonts/poppins/roboto-condensed-v16-latin-regular.svg new file mode 100755 index 0000000..803c3b8 --- /dev/null +++ b/public/Auth/fonts/poppins/roboto-condensed-v16-latin-regular.svg @@ -0,0 +1,306 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/public/Auth/fonts/poppins/roboto-condensed-v16-latin-regular.ttf b/public/Auth/fonts/poppins/roboto-condensed-v16-latin-regular.ttf new file mode 100755 index 0000000..053201b Binary files /dev/null and b/public/Auth/fonts/poppins/roboto-condensed-v16-latin-regular.ttf differ diff --git a/public/Auth/fonts/poppins/roboto-condensed-v16-latin-regular.woff b/public/Auth/fonts/poppins/roboto-condensed-v16-latin-regular.woff new file mode 100755 index 0000000..613f5de Binary files /dev/null and b/public/Auth/fonts/poppins/roboto-condensed-v16-latin-regular.woff differ diff --git a/public/Auth/fonts/poppins/roboto-condensed-v16-latin-regular.woff2 b/public/Auth/fonts/poppins/roboto-condensed-v16-latin-regular.woff2 new file mode 100755 index 0000000..e90965b Binary files /dev/null and b/public/Auth/fonts/poppins/roboto-condensed-v16-latin-regular.woff2 differ diff --git a/public/Auth/images/bg-checker.png b/public/Auth/images/bg-checker.png new file mode 100755 index 0000000..d1776f4 Binary files /dev/null and b/public/Auth/images/bg-checker.png differ diff --git a/public/Auth/images/bg-client.png b/public/Auth/images/bg-client.png new file mode 100755 index 0000000..6e75166 Binary files /dev/null and b/public/Auth/images/bg-client.png differ diff --git a/public/Auth/images/bg-login.png b/public/Auth/images/bg-login.png new file mode 100755 index 0000000..0716a8b Binary files /dev/null and b/public/Auth/images/bg-login.png differ diff --git a/public/Auth/images/bg-vendor.png b/public/Auth/images/bg-vendor.png new file mode 100755 index 0000000..54d44db Binary files /dev/null and b/public/Auth/images/bg-vendor.png differ diff --git a/public/Auth/images/signin-image.jpg b/public/Auth/images/signin-image.jpg new file mode 100755 index 0000000..1bafcd5 Binary files /dev/null and b/public/Auth/images/signin-image.jpg differ diff --git a/public/Auth/images/signup-image.jpg b/public/Auth/images/signup-image.jpg new file mode 100755 index 0000000..171e3e5 Binary files /dev/null and b/public/Auth/images/signup-image.jpg differ diff --git a/public/Auth/js/main.js b/public/Auth/js/main.js new file mode 100755 index 0000000..e69de29 diff --git a/public/Auth/vendor/jquery/jquery-ui.min.js b/public/Auth/vendor/jquery/jquery-ui.min.js new file mode 100755 index 0000000..25398a1 --- /dev/null +++ b/public/Auth/vendor/jquery/jquery-ui.min.js @@ -0,0 +1,13 @@ +/*! jQuery UI - v1.12.1 - 2016-09-14 +* http://jqueryui.com +* Includes: widget.js, position.js, data.js, disable-selection.js, effect.js, effects/effect-blind.js, effects/effect-bounce.js, effects/effect-clip.js, effects/effect-drop.js, effects/effect-explode.js, effects/effect-fade.js, effects/effect-fold.js, effects/effect-highlight.js, effects/effect-puff.js, effects/effect-pulsate.js, effects/effect-scale.js, effects/effect-shake.js, effects/effect-size.js, effects/effect-slide.js, effects/effect-transfer.js, focusable.js, form-reset-mixin.js, jquery-1-7.js, keycode.js, labels.js, scroll-parent.js, tabbable.js, unique-id.js, widgets/accordion.js, widgets/autocomplete.js, widgets/button.js, widgets/checkboxradio.js, widgets/controlgroup.js, widgets/datepicker.js, widgets/dialog.js, widgets/draggable.js, widgets/droppable.js, widgets/menu.js, widgets/mouse.js, widgets/progressbar.js, widgets/resizable.js, widgets/selectable.js, widgets/selectmenu.js, widgets/slider.js, widgets/sortable.js, widgets/spinner.js, widgets/tabs.js, widgets/tooltip.js +* Copyright jQuery Foundation and other contributors; Licensed MIT */ + +(function(t){"function"==typeof define&&define.amd?define(["jquery"],t):t(jQuery)})(function(t){function e(t){for(var e=t.css("visibility");"inherit"===e;)t=t.parent(),e=t.css("visibility");return"hidden"!==e}function i(t){for(var e,i;t.length&&t[0]!==document;){if(e=t.css("position"),("absolute"===e||"relative"===e||"fixed"===e)&&(i=parseInt(t.css("zIndex"),10),!isNaN(i)&&0!==i))return i;t=t.parent()}return 0}function s(){this._curInst=null,this._keyEvent=!1,this._disabledInputs=[],this._datepickerShowing=!1,this._inDialog=!1,this._mainDivId="ui-datepicker-div",this._inlineClass="ui-datepicker-inline",this._appendClass="ui-datepicker-append",this._triggerClass="ui-datepicker-trigger",this._dialogClass="ui-datepicker-dialog",this._disableClass="ui-datepicker-disabled",this._unselectableClass="ui-datepicker-unselectable",this._currentClass="ui-datepicker-current-day",this._dayOverClass="ui-datepicker-days-cell-over",this.regional=[],this.regional[""]={closeText:"Done",prevText:"Prev",nextText:"Next",currentText:"Today",monthNames:["January","February","March","April","May","June","July","August","September","October","November","December"],monthNamesShort:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],dayNames:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],dayNamesShort:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],dayNamesMin:["Su","Mo","Tu","We","Th","Fr","Sa"],weekHeader:"Wk",dateFormat:"mm/dd/yy",firstDay:0,isRTL:!1,showMonthAfterYear:!1,yearSuffix:""},this._defaults={showOn:"focus",showAnim:"fadeIn",showOptions:{},defaultDate:null,appendText:"",buttonText:"...",buttonImage:"",buttonImageOnly:!1,hideIfNoPrevNext:!1,navigationAsDateFormat:!1,gotoCurrent:!1,changeMonth:!1,changeYear:!1,yearRange:"c-10:c+10",showOtherMonths:!1,selectOtherMonths:!1,showWeek:!1,calculateWeek:this.iso8601Week,shortYearCutoff:"+10",minDate:null,maxDate:null,duration:"fast",beforeShowDay:null,beforeShow:null,onSelect:null,onChangeMonthYear:null,onClose:null,numberOfMonths:1,showCurrentAtPos:0,stepMonths:1,stepBigMonths:12,altField:"",altFormat:"",constrainInput:!0,showButtonPanel:!1,autoSize:!1,disabled:!1},t.extend(this._defaults,this.regional[""]),this.regional.en=t.extend(!0,{},this.regional[""]),this.regional["en-US"]=t.extend(!0,{},this.regional.en),this.dpDiv=n(t("
"))}function n(e){var i="button, .ui-datepicker-prev, .ui-datepicker-next, .ui-datepicker-calendar td a";return e.on("mouseout",i,function(){t(this).removeClass("ui-state-hover"),-1!==this.className.indexOf("ui-datepicker-prev")&&t(this).removeClass("ui-datepicker-prev-hover"),-1!==this.className.indexOf("ui-datepicker-next")&&t(this).removeClass("ui-datepicker-next-hover")}).on("mouseover",i,o)}function o(){t.datepicker._isDisabledDatepicker(m.inline?m.dpDiv.parent()[0]:m.input[0])||(t(this).parents(".ui-datepicker-calendar").find("a").removeClass("ui-state-hover"),t(this).addClass("ui-state-hover"),-1!==this.className.indexOf("ui-datepicker-prev")&&t(this).addClass("ui-datepicker-prev-hover"),-1!==this.className.indexOf("ui-datepicker-next")&&t(this).addClass("ui-datepicker-next-hover"))}function a(e,i){t.extend(e,i);for(var s in i)null==i[s]&&(e[s]=i[s]);return e}function r(t){return function(){var e=this.element.val();t.apply(this,arguments),this._refresh(),e!==this.element.val()&&this._trigger("change")}}t.ui=t.ui||{},t.ui.version="1.12.1";var h=0,l=Array.prototype.slice;t.cleanData=function(e){return function(i){var s,n,o;for(o=0;null!=(n=i[o]);o++)try{s=t._data(n,"events"),s&&s.remove&&t(n).triggerHandler("remove")}catch(a){}e(i)}}(t.cleanData),t.widget=function(e,i,s){var n,o,a,r={},h=e.split(".")[0];e=e.split(".")[1];var l=h+"-"+e;return s||(s=i,i=t.Widget),t.isArray(s)&&(s=t.extend.apply(null,[{}].concat(s))),t.expr[":"][l.toLowerCase()]=function(e){return!!t.data(e,l)},t[h]=t[h]||{},n=t[h][e],o=t[h][e]=function(t,e){return this._createWidget?(arguments.length&&this._createWidget(t,e),void 0):new o(t,e)},t.extend(o,n,{version:s.version,_proto:t.extend({},s),_childConstructors:[]}),a=new i,a.options=t.widget.extend({},a.options),t.each(s,function(e,s){return t.isFunction(s)?(r[e]=function(){function t(){return i.prototype[e].apply(this,arguments)}function n(t){return i.prototype[e].apply(this,t)}return function(){var e,i=this._super,o=this._superApply;return this._super=t,this._superApply=n,e=s.apply(this,arguments),this._super=i,this._superApply=o,e}}(),void 0):(r[e]=s,void 0)}),o.prototype=t.widget.extend(a,{widgetEventPrefix:n?a.widgetEventPrefix||e:e},r,{constructor:o,namespace:h,widgetName:e,widgetFullName:l}),n?(t.each(n._childConstructors,function(e,i){var s=i.prototype;t.widget(s.namespace+"."+s.widgetName,o,i._proto)}),delete n._childConstructors):i._childConstructors.push(o),t.widget.bridge(e,o),o},t.widget.extend=function(e){for(var i,s,n=l.call(arguments,1),o=0,a=n.length;a>o;o++)for(i in n[o])s=n[o][i],n[o].hasOwnProperty(i)&&void 0!==s&&(e[i]=t.isPlainObject(s)?t.isPlainObject(e[i])?t.widget.extend({},e[i],s):t.widget.extend({},s):s);return e},t.widget.bridge=function(e,i){var s=i.prototype.widgetFullName||e;t.fn[e]=function(n){var o="string"==typeof n,a=l.call(arguments,1),r=this;return o?this.length||"instance"!==n?this.each(function(){var i,o=t.data(this,s);return"instance"===n?(r=o,!1):o?t.isFunction(o[n])&&"_"!==n.charAt(0)?(i=o[n].apply(o,a),i!==o&&void 0!==i?(r=i&&i.jquery?r.pushStack(i.get()):i,!1):void 0):t.error("no such method '"+n+"' for "+e+" widget instance"):t.error("cannot call methods on "+e+" prior to initialization; "+"attempted to call method '"+n+"'")}):r=void 0:(a.length&&(n=t.widget.extend.apply(null,[n].concat(a))),this.each(function(){var e=t.data(this,s);e?(e.option(n||{}),e._init&&e._init()):t.data(this,s,new i(n,this))})),r}},t.Widget=function(){},t.Widget._childConstructors=[],t.Widget.prototype={widgetName:"widget",widgetEventPrefix:"",defaultElement:"
",options:{classes:{},disabled:!1,create:null},_createWidget:function(e,i){i=t(i||this.defaultElement||this)[0],this.element=t(i),this.uuid=h++,this.eventNamespace="."+this.widgetName+this.uuid,this.bindings=t(),this.hoverable=t(),this.focusable=t(),this.classesElementLookup={},i!==this&&(t.data(i,this.widgetFullName,this),this._on(!0,this.element,{remove:function(t){t.target===i&&this.destroy()}}),this.document=t(i.style?i.ownerDocument:i.document||i),this.window=t(this.document[0].defaultView||this.document[0].parentWindow)),this.options=t.widget.extend({},this.options,this._getCreateOptions(),e),this._create(),this.options.disabled&&this._setOptionDisabled(this.options.disabled),this._trigger("create",null,this._getCreateEventData()),this._init()},_getCreateOptions:function(){return{}},_getCreateEventData:t.noop,_create:t.noop,_init:t.noop,destroy:function(){var e=this;this._destroy(),t.each(this.classesElementLookup,function(t,i){e._removeClass(i,t)}),this.element.off(this.eventNamespace).removeData(this.widgetFullName),this.widget().off(this.eventNamespace).removeAttr("aria-disabled"),this.bindings.off(this.eventNamespace)},_destroy:t.noop,widget:function(){return this.element},option:function(e,i){var s,n,o,a=e;if(0===arguments.length)return t.widget.extend({},this.options);if("string"==typeof e)if(a={},s=e.split("."),e=s.shift(),s.length){for(n=a[e]=t.widget.extend({},this.options[e]),o=0;s.length-1>o;o++)n[s[o]]=n[s[o]]||{},n=n[s[o]];if(e=s.pop(),1===arguments.length)return void 0===n[e]?null:n[e];n[e]=i}else{if(1===arguments.length)return void 0===this.options[e]?null:this.options[e];a[e]=i}return this._setOptions(a),this},_setOptions:function(t){var e;for(e in t)this._setOption(e,t[e]);return this},_setOption:function(t,e){return"classes"===t&&this._setOptionClasses(e),this.options[t]=e,"disabled"===t&&this._setOptionDisabled(e),this},_setOptionClasses:function(e){var i,s,n;for(i in e)n=this.classesElementLookup[i],e[i]!==this.options.classes[i]&&n&&n.length&&(s=t(n.get()),this._removeClass(n,i),s.addClass(this._classes({element:s,keys:i,classes:e,add:!0})))},_setOptionDisabled:function(t){this._toggleClass(this.widget(),this.widgetFullName+"-disabled",null,!!t),t&&(this._removeClass(this.hoverable,null,"ui-state-hover"),this._removeClass(this.focusable,null,"ui-state-focus"))},enable:function(){return this._setOptions({disabled:!1})},disable:function(){return this._setOptions({disabled:!0})},_classes:function(e){function i(i,o){var a,r;for(r=0;i.length>r;r++)a=n.classesElementLookup[i[r]]||t(),a=e.add?t(t.unique(a.get().concat(e.element.get()))):t(a.not(e.element).get()),n.classesElementLookup[i[r]]=a,s.push(i[r]),o&&e.classes[i[r]]&&s.push(e.classes[i[r]])}var s=[],n=this;return e=t.extend({element:this.element,classes:this.options.classes||{}},e),this._on(e.element,{remove:"_untrackClassesElement"}),e.keys&&i(e.keys.match(/\S+/g)||[],!0),e.extra&&i(e.extra.match(/\S+/g)||[]),s.join(" ")},_untrackClassesElement:function(e){var i=this;t.each(i.classesElementLookup,function(s,n){-1!==t.inArray(e.target,n)&&(i.classesElementLookup[s]=t(n.not(e.target).get()))})},_removeClass:function(t,e,i){return this._toggleClass(t,e,i,!1)},_addClass:function(t,e,i){return this._toggleClass(t,e,i,!0)},_toggleClass:function(t,e,i,s){s="boolean"==typeof s?s:i;var n="string"==typeof t||null===t,o={extra:n?e:i,keys:n?t:e,element:n?this.element:t,add:s};return o.element.toggleClass(this._classes(o),s),this},_on:function(e,i,s){var n,o=this;"boolean"!=typeof e&&(s=i,i=e,e=!1),s?(i=n=t(i),this.bindings=this.bindings.add(i)):(s=i,i=this.element,n=this.widget()),t.each(s,function(s,a){function r(){return e||o.options.disabled!==!0&&!t(this).hasClass("ui-state-disabled")?("string"==typeof a?o[a]:a).apply(o,arguments):void 0}"string"!=typeof a&&(r.guid=a.guid=a.guid||r.guid||t.guid++);var h=s.match(/^([\w:-]*)\s*(.*)$/),l=h[1]+o.eventNamespace,c=h[2];c?n.on(l,c,r):i.on(l,r)})},_off:function(e,i){i=(i||"").split(" ").join(this.eventNamespace+" ")+this.eventNamespace,e.off(i).off(i),this.bindings=t(this.bindings.not(e).get()),this.focusable=t(this.focusable.not(e).get()),this.hoverable=t(this.hoverable.not(e).get())},_delay:function(t,e){function i(){return("string"==typeof t?s[t]:t).apply(s,arguments)}var s=this;return setTimeout(i,e||0)},_hoverable:function(e){this.hoverable=this.hoverable.add(e),this._on(e,{mouseenter:function(e){this._addClass(t(e.currentTarget),null,"ui-state-hover")},mouseleave:function(e){this._removeClass(t(e.currentTarget),null,"ui-state-hover")}})},_focusable:function(e){this.focusable=this.focusable.add(e),this._on(e,{focusin:function(e){this._addClass(t(e.currentTarget),null,"ui-state-focus")},focusout:function(e){this._removeClass(t(e.currentTarget),null,"ui-state-focus")}})},_trigger:function(e,i,s){var n,o,a=this.options[e];if(s=s||{},i=t.Event(i),i.type=(e===this.widgetEventPrefix?e:this.widgetEventPrefix+e).toLowerCase(),i.target=this.element[0],o=i.originalEvent)for(n in o)n in i||(i[n]=o[n]);return this.element.trigger(i,s),!(t.isFunction(a)&&a.apply(this.element[0],[i].concat(s))===!1||i.isDefaultPrevented())}},t.each({show:"fadeIn",hide:"fadeOut"},function(e,i){t.Widget.prototype["_"+e]=function(s,n,o){"string"==typeof n&&(n={effect:n});var a,r=n?n===!0||"number"==typeof n?i:n.effect||i:e;n=n||{},"number"==typeof n&&(n={duration:n}),a=!t.isEmptyObject(n),n.complete=o,n.delay&&s.delay(n.delay),a&&t.effects&&t.effects.effect[r]?s[e](n):r!==e&&s[r]?s[r](n.duration,n.easing,o):s.queue(function(i){t(this)[e](),o&&o.call(s[0]),i()})}}),t.widget,function(){function e(t,e,i){return[parseFloat(t[0])*(u.test(t[0])?e/100:1),parseFloat(t[1])*(u.test(t[1])?i/100:1)]}function i(e,i){return parseInt(t.css(e,i),10)||0}function s(e){var i=e[0];return 9===i.nodeType?{width:e.width(),height:e.height(),offset:{top:0,left:0}}:t.isWindow(i)?{width:e.width(),height:e.height(),offset:{top:e.scrollTop(),left:e.scrollLeft()}}:i.preventDefault?{width:0,height:0,offset:{top:i.pageY,left:i.pageX}}:{width:e.outerWidth(),height:e.outerHeight(),offset:e.offset()}}var n,o=Math.max,a=Math.abs,r=/left|center|right/,h=/top|center|bottom/,l=/[\+\-]\d+(\.[\d]+)?%?/,c=/^\w+/,u=/%$/,d=t.fn.position;t.position={scrollbarWidth:function(){if(void 0!==n)return n;var e,i,s=t("
"),o=s.children()[0];return t("body").append(s),e=o.offsetWidth,s.css("overflow","scroll"),i=o.offsetWidth,e===i&&(i=s[0].clientWidth),s.remove(),n=e-i},getScrollInfo:function(e){var i=e.isWindow||e.isDocument?"":e.element.css("overflow-x"),s=e.isWindow||e.isDocument?"":e.element.css("overflow-y"),n="scroll"===i||"auto"===i&&e.widthi?"left":e>0?"right":"center",vertical:0>r?"top":s>0?"bottom":"middle"};l>p&&p>a(e+i)&&(u.horizontal="center"),c>f&&f>a(s+r)&&(u.vertical="middle"),u.important=o(a(e),a(i))>o(a(s),a(r))?"horizontal":"vertical",n.using.call(this,t,u)}),h.offset(t.extend(D,{using:r}))})},t.ui.position={fit:{left:function(t,e){var i,s=e.within,n=s.isWindow?s.scrollLeft:s.offset.left,a=s.width,r=t.left-e.collisionPosition.marginLeft,h=n-r,l=r+e.collisionWidth-a-n;e.collisionWidth>a?h>0&&0>=l?(i=t.left+h+e.collisionWidth-a-n,t.left+=h-i):t.left=l>0&&0>=h?n:h>l?n+a-e.collisionWidth:n:h>0?t.left+=h:l>0?t.left-=l:t.left=o(t.left-r,t.left)},top:function(t,e){var i,s=e.within,n=s.isWindow?s.scrollTop:s.offset.top,a=e.within.height,r=t.top-e.collisionPosition.marginTop,h=n-r,l=r+e.collisionHeight-a-n;e.collisionHeight>a?h>0&&0>=l?(i=t.top+h+e.collisionHeight-a-n,t.top+=h-i):t.top=l>0&&0>=h?n:h>l?n+a-e.collisionHeight:n:h>0?t.top+=h:l>0?t.top-=l:t.top=o(t.top-r,t.top)}},flip:{left:function(t,e){var i,s,n=e.within,o=n.offset.left+n.scrollLeft,r=n.width,h=n.isWindow?n.scrollLeft:n.offset.left,l=t.left-e.collisionPosition.marginLeft,c=l-h,u=l+e.collisionWidth-r-h,d="left"===e.my[0]?-e.elemWidth:"right"===e.my[0]?e.elemWidth:0,p="left"===e.at[0]?e.targetWidth:"right"===e.at[0]?-e.targetWidth:0,f=-2*e.offset[0];0>c?(i=t.left+d+p+f+e.collisionWidth-r-o,(0>i||a(c)>i)&&(t.left+=d+p+f)):u>0&&(s=t.left-e.collisionPosition.marginLeft+d+p+f-h,(s>0||u>a(s))&&(t.left+=d+p+f))},top:function(t,e){var i,s,n=e.within,o=n.offset.top+n.scrollTop,r=n.height,h=n.isWindow?n.scrollTop:n.offset.top,l=t.top-e.collisionPosition.marginTop,c=l-h,u=l+e.collisionHeight-r-h,d="top"===e.my[1],p=d?-e.elemHeight:"bottom"===e.my[1]?e.elemHeight:0,f="top"===e.at[1]?e.targetHeight:"bottom"===e.at[1]?-e.targetHeight:0,g=-2*e.offset[1];0>c?(s=t.top+p+f+g+e.collisionHeight-r-o,(0>s||a(c)>s)&&(t.top+=p+f+g)):u>0&&(i=t.top-e.collisionPosition.marginTop+p+f+g-h,(i>0||u>a(i))&&(t.top+=p+f+g))}},flipfit:{left:function(){t.ui.position.flip.left.apply(this,arguments),t.ui.position.fit.left.apply(this,arguments)},top:function(){t.ui.position.flip.top.apply(this,arguments),t.ui.position.fit.top.apply(this,arguments)}}}}(),t.ui.position,t.extend(t.expr[":"],{data:t.expr.createPseudo?t.expr.createPseudo(function(e){return function(i){return!!t.data(i,e)}}):function(e,i,s){return!!t.data(e,s[3])}}),t.fn.extend({disableSelection:function(){var t="onselectstart"in document.createElement("div")?"selectstart":"mousedown";return function(){return this.on(t+".ui-disableSelection",function(t){t.preventDefault()})}}(),enableSelection:function(){return this.off(".ui-disableSelection")}});var c="ui-effects-",u="ui-effects-style",d="ui-effects-animated",p=t;t.effects={effect:{}},function(t,e){function i(t,e,i){var s=u[e.type]||{};return null==t?i||!e.def?null:e.def:(t=s.floor?~~t:parseFloat(t),isNaN(t)?e.def:s.mod?(t+s.mod)%s.mod:0>t?0:t>s.max?s.max:t)}function s(i){var s=l(),n=s._rgba=[];return i=i.toLowerCase(),f(h,function(t,o){var a,r=o.re.exec(i),h=r&&o.parse(r),l=o.space||"rgba";return h?(a=s[l](h),s[c[l].cache]=a[c[l].cache],n=s._rgba=a._rgba,!1):e}),n.length?("0,0,0,0"===n.join()&&t.extend(n,o.transparent),s):o[i]}function n(t,e,i){return i=(i+1)%1,1>6*i?t+6*(e-t)*i:1>2*i?e:2>3*i?t+6*(e-t)*(2/3-i):t}var o,a="backgroundColor borderBottomColor borderLeftColor borderRightColor borderTopColor color columnRuleColor outlineColor textDecorationColor textEmphasisColor",r=/^([\-+])=\s*(\d+\.?\d*)/,h=[{re:/rgba?\(\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d{1,3})\s*(?:,\s*(\d?(?:\.\d+)?)\s*)?\)/,parse:function(t){return[t[1],t[2],t[3],t[4]]}},{re:/rgba?\(\s*(\d+(?:\.\d+)?)\%\s*,\s*(\d+(?:\.\d+)?)\%\s*,\s*(\d+(?:\.\d+)?)\%\s*(?:,\s*(\d?(?:\.\d+)?)\s*)?\)/,parse:function(t){return[2.55*t[1],2.55*t[2],2.55*t[3],t[4]]}},{re:/#([a-f0-9]{2})([a-f0-9]{2})([a-f0-9]{2})/,parse:function(t){return[parseInt(t[1],16),parseInt(t[2],16),parseInt(t[3],16)]}},{re:/#([a-f0-9])([a-f0-9])([a-f0-9])/,parse:function(t){return[parseInt(t[1]+t[1],16),parseInt(t[2]+t[2],16),parseInt(t[3]+t[3],16)]}},{re:/hsla?\(\s*(\d+(?:\.\d+)?)\s*,\s*(\d+(?:\.\d+)?)\%\s*,\s*(\d+(?:\.\d+)?)\%\s*(?:,\s*(\d?(?:\.\d+)?)\s*)?\)/,space:"hsla",parse:function(t){return[t[1],t[2]/100,t[3]/100,t[4]]}}],l=t.Color=function(e,i,s,n){return new t.Color.fn.parse(e,i,s,n)},c={rgba:{props:{red:{idx:0,type:"byte"},green:{idx:1,type:"byte"},blue:{idx:2,type:"byte"}}},hsla:{props:{hue:{idx:0,type:"degrees"},saturation:{idx:1,type:"percent"},lightness:{idx:2,type:"percent"}}}},u={"byte":{floor:!0,max:255},percent:{max:1},degrees:{mod:360,floor:!0}},d=l.support={},p=t("

")[0],f=t.each;p.style.cssText="background-color:rgba(1,1,1,.5)",d.rgba=p.style.backgroundColor.indexOf("rgba")>-1,f(c,function(t,e){e.cache="_"+t,e.props.alpha={idx:3,type:"percent",def:1}}),l.fn=t.extend(l.prototype,{parse:function(n,a,r,h){if(n===e)return this._rgba=[null,null,null,null],this;(n.jquery||n.nodeType)&&(n=t(n).css(a),a=e);var u=this,d=t.type(n),p=this._rgba=[];return a!==e&&(n=[n,a,r,h],d="array"),"string"===d?this.parse(s(n)||o._default):"array"===d?(f(c.rgba.props,function(t,e){p[e.idx]=i(n[e.idx],e)}),this):"object"===d?(n instanceof l?f(c,function(t,e){n[e.cache]&&(u[e.cache]=n[e.cache].slice())}):f(c,function(e,s){var o=s.cache;f(s.props,function(t,e){if(!u[o]&&s.to){if("alpha"===t||null==n[t])return;u[o]=s.to(u._rgba)}u[o][e.idx]=i(n[t],e,!0)}),u[o]&&0>t.inArray(null,u[o].slice(0,3))&&(u[o][3]=1,s.from&&(u._rgba=s.from(u[o])))}),this):e},is:function(t){var i=l(t),s=!0,n=this;return f(c,function(t,o){var a,r=i[o.cache];return r&&(a=n[o.cache]||o.to&&o.to(n._rgba)||[],f(o.props,function(t,i){return null!=r[i.idx]?s=r[i.idx]===a[i.idx]:e})),s}),s},_space:function(){var t=[],e=this;return f(c,function(i,s){e[s.cache]&&t.push(i)}),t.pop()},transition:function(t,e){var s=l(t),n=s._space(),o=c[n],a=0===this.alpha()?l("transparent"):this,r=a[o.cache]||o.to(a._rgba),h=r.slice();return s=s[o.cache],f(o.props,function(t,n){var o=n.idx,a=r[o],l=s[o],c=u[n.type]||{};null!==l&&(null===a?h[o]=l:(c.mod&&(l-a>c.mod/2?a+=c.mod:a-l>c.mod/2&&(a-=c.mod)),h[o]=i((l-a)*e+a,n)))}),this[n](h)},blend:function(e){if(1===this._rgba[3])return this;var i=this._rgba.slice(),s=i.pop(),n=l(e)._rgba;return l(t.map(i,function(t,e){return(1-s)*n[e]+s*t}))},toRgbaString:function(){var e="rgba(",i=t.map(this._rgba,function(t,e){return null==t?e>2?1:0:t});return 1===i[3]&&(i.pop(),e="rgb("),e+i.join()+")"},toHslaString:function(){var e="hsla(",i=t.map(this.hsla(),function(t,e){return null==t&&(t=e>2?1:0),e&&3>e&&(t=Math.round(100*t)+"%"),t});return 1===i[3]&&(i.pop(),e="hsl("),e+i.join()+")"},toHexString:function(e){var i=this._rgba.slice(),s=i.pop();return e&&i.push(~~(255*s)),"#"+t.map(i,function(t){return t=(t||0).toString(16),1===t.length?"0"+t:t}).join("")},toString:function(){return 0===this._rgba[3]?"transparent":this.toRgbaString()}}),l.fn.parse.prototype=l.fn,c.hsla.to=function(t){if(null==t[0]||null==t[1]||null==t[2])return[null,null,null,t[3]];var e,i,s=t[0]/255,n=t[1]/255,o=t[2]/255,a=t[3],r=Math.max(s,n,o),h=Math.min(s,n,o),l=r-h,c=r+h,u=.5*c;return e=h===r?0:s===r?60*(n-o)/l+360:n===r?60*(o-s)/l+120:60*(s-n)/l+240,i=0===l?0:.5>=u?l/c:l/(2-c),[Math.round(e)%360,i,u,null==a?1:a]},c.hsla.from=function(t){if(null==t[0]||null==t[1]||null==t[2])return[null,null,null,t[3]];var e=t[0]/360,i=t[1],s=t[2],o=t[3],a=.5>=s?s*(1+i):s+i-s*i,r=2*s-a;return[Math.round(255*n(r,a,e+1/3)),Math.round(255*n(r,a,e)),Math.round(255*n(r,a,e-1/3)),o]},f(c,function(s,n){var o=n.props,a=n.cache,h=n.to,c=n.from;l.fn[s]=function(s){if(h&&!this[a]&&(this[a]=h(this._rgba)),s===e)return this[a].slice();var n,r=t.type(s),u="array"===r||"object"===r?s:arguments,d=this[a].slice();return f(o,function(t,e){var s=u["object"===r?t:e.idx];null==s&&(s=d[e.idx]),d[e.idx]=i(s,e)}),c?(n=l(c(d)),n[a]=d,n):l(d)},f(o,function(e,i){l.fn[e]||(l.fn[e]=function(n){var o,a=t.type(n),h="alpha"===e?this._hsla?"hsla":"rgba":s,l=this[h](),c=l[i.idx];return"undefined"===a?c:("function"===a&&(n=n.call(this,c),a=t.type(n)),null==n&&i.empty?this:("string"===a&&(o=r.exec(n),o&&(n=c+parseFloat(o[2])*("+"===o[1]?1:-1))),l[i.idx]=n,this[h](l)))})})}),l.hook=function(e){var i=e.split(" ");f(i,function(e,i){t.cssHooks[i]={set:function(e,n){var o,a,r="";if("transparent"!==n&&("string"!==t.type(n)||(o=s(n)))){if(n=l(o||n),!d.rgba&&1!==n._rgba[3]){for(a="backgroundColor"===i?e.parentNode:e;(""===r||"transparent"===r)&&a&&a.style;)try{r=t.css(a,"backgroundColor"),a=a.parentNode}catch(h){}n=n.blend(r&&"transparent"!==r?r:"_default")}n=n.toRgbaString()}try{e.style[i]=n}catch(h){}}},t.fx.step[i]=function(e){e.colorInit||(e.start=l(e.elem,i),e.end=l(e.end),e.colorInit=!0),t.cssHooks[i].set(e.elem,e.start.transition(e.end,e.pos))}})},l.hook(a),t.cssHooks.borderColor={expand:function(t){var e={};return f(["Top","Right","Bottom","Left"],function(i,s){e["border"+s+"Color"]=t}),e}},o=t.Color.names={aqua:"#00ffff",black:"#000000",blue:"#0000ff",fuchsia:"#ff00ff",gray:"#808080",green:"#008000",lime:"#00ff00",maroon:"#800000",navy:"#000080",olive:"#808000",purple:"#800080",red:"#ff0000",silver:"#c0c0c0",teal:"#008080",white:"#ffffff",yellow:"#ffff00",transparent:[null,null,null,0],_default:"#ffffff"}}(p),function(){function e(e){var i,s,n=e.ownerDocument.defaultView?e.ownerDocument.defaultView.getComputedStyle(e,null):e.currentStyle,o={};if(n&&n.length&&n[0]&&n[n[0]])for(s=n.length;s--;)i=n[s],"string"==typeof n[i]&&(o[t.camelCase(i)]=n[i]);else for(i in n)"string"==typeof n[i]&&(o[i]=n[i]);return o}function i(e,i){var s,o,a={};for(s in i)o=i[s],e[s]!==o&&(n[s]||(t.fx.step[s]||!isNaN(parseFloat(o)))&&(a[s]=o));return a}var s=["add","remove","toggle"],n={border:1,borderBottom:1,borderColor:1,borderLeft:1,borderRight:1,borderTop:1,borderWidth:1,margin:1,padding:1};t.each(["borderLeftStyle","borderRightStyle","borderBottomStyle","borderTopStyle"],function(e,i){t.fx.step[i]=function(t){("none"!==t.end&&!t.setAttr||1===t.pos&&!t.setAttr)&&(p.style(t.elem,i,t.end),t.setAttr=!0)}}),t.fn.addBack||(t.fn.addBack=function(t){return this.add(null==t?this.prevObject:this.prevObject.filter(t))}),t.effects.animateClass=function(n,o,a,r){var h=t.speed(o,a,r);return this.queue(function(){var o,a=t(this),r=a.attr("class")||"",l=h.children?a.find("*").addBack():a;l=l.map(function(){var i=t(this);return{el:i,start:e(this)}}),o=function(){t.each(s,function(t,e){n[e]&&a[e+"Class"](n[e])})},o(),l=l.map(function(){return this.end=e(this.el[0]),this.diff=i(this.start,this.end),this}),a.attr("class",r),l=l.map(function(){var e=this,i=t.Deferred(),s=t.extend({},h,{queue:!1,complete:function(){i.resolve(e)}});return this.el.animate(this.diff,s),i.promise()}),t.when.apply(t,l.get()).done(function(){o(),t.each(arguments,function(){var e=this.el;t.each(this.diff,function(t){e.css(t,"")})}),h.complete.call(a[0])})})},t.fn.extend({addClass:function(e){return function(i,s,n,o){return s?t.effects.animateClass.call(this,{add:i},s,n,o):e.apply(this,arguments)}}(t.fn.addClass),removeClass:function(e){return function(i,s,n,o){return arguments.length>1?t.effects.animateClass.call(this,{remove:i},s,n,o):e.apply(this,arguments)}}(t.fn.removeClass),toggleClass:function(e){return function(i,s,n,o,a){return"boolean"==typeof s||void 0===s?n?t.effects.animateClass.call(this,s?{add:i}:{remove:i},n,o,a):e.apply(this,arguments):t.effects.animateClass.call(this,{toggle:i},s,n,o)}}(t.fn.toggleClass),switchClass:function(e,i,s,n,o){return t.effects.animateClass.call(this,{add:i,remove:e},s,n,o)}})}(),function(){function e(e,i,s,n){return t.isPlainObject(e)&&(i=e,e=e.effect),e={effect:e},null==i&&(i={}),t.isFunction(i)&&(n=i,s=null,i={}),("number"==typeof i||t.fx.speeds[i])&&(n=s,s=i,i={}),t.isFunction(s)&&(n=s,s=null),i&&t.extend(e,i),s=s||i.duration,e.duration=t.fx.off?0:"number"==typeof s?s:s in t.fx.speeds?t.fx.speeds[s]:t.fx.speeds._default,e.complete=n||i.complete,e}function i(e){return!e||"number"==typeof e||t.fx.speeds[e]?!0:"string"!=typeof e||t.effects.effect[e]?t.isFunction(e)?!0:"object"!=typeof e||e.effect?!1:!0:!0}function s(t,e){var i=e.outerWidth(),s=e.outerHeight(),n=/^rect\((-?\d*\.?\d*px|-?\d+%|auto),?\s*(-?\d*\.?\d*px|-?\d+%|auto),?\s*(-?\d*\.?\d*px|-?\d+%|auto),?\s*(-?\d*\.?\d*px|-?\d+%|auto)\)$/,o=n.exec(t)||["",0,i,s,0];return{top:parseFloat(o[1])||0,right:"auto"===o[2]?i:parseFloat(o[2]),bottom:"auto"===o[3]?s:parseFloat(o[3]),left:parseFloat(o[4])||0}}t.expr&&t.expr.filters&&t.expr.filters.animated&&(t.expr.filters.animated=function(e){return function(i){return!!t(i).data(d)||e(i)}}(t.expr.filters.animated)),t.uiBackCompat!==!1&&t.extend(t.effects,{save:function(t,e){for(var i=0,s=e.length;s>i;i++)null!==e[i]&&t.data(c+e[i],t[0].style[e[i]])},restore:function(t,e){for(var i,s=0,n=e.length;n>s;s++)null!==e[s]&&(i=t.data(c+e[s]),t.css(e[s],i))},setMode:function(t,e){return"toggle"===e&&(e=t.is(":hidden")?"show":"hide"),e},createWrapper:function(e){if(e.parent().is(".ui-effects-wrapper"))return e.parent();var i={width:e.outerWidth(!0),height:e.outerHeight(!0),"float":e.css("float")},s=t("

").addClass("ui-effects-wrapper").css({fontSize:"100%",background:"transparent",border:"none",margin:0,padding:0}),n={width:e.width(),height:e.height()},o=document.activeElement;try{o.id}catch(a){o=document.body}return e.wrap(s),(e[0]===o||t.contains(e[0],o))&&t(o).trigger("focus"),s=e.parent(),"static"===e.css("position")?(s.css({position:"relative"}),e.css({position:"relative"})):(t.extend(i,{position:e.css("position"),zIndex:e.css("z-index")}),t.each(["top","left","bottom","right"],function(t,s){i[s]=e.css(s),isNaN(parseInt(i[s],10))&&(i[s]="auto")}),e.css({position:"relative",top:0,left:0,right:"auto",bottom:"auto"})),e.css(n),s.css(i).show()},removeWrapper:function(e){var i=document.activeElement;return e.parent().is(".ui-effects-wrapper")&&(e.parent().replaceWith(e),(e[0]===i||t.contains(e[0],i))&&t(i).trigger("focus")),e}}),t.extend(t.effects,{version:"1.12.1",define:function(e,i,s){return s||(s=i,i="effect"),t.effects.effect[e]=s,t.effects.effect[e].mode=i,s},scaledDimensions:function(t,e,i){if(0===e)return{height:0,width:0,outerHeight:0,outerWidth:0};var s="horizontal"!==i?(e||100)/100:1,n="vertical"!==i?(e||100)/100:1;return{height:t.height()*n,width:t.width()*s,outerHeight:t.outerHeight()*n,outerWidth:t.outerWidth()*s}},clipToBox:function(t){return{width:t.clip.right-t.clip.left,height:t.clip.bottom-t.clip.top,left:t.clip.left,top:t.clip.top}},unshift:function(t,e,i){var s=t.queue();e>1&&s.splice.apply(s,[1,0].concat(s.splice(e,i))),t.dequeue()},saveStyle:function(t){t.data(u,t[0].style.cssText)},restoreStyle:function(t){t[0].style.cssText=t.data(u)||"",t.removeData(u)},mode:function(t,e){var i=t.is(":hidden");return"toggle"===e&&(e=i?"show":"hide"),(i?"hide"===e:"show"===e)&&(e="none"),e},getBaseline:function(t,e){var i,s;switch(t[0]){case"top":i=0;break;case"middle":i=.5;break;case"bottom":i=1;break;default:i=t[0]/e.height}switch(t[1]){case"left":s=0;break;case"center":s=.5;break;case"right":s=1;break;default:s=t[1]/e.width}return{x:s,y:i}},createPlaceholder:function(e){var i,s=e.css("position"),n=e.position();return e.css({marginTop:e.css("marginTop"),marginBottom:e.css("marginBottom"),marginLeft:e.css("marginLeft"),marginRight:e.css("marginRight")}).outerWidth(e.outerWidth()).outerHeight(e.outerHeight()),/^(static|relative)/.test(s)&&(s="absolute",i=t("<"+e[0].nodeName+">").insertAfter(e).css({display:/^(inline|ruby)/.test(e.css("display"))?"inline-block":"block",visibility:"hidden",marginTop:e.css("marginTop"),marginBottom:e.css("marginBottom"),marginLeft:e.css("marginLeft"),marginRight:e.css("marginRight"),"float":e.css("float")}).outerWidth(e.outerWidth()).outerHeight(e.outerHeight()).addClass("ui-effects-placeholder"),e.data(c+"placeholder",i)),e.css({position:s,left:n.left,top:n.top}),i},removePlaceholder:function(t){var e=c+"placeholder",i=t.data(e);i&&(i.remove(),t.removeData(e))},cleanUp:function(e){t.effects.restoreStyle(e),t.effects.removePlaceholder(e)},setTransition:function(e,i,s,n){return n=n||{},t.each(i,function(t,i){var o=e.cssUnit(i);o[0]>0&&(n[i]=o[0]*s+o[1])}),n}}),t.fn.extend({effect:function(){function i(e){function i(){r.removeData(d),t.effects.cleanUp(r),"hide"===s.mode&&r.hide(),a()}function a(){t.isFunction(h)&&h.call(r[0]),t.isFunction(e)&&e()}var r=t(this);s.mode=c.shift(),t.uiBackCompat===!1||o?"none"===s.mode?(r[l](),a()):n.call(r[0],s,i):(r.is(":hidden")?"hide"===l:"show"===l)?(r[l](),a()):n.call(r[0],s,a)}var s=e.apply(this,arguments),n=t.effects.effect[s.effect],o=n.mode,a=s.queue,r=a||"fx",h=s.complete,l=s.mode,c=[],u=function(e){var i=t(this),s=t.effects.mode(i,l)||o;i.data(d,!0),c.push(s),o&&("show"===s||s===o&&"hide"===s)&&i.show(),o&&"none"===s||t.effects.saveStyle(i),t.isFunction(e)&&e()};return t.fx.off||!n?l?this[l](s.duration,h):this.each(function(){h&&h.call(this)}):a===!1?this.each(u).each(i):this.queue(r,u).queue(r,i)},show:function(t){return function(s){if(i(s))return t.apply(this,arguments);var n=e.apply(this,arguments);return n.mode="show",this.effect.call(this,n) +}}(t.fn.show),hide:function(t){return function(s){if(i(s))return t.apply(this,arguments);var n=e.apply(this,arguments);return n.mode="hide",this.effect.call(this,n)}}(t.fn.hide),toggle:function(t){return function(s){if(i(s)||"boolean"==typeof s)return t.apply(this,arguments);var n=e.apply(this,arguments);return n.mode="toggle",this.effect.call(this,n)}}(t.fn.toggle),cssUnit:function(e){var i=this.css(e),s=[];return t.each(["em","px","%","pt"],function(t,e){i.indexOf(e)>0&&(s=[parseFloat(i),e])}),s},cssClip:function(t){return t?this.css("clip","rect("+t.top+"px "+t.right+"px "+t.bottom+"px "+t.left+"px)"):s(this.css("clip"),this)},transfer:function(e,i){var s=t(this),n=t(e.to),o="fixed"===n.css("position"),a=t("body"),r=o?a.scrollTop():0,h=o?a.scrollLeft():0,l=n.offset(),c={top:l.top-r,left:l.left-h,height:n.innerHeight(),width:n.innerWidth()},u=s.offset(),d=t("
").appendTo("body").addClass(e.className).css({top:u.top-r,left:u.left-h,height:s.innerHeight(),width:s.innerWidth(),position:o?"fixed":"absolute"}).animate(c,e.duration,e.easing,function(){d.remove(),t.isFunction(i)&&i()})}}),t.fx.step.clip=function(e){e.clipInit||(e.start=t(e.elem).cssClip(),"string"==typeof e.end&&(e.end=s(e.end,e.elem)),e.clipInit=!0),t(e.elem).cssClip({top:e.pos*(e.end.top-e.start.top)+e.start.top,right:e.pos*(e.end.right-e.start.right)+e.start.right,bottom:e.pos*(e.end.bottom-e.start.bottom)+e.start.bottom,left:e.pos*(e.end.left-e.start.left)+e.start.left})}}(),function(){var e={};t.each(["Quad","Cubic","Quart","Quint","Expo"],function(t,i){e[i]=function(e){return Math.pow(e,t+2)}}),t.extend(e,{Sine:function(t){return 1-Math.cos(t*Math.PI/2)},Circ:function(t){return 1-Math.sqrt(1-t*t)},Elastic:function(t){return 0===t||1===t?t:-Math.pow(2,8*(t-1))*Math.sin((80*(t-1)-7.5)*Math.PI/15)},Back:function(t){return t*t*(3*t-2)},Bounce:function(t){for(var e,i=4;((e=Math.pow(2,--i))-1)/11>t;);return 1/Math.pow(4,3-i)-7.5625*Math.pow((3*e-2)/22-t,2)}}),t.each(e,function(e,i){t.easing["easeIn"+e]=i,t.easing["easeOut"+e]=function(t){return 1-i(1-t)},t.easing["easeInOut"+e]=function(t){return.5>t?i(2*t)/2:1-i(-2*t+2)/2}})}();var f=t.effects;t.effects.define("blind","hide",function(e,i){var s={up:["bottom","top"],vertical:["bottom","top"],down:["top","bottom"],left:["right","left"],horizontal:["right","left"],right:["left","right"]},n=t(this),o=e.direction||"up",a=n.cssClip(),r={clip:t.extend({},a)},h=t.effects.createPlaceholder(n);r.clip[s[o][0]]=r.clip[s[o][1]],"show"===e.mode&&(n.cssClip(r.clip),h&&h.css(t.effects.clipToBox(r)),r.clip=a),h&&h.animate(t.effects.clipToBox(r),e.duration,e.easing),n.animate(r,{queue:!1,duration:e.duration,easing:e.easing,complete:i})}),t.effects.define("bounce",function(e,i){var s,n,o,a=t(this),r=e.mode,h="hide"===r,l="show"===r,c=e.direction||"up",u=e.distance,d=e.times||5,p=2*d+(l||h?1:0),f=e.duration/p,g=e.easing,m="up"===c||"down"===c?"top":"left",_="up"===c||"left"===c,v=0,b=a.queue().length;for(t.effects.createPlaceholder(a),o=a.css(m),u||(u=a["top"===m?"outerHeight":"outerWidth"]()/3),l&&(n={opacity:1},n[m]=o,a.css("opacity",0).css(m,_?2*-u:2*u).animate(n,f,g)),h&&(u/=Math.pow(2,d-1)),n={},n[m]=o;d>v;v++)s={},s[m]=(_?"-=":"+=")+u,a.animate(s,f,g).animate(n,f,g),u=h?2*u:u/2;h&&(s={opacity:0},s[m]=(_?"-=":"+=")+u,a.animate(s,f,g)),a.queue(i),t.effects.unshift(a,b,p+1)}),t.effects.define("clip","hide",function(e,i){var s,n={},o=t(this),a=e.direction||"vertical",r="both"===a,h=r||"horizontal"===a,l=r||"vertical"===a;s=o.cssClip(),n.clip={top:l?(s.bottom-s.top)/2:s.top,right:h?(s.right-s.left)/2:s.right,bottom:l?(s.bottom-s.top)/2:s.bottom,left:h?(s.right-s.left)/2:s.left},t.effects.createPlaceholder(o),"show"===e.mode&&(o.cssClip(n.clip),n.clip=s),o.animate(n,{queue:!1,duration:e.duration,easing:e.easing,complete:i})}),t.effects.define("drop","hide",function(e,i){var s,n=t(this),o=e.mode,a="show"===o,r=e.direction||"left",h="up"===r||"down"===r?"top":"left",l="up"===r||"left"===r?"-=":"+=",c="+="===l?"-=":"+=",u={opacity:0};t.effects.createPlaceholder(n),s=e.distance||n["top"===h?"outerHeight":"outerWidth"](!0)/2,u[h]=l+s,a&&(n.css(u),u[h]=c+s,u.opacity=1),n.animate(u,{queue:!1,duration:e.duration,easing:e.easing,complete:i})}),t.effects.define("explode","hide",function(e,i){function s(){b.push(this),b.length===u*d&&n()}function n(){p.css({visibility:"visible"}),t(b).remove(),i()}var o,a,r,h,l,c,u=e.pieces?Math.round(Math.sqrt(e.pieces)):3,d=u,p=t(this),f=e.mode,g="show"===f,m=p.show().css("visibility","hidden").offset(),_=Math.ceil(p.outerWidth()/d),v=Math.ceil(p.outerHeight()/u),b=[];for(o=0;u>o;o++)for(h=m.top+o*v,c=o-(u-1)/2,a=0;d>a;a++)r=m.left+a*_,l=a-(d-1)/2,p.clone().appendTo("body").wrap("
").css({position:"absolute",visibility:"visible",left:-a*_,top:-o*v}).parent().addClass("ui-effects-explode").css({position:"absolute",overflow:"hidden",width:_,height:v,left:r+(g?l*_:0),top:h+(g?c*v:0),opacity:g?0:1}).animate({left:r+(g?0:l*_),top:h+(g?0:c*v),opacity:g?1:0},e.duration||500,e.easing,s)}),t.effects.define("fade","toggle",function(e,i){var s="show"===e.mode;t(this).css("opacity",s?0:1).animate({opacity:s?1:0},{queue:!1,duration:e.duration,easing:e.easing,complete:i})}),t.effects.define("fold","hide",function(e,i){var s=t(this),n=e.mode,o="show"===n,a="hide"===n,r=e.size||15,h=/([0-9]+)%/.exec(r),l=!!e.horizFirst,c=l?["right","bottom"]:["bottom","right"],u=e.duration/2,d=t.effects.createPlaceholder(s),p=s.cssClip(),f={clip:t.extend({},p)},g={clip:t.extend({},p)},m=[p[c[0]],p[c[1]]],_=s.queue().length;h&&(r=parseInt(h[1],10)/100*m[a?0:1]),f.clip[c[0]]=r,g.clip[c[0]]=r,g.clip[c[1]]=0,o&&(s.cssClip(g.clip),d&&d.css(t.effects.clipToBox(g)),g.clip=p),s.queue(function(i){d&&d.animate(t.effects.clipToBox(f),u,e.easing).animate(t.effects.clipToBox(g),u,e.easing),i()}).animate(f,u,e.easing).animate(g,u,e.easing).queue(i),t.effects.unshift(s,_,4)}),t.effects.define("highlight","show",function(e,i){var s=t(this),n={backgroundColor:s.css("backgroundColor")};"hide"===e.mode&&(n.opacity=0),t.effects.saveStyle(s),s.css({backgroundImage:"none",backgroundColor:e.color||"#ffff99"}).animate(n,{queue:!1,duration:e.duration,easing:e.easing,complete:i})}),t.effects.define("size",function(e,i){var s,n,o,a=t(this),r=["fontSize"],h=["borderTopWidth","borderBottomWidth","paddingTop","paddingBottom"],l=["borderLeftWidth","borderRightWidth","paddingLeft","paddingRight"],c=e.mode,u="effect"!==c,d=e.scale||"both",p=e.origin||["middle","center"],f=a.css("position"),g=a.position(),m=t.effects.scaledDimensions(a),_=e.from||m,v=e.to||t.effects.scaledDimensions(a,0);t.effects.createPlaceholder(a),"show"===c&&(o=_,_=v,v=o),n={from:{y:_.height/m.height,x:_.width/m.width},to:{y:v.height/m.height,x:v.width/m.width}},("box"===d||"both"===d)&&(n.from.y!==n.to.y&&(_=t.effects.setTransition(a,h,n.from.y,_),v=t.effects.setTransition(a,h,n.to.y,v)),n.from.x!==n.to.x&&(_=t.effects.setTransition(a,l,n.from.x,_),v=t.effects.setTransition(a,l,n.to.x,v))),("content"===d||"both"===d)&&n.from.y!==n.to.y&&(_=t.effects.setTransition(a,r,n.from.y,_),v=t.effects.setTransition(a,r,n.to.y,v)),p&&(s=t.effects.getBaseline(p,m),_.top=(m.outerHeight-_.outerHeight)*s.y+g.top,_.left=(m.outerWidth-_.outerWidth)*s.x+g.left,v.top=(m.outerHeight-v.outerHeight)*s.y+g.top,v.left=(m.outerWidth-v.outerWidth)*s.x+g.left),a.css(_),("content"===d||"both"===d)&&(h=h.concat(["marginTop","marginBottom"]).concat(r),l=l.concat(["marginLeft","marginRight"]),a.find("*[width]").each(function(){var i=t(this),s=t.effects.scaledDimensions(i),o={height:s.height*n.from.y,width:s.width*n.from.x,outerHeight:s.outerHeight*n.from.y,outerWidth:s.outerWidth*n.from.x},a={height:s.height*n.to.y,width:s.width*n.to.x,outerHeight:s.height*n.to.y,outerWidth:s.width*n.to.x};n.from.y!==n.to.y&&(o=t.effects.setTransition(i,h,n.from.y,o),a=t.effects.setTransition(i,h,n.to.y,a)),n.from.x!==n.to.x&&(o=t.effects.setTransition(i,l,n.from.x,o),a=t.effects.setTransition(i,l,n.to.x,a)),u&&t.effects.saveStyle(i),i.css(o),i.animate(a,e.duration,e.easing,function(){u&&t.effects.restoreStyle(i)})})),a.animate(v,{queue:!1,duration:e.duration,easing:e.easing,complete:function(){var e=a.offset();0===v.opacity&&a.css("opacity",_.opacity),u||(a.css("position","static"===f?"relative":f).offset(e),t.effects.saveStyle(a)),i()}})}),t.effects.define("scale",function(e,i){var s=t(this),n=e.mode,o=parseInt(e.percent,10)||(0===parseInt(e.percent,10)?0:"effect"!==n?0:100),a=t.extend(!0,{from:t.effects.scaledDimensions(s),to:t.effects.scaledDimensions(s,o,e.direction||"both"),origin:e.origin||["middle","center"]},e);e.fade&&(a.from.opacity=1,a.to.opacity=0),t.effects.effect.size.call(this,a,i)}),t.effects.define("puff","hide",function(e,i){var s=t.extend(!0,{},e,{fade:!0,percent:parseInt(e.percent,10)||150});t.effects.effect.scale.call(this,s,i)}),t.effects.define("pulsate","show",function(e,i){var s=t(this),n=e.mode,o="show"===n,a="hide"===n,r=o||a,h=2*(e.times||5)+(r?1:0),l=e.duration/h,c=0,u=1,d=s.queue().length;for((o||!s.is(":visible"))&&(s.css("opacity",0).show(),c=1);h>u;u++)s.animate({opacity:c},l,e.easing),c=1-c;s.animate({opacity:c},l,e.easing),s.queue(i),t.effects.unshift(s,d,h+1)}),t.effects.define("shake",function(e,i){var s=1,n=t(this),o=e.direction||"left",a=e.distance||20,r=e.times||3,h=2*r+1,l=Math.round(e.duration/h),c="up"===o||"down"===o?"top":"left",u="up"===o||"left"===o,d={},p={},f={},g=n.queue().length;for(t.effects.createPlaceholder(n),d[c]=(u?"-=":"+=")+a,p[c]=(u?"+=":"-=")+2*a,f[c]=(u?"-=":"+=")+2*a,n.animate(d,l,e.easing);r>s;s++)n.animate(p,l,e.easing).animate(f,l,e.easing);n.animate(p,l,e.easing).animate(d,l/2,e.easing).queue(i),t.effects.unshift(n,g,h+1)}),t.effects.define("slide","show",function(e,i){var s,n,o=t(this),a={up:["bottom","top"],down:["top","bottom"],left:["right","left"],right:["left","right"]},r=e.mode,h=e.direction||"left",l="up"===h||"down"===h?"top":"left",c="up"===h||"left"===h,u=e.distance||o["top"===l?"outerHeight":"outerWidth"](!0),d={};t.effects.createPlaceholder(o),s=o.cssClip(),n=o.position()[l],d[l]=(c?-1:1)*u+n,d.clip=o.cssClip(),d.clip[a[h][1]]=d.clip[a[h][0]],"show"===r&&(o.cssClip(d.clip),o.css(l,d[l]),d.clip=s,d[l]=n),o.animate(d,{queue:!1,duration:e.duration,easing:e.easing,complete:i})});var f;t.uiBackCompat!==!1&&(f=t.effects.define("transfer",function(e,i){t(this).transfer(e,i)})),t.ui.focusable=function(i,s){var n,o,a,r,h,l=i.nodeName.toLowerCase();return"area"===l?(n=i.parentNode,o=n.name,i.href&&o&&"map"===n.nodeName.toLowerCase()?(a=t("img[usemap='#"+o+"']"),a.length>0&&a.is(":visible")):!1):(/^(input|select|textarea|button|object)$/.test(l)?(r=!i.disabled,r&&(h=t(i).closest("fieldset")[0],h&&(r=!h.disabled))):r="a"===l?i.href||s:s,r&&t(i).is(":visible")&&e(t(i)))},t.extend(t.expr[":"],{focusable:function(e){return t.ui.focusable(e,null!=t.attr(e,"tabindex"))}}),t.ui.focusable,t.fn.form=function(){return"string"==typeof this[0].form?this.closest("form"):t(this[0].form)},t.ui.formResetMixin={_formResetHandler:function(){var e=t(this);setTimeout(function(){var i=e.data("ui-form-reset-instances");t.each(i,function(){this.refresh()})})},_bindFormResetHandler:function(){if(this.form=this.element.form(),this.form.length){var t=this.form.data("ui-form-reset-instances")||[];t.length||this.form.on("reset.ui-form-reset",this._formResetHandler),t.push(this),this.form.data("ui-form-reset-instances",t)}},_unbindFormResetHandler:function(){if(this.form.length){var e=this.form.data("ui-form-reset-instances");e.splice(t.inArray(this,e),1),e.length?this.form.data("ui-form-reset-instances",e):this.form.removeData("ui-form-reset-instances").off("reset.ui-form-reset")}}},"1.7"===t.fn.jquery.substring(0,3)&&(t.each(["Width","Height"],function(e,i){function s(e,i,s,o){return t.each(n,function(){i-=parseFloat(t.css(e,"padding"+this))||0,s&&(i-=parseFloat(t.css(e,"border"+this+"Width"))||0),o&&(i-=parseFloat(t.css(e,"margin"+this))||0)}),i}var n="Width"===i?["Left","Right"]:["Top","Bottom"],o=i.toLowerCase(),a={innerWidth:t.fn.innerWidth,innerHeight:t.fn.innerHeight,outerWidth:t.fn.outerWidth,outerHeight:t.fn.outerHeight};t.fn["inner"+i]=function(e){return void 0===e?a["inner"+i].call(this):this.each(function(){t(this).css(o,s(this,e)+"px")})},t.fn["outer"+i]=function(e,n){return"number"!=typeof e?a["outer"+i].call(this,e):this.each(function(){t(this).css(o,s(this,e,!0,n)+"px")})}}),t.fn.addBack=function(t){return this.add(null==t?this.prevObject:this.prevObject.filter(t))}),t.ui.keyCode={BACKSPACE:8,COMMA:188,DELETE:46,DOWN:40,END:35,ENTER:13,ESCAPE:27,HOME:36,LEFT:37,PAGE_DOWN:34,PAGE_UP:33,PERIOD:190,RIGHT:39,SPACE:32,TAB:9,UP:38},t.ui.escapeSelector=function(){var t=/([!"#$%&'()*+,.\/:;<=>?@[\]^`{|}~])/g;return function(e){return e.replace(t,"\\$1")}}(),t.fn.labels=function(){var e,i,s,n,o;return this[0].labels&&this[0].labels.length?this.pushStack(this[0].labels):(n=this.eq(0).parents("label"),s=this.attr("id"),s&&(e=this.eq(0).parents().last(),o=e.add(e.length?e.siblings():this.siblings()),i="label[for='"+t.ui.escapeSelector(s)+"']",n=n.add(o.find(i).addBack(i))),this.pushStack(n))},t.fn.scrollParent=function(e){var i=this.css("position"),s="absolute"===i,n=e?/(auto|scroll|hidden)/:/(auto|scroll)/,o=this.parents().filter(function(){var e=t(this);return s&&"static"===e.css("position")?!1:n.test(e.css("overflow")+e.css("overflow-y")+e.css("overflow-x"))}).eq(0);return"fixed"!==i&&o.length?o:t(this[0].ownerDocument||document)},t.extend(t.expr[":"],{tabbable:function(e){var i=t.attr(e,"tabindex"),s=null!=i;return(!s||i>=0)&&t.ui.focusable(e,s)}}),t.fn.extend({uniqueId:function(){var t=0;return function(){return this.each(function(){this.id||(this.id="ui-id-"+ ++t)})}}(),removeUniqueId:function(){return this.each(function(){/^ui-id-\d+$/.test(this.id)&&t(this).removeAttr("id")})}}),t.widget("ui.accordion",{version:"1.12.1",options:{active:0,animate:{},classes:{"ui-accordion-header":"ui-corner-top","ui-accordion-header-collapsed":"ui-corner-all","ui-accordion-content":"ui-corner-bottom"},collapsible:!1,event:"click",header:"> li > :first-child, > :not(li):even",heightStyle:"auto",icons:{activeHeader:"ui-icon-triangle-1-s",header:"ui-icon-triangle-1-e"},activate:null,beforeActivate:null},hideProps:{borderTopWidth:"hide",borderBottomWidth:"hide",paddingTop:"hide",paddingBottom:"hide",height:"hide"},showProps:{borderTopWidth:"show",borderBottomWidth:"show",paddingTop:"show",paddingBottom:"show",height:"show"},_create:function(){var e=this.options;this.prevShow=this.prevHide=t(),this._addClass("ui-accordion","ui-widget ui-helper-reset"),this.element.attr("role","tablist"),e.collapsible||e.active!==!1&&null!=e.active||(e.active=0),this._processPanels(),0>e.active&&(e.active+=this.headers.length),this._refresh()},_getCreateEventData:function(){return{header:this.active,panel:this.active.length?this.active.next():t()}},_createIcons:function(){var e,i,s=this.options.icons;s&&(e=t(""),this._addClass(e,"ui-accordion-header-icon","ui-icon "+s.header),e.prependTo(this.headers),i=this.active.children(".ui-accordion-header-icon"),this._removeClass(i,s.header)._addClass(i,null,s.activeHeader)._addClass(this.headers,"ui-accordion-icons"))},_destroyIcons:function(){this._removeClass(this.headers,"ui-accordion-icons"),this.headers.children(".ui-accordion-header-icon").remove()},_destroy:function(){var t;this.element.removeAttr("role"),this.headers.removeAttr("role aria-expanded aria-selected aria-controls tabIndex").removeUniqueId(),this._destroyIcons(),t=this.headers.next().css("display","").removeAttr("role aria-hidden aria-labelledby").removeUniqueId(),"content"!==this.options.heightStyle&&t.css("height","")},_setOption:function(t,e){return"active"===t?(this._activate(e),void 0):("event"===t&&(this.options.event&&this._off(this.headers,this.options.event),this._setupEvents(e)),this._super(t,e),"collapsible"!==t||e||this.options.active!==!1||this._activate(0),"icons"===t&&(this._destroyIcons(),e&&this._createIcons()),void 0)},_setOptionDisabled:function(t){this._super(t),this.element.attr("aria-disabled",t),this._toggleClass(null,"ui-state-disabled",!!t),this._toggleClass(this.headers.add(this.headers.next()),null,"ui-state-disabled",!!t)},_keydown:function(e){if(!e.altKey&&!e.ctrlKey){var i=t.ui.keyCode,s=this.headers.length,n=this.headers.index(e.target),o=!1;switch(e.keyCode){case i.RIGHT:case i.DOWN:o=this.headers[(n+1)%s];break;case i.LEFT:case i.UP:o=this.headers[(n-1+s)%s];break;case i.SPACE:case i.ENTER:this._eventHandler(e);break;case i.HOME:o=this.headers[0];break;case i.END:o=this.headers[s-1]}o&&(t(e.target).attr("tabIndex",-1),t(o).attr("tabIndex",0),t(o).trigger("focus"),e.preventDefault())}},_panelKeyDown:function(e){e.keyCode===t.ui.keyCode.UP&&e.ctrlKey&&t(e.currentTarget).prev().trigger("focus")},refresh:function(){var e=this.options;this._processPanels(),e.active===!1&&e.collapsible===!0||!this.headers.length?(e.active=!1,this.active=t()):e.active===!1?this._activate(0):this.active.length&&!t.contains(this.element[0],this.active[0])?this.headers.length===this.headers.find(".ui-state-disabled").length?(e.active=!1,this.active=t()):this._activate(Math.max(0,e.active-1)):e.active=this.headers.index(this.active),this._destroyIcons(),this._refresh()},_processPanels:function(){var t=this.headers,e=this.panels;this.headers=this.element.find(this.options.header),this._addClass(this.headers,"ui-accordion-header ui-accordion-header-collapsed","ui-state-default"),this.panels=this.headers.next().filter(":not(.ui-accordion-content-active)").hide(),this._addClass(this.panels,"ui-accordion-content","ui-helper-reset ui-widget-content"),e&&(this._off(t.not(this.headers)),this._off(e.not(this.panels)))},_refresh:function(){var e,i=this.options,s=i.heightStyle,n=this.element.parent();this.active=this._findActive(i.active),this._addClass(this.active,"ui-accordion-header-active","ui-state-active")._removeClass(this.active,"ui-accordion-header-collapsed"),this._addClass(this.active.next(),"ui-accordion-content-active"),this.active.next().show(),this.headers.attr("role","tab").each(function(){var e=t(this),i=e.uniqueId().attr("id"),s=e.next(),n=s.uniqueId().attr("id");e.attr("aria-controls",n),s.attr("aria-labelledby",i)}).next().attr("role","tabpanel"),this.headers.not(this.active).attr({"aria-selected":"false","aria-expanded":"false",tabIndex:-1}).next().attr({"aria-hidden":"true"}).hide(),this.active.length?this.active.attr({"aria-selected":"true","aria-expanded":"true",tabIndex:0}).next().attr({"aria-hidden":"false"}):this.headers.eq(0).attr("tabIndex",0),this._createIcons(),this._setupEvents(i.event),"fill"===s?(e=n.height(),this.element.siblings(":visible").each(function(){var i=t(this),s=i.css("position");"absolute"!==s&&"fixed"!==s&&(e-=i.outerHeight(!0))}),this.headers.each(function(){e-=t(this).outerHeight(!0)}),this.headers.next().each(function(){t(this).height(Math.max(0,e-t(this).innerHeight()+t(this).height()))}).css("overflow","auto")):"auto"===s&&(e=0,this.headers.next().each(function(){var i=t(this).is(":visible");i||t(this).show(),e=Math.max(e,t(this).css("height","").height()),i||t(this).hide()}).height(e))},_activate:function(e){var i=this._findActive(e)[0];i!==this.active[0]&&(i=i||this.active[0],this._eventHandler({target:i,currentTarget:i,preventDefault:t.noop}))},_findActive:function(e){return"number"==typeof e?this.headers.eq(e):t()},_setupEvents:function(e){var i={keydown:"_keydown"};e&&t.each(e.split(" "),function(t,e){i[e]="_eventHandler"}),this._off(this.headers.add(this.headers.next())),this._on(this.headers,i),this._on(this.headers.next(),{keydown:"_panelKeyDown"}),this._hoverable(this.headers),this._focusable(this.headers)},_eventHandler:function(e){var i,s,n=this.options,o=this.active,a=t(e.currentTarget),r=a[0]===o[0],h=r&&n.collapsible,l=h?t():a.next(),c=o.next(),u={oldHeader:o,oldPanel:c,newHeader:h?t():a,newPanel:l};e.preventDefault(),r&&!n.collapsible||this._trigger("beforeActivate",e,u)===!1||(n.active=h?!1:this.headers.index(a),this.active=r?t():a,this._toggle(u),this._removeClass(o,"ui-accordion-header-active","ui-state-active"),n.icons&&(i=o.children(".ui-accordion-header-icon"),this._removeClass(i,null,n.icons.activeHeader)._addClass(i,null,n.icons.header)),r||(this._removeClass(a,"ui-accordion-header-collapsed")._addClass(a,"ui-accordion-header-active","ui-state-active"),n.icons&&(s=a.children(".ui-accordion-header-icon"),this._removeClass(s,null,n.icons.header)._addClass(s,null,n.icons.activeHeader)),this._addClass(a.next(),"ui-accordion-content-active")))},_toggle:function(e){var i=e.newPanel,s=this.prevShow.length?this.prevShow:e.oldPanel;this.prevShow.add(this.prevHide).stop(!0,!0),this.prevShow=i,this.prevHide=s,this.options.animate?this._animate(i,s,e):(s.hide(),i.show(),this._toggleComplete(e)),s.attr({"aria-hidden":"true"}),s.prev().attr({"aria-selected":"false","aria-expanded":"false"}),i.length&&s.length?s.prev().attr({tabIndex:-1,"aria-expanded":"false"}):i.length&&this.headers.filter(function(){return 0===parseInt(t(this).attr("tabIndex"),10)}).attr("tabIndex",-1),i.attr("aria-hidden","false").prev().attr({"aria-selected":"true","aria-expanded":"true",tabIndex:0})},_animate:function(t,e,i){var s,n,o,a=this,r=0,h=t.css("box-sizing"),l=t.length&&(!e.length||t.index()",delay:300,options:{icons:{submenu:"ui-icon-caret-1-e"},items:"> *",menus:"ul",position:{my:"left top",at:"right top"},role:"menu",blur:null,focus:null,select:null},_create:function(){this.activeMenu=this.element,this.mouseHandled=!1,this.element.uniqueId().attr({role:this.options.role,tabIndex:0}),this._addClass("ui-menu","ui-widget ui-widget-content"),this._on({"mousedown .ui-menu-item":function(t){t.preventDefault()},"click .ui-menu-item":function(e){var i=t(e.target),s=t(t.ui.safeActiveElement(this.document[0]));!this.mouseHandled&&i.not(".ui-state-disabled").length&&(this.select(e),e.isPropagationStopped()||(this.mouseHandled=!0),i.has(".ui-menu").length?this.expand(e):!this.element.is(":focus")&&s.closest(".ui-menu").length&&(this.element.trigger("focus",[!0]),this.active&&1===this.active.parents(".ui-menu").length&&clearTimeout(this.timer)))},"mouseenter .ui-menu-item":function(e){if(!this.previousFilter){var i=t(e.target).closest(".ui-menu-item"),s=t(e.currentTarget);i[0]===s[0]&&(this._removeClass(s.siblings().children(".ui-state-active"),null,"ui-state-active"),this.focus(e,s))}},mouseleave:"collapseAll","mouseleave .ui-menu":"collapseAll",focus:function(t,e){var i=this.active||this.element.find(this.options.items).eq(0);e||this.focus(t,i)},blur:function(e){this._delay(function(){var i=!t.contains(this.element[0],t.ui.safeActiveElement(this.document[0]));i&&this.collapseAll(e)})},keydown:"_keydown"}),this.refresh(),this._on(this.document,{click:function(t){this._closeOnDocumentClick(t)&&this.collapseAll(t),this.mouseHandled=!1}})},_destroy:function(){var e=this.element.find(".ui-menu-item").removeAttr("role aria-disabled"),i=e.children(".ui-menu-item-wrapper").removeUniqueId().removeAttr("tabIndex role aria-haspopup");this.element.removeAttr("aria-activedescendant").find(".ui-menu").addBack().removeAttr("role aria-labelledby aria-expanded aria-hidden aria-disabled tabIndex").removeUniqueId().show(),i.children().each(function(){var e=t(this);e.data("ui-menu-submenu-caret")&&e.remove()})},_keydown:function(e){var i,s,n,o,a=!0;switch(e.keyCode){case t.ui.keyCode.PAGE_UP:this.previousPage(e);break;case t.ui.keyCode.PAGE_DOWN:this.nextPage(e);break;case t.ui.keyCode.HOME:this._move("first","first",e);break;case t.ui.keyCode.END:this._move("last","last",e);break;case t.ui.keyCode.UP:this.previous(e);break;case t.ui.keyCode.DOWN:this.next(e);break;case t.ui.keyCode.LEFT:this.collapse(e);break;case t.ui.keyCode.RIGHT:this.active&&!this.active.is(".ui-state-disabled")&&this.expand(e);break;case t.ui.keyCode.ENTER:case t.ui.keyCode.SPACE:this._activate(e);break;case t.ui.keyCode.ESCAPE:this.collapse(e);break;default:a=!1,s=this.previousFilter||"",o=!1,n=e.keyCode>=96&&105>=e.keyCode?""+(e.keyCode-96):String.fromCharCode(e.keyCode),clearTimeout(this.filterTimer),n===s?o=!0:n=s+n,i=this._filterMenuItems(n),i=o&&-1!==i.index(this.active.next())?this.active.nextAll(".ui-menu-item"):i,i.length||(n=String.fromCharCode(e.keyCode),i=this._filterMenuItems(n)),i.length?(this.focus(e,i),this.previousFilter=n,this.filterTimer=this._delay(function(){delete this.previousFilter},1e3)):delete this.previousFilter}a&&e.preventDefault()},_activate:function(t){this.active&&!this.active.is(".ui-state-disabled")&&(this.active.children("[aria-haspopup='true']").length?this.expand(t):this.select(t))},refresh:function(){var e,i,s,n,o,a=this,r=this.options.icons.submenu,h=this.element.find(this.options.menus);this._toggleClass("ui-menu-icons",null,!!this.element.find(".ui-icon").length),s=h.filter(":not(.ui-menu)").hide().attr({role:this.options.role,"aria-hidden":"true","aria-expanded":"false"}).each(function(){var e=t(this),i=e.prev(),s=t("").data("ui-menu-submenu-caret",!0);a._addClass(s,"ui-menu-icon","ui-icon "+r),i.attr("aria-haspopup","true").prepend(s),e.attr("aria-labelledby",i.attr("id"))}),this._addClass(s,"ui-menu","ui-widget ui-widget-content ui-front"),e=h.add(this.element),i=e.find(this.options.items),i.not(".ui-menu-item").each(function(){var e=t(this);a._isDivider(e)&&a._addClass(e,"ui-menu-divider","ui-widget-content")}),n=i.not(".ui-menu-item, .ui-menu-divider"),o=n.children().not(".ui-menu").uniqueId().attr({tabIndex:-1,role:this._itemRole()}),this._addClass(n,"ui-menu-item")._addClass(o,"ui-menu-item-wrapper"),i.filter(".ui-state-disabled").attr("aria-disabled","true"),this.active&&!t.contains(this.element[0],this.active[0])&&this.blur()},_itemRole:function(){return{menu:"menuitem",listbox:"option"}[this.options.role]},_setOption:function(t,e){if("icons"===t){var i=this.element.find(".ui-menu-icon");this._removeClass(i,null,this.options.icons.submenu)._addClass(i,null,e.submenu)}this._super(t,e)},_setOptionDisabled:function(t){this._super(t),this.element.attr("aria-disabled",t+""),this._toggleClass(null,"ui-state-disabled",!!t)},focus:function(t,e){var i,s,n;this.blur(t,t&&"focus"===t.type),this._scrollIntoView(e),this.active=e.first(),s=this.active.children(".ui-menu-item-wrapper"),this._addClass(s,null,"ui-state-active"),this.options.role&&this.element.attr("aria-activedescendant",s.attr("id")),n=this.active.parent().closest(".ui-menu-item").children(".ui-menu-item-wrapper"),this._addClass(n,null,"ui-state-active"),t&&"keydown"===t.type?this._close():this.timer=this._delay(function(){this._close()},this.delay),i=e.children(".ui-menu"),i.length&&t&&/^mouse/.test(t.type)&&this._startOpening(i),this.activeMenu=e.parent(),this._trigger("focus",t,{item:e})},_scrollIntoView:function(e){var i,s,n,o,a,r;this._hasScroll()&&(i=parseFloat(t.css(this.activeMenu[0],"borderTopWidth"))||0,s=parseFloat(t.css(this.activeMenu[0],"paddingTop"))||0,n=e.offset().top-this.activeMenu.offset().top-i-s,o=this.activeMenu.scrollTop(),a=this.activeMenu.height(),r=e.outerHeight(),0>n?this.activeMenu.scrollTop(o+n):n+r>a&&this.activeMenu.scrollTop(o+n-a+r))},blur:function(t,e){e||clearTimeout(this.timer),this.active&&(this._removeClass(this.active.children(".ui-menu-item-wrapper"),null,"ui-state-active"),this._trigger("blur",t,{item:this.active}),this.active=null)},_startOpening:function(t){clearTimeout(this.timer),"true"===t.attr("aria-hidden")&&(this.timer=this._delay(function(){this._close(),this._open(t)},this.delay))},_open:function(e){var i=t.extend({of:this.active},this.options.position);clearTimeout(this.timer),this.element.find(".ui-menu").not(e.parents(".ui-menu")).hide().attr("aria-hidden","true"),e.show().removeAttr("aria-hidden").attr("aria-expanded","true").position(i)},collapseAll:function(e,i){clearTimeout(this.timer),this.timer=this._delay(function(){var s=i?this.element:t(e&&e.target).closest(this.element.find(".ui-menu"));s.length||(s=this.element),this._close(s),this.blur(e),this._removeClass(s.find(".ui-state-active"),null,"ui-state-active"),this.activeMenu=s},this.delay)},_close:function(t){t||(t=this.active?this.active.parent():this.element),t.find(".ui-menu").hide().attr("aria-hidden","true").attr("aria-expanded","false")},_closeOnDocumentClick:function(e){return!t(e.target).closest(".ui-menu").length},_isDivider:function(t){return!/[^\-\u2014\u2013\s]/.test(t.text())},collapse:function(t){var e=this.active&&this.active.parent().closest(".ui-menu-item",this.element);e&&e.length&&(this._close(),this.focus(t,e))},expand:function(t){var e=this.active&&this.active.children(".ui-menu ").find(this.options.items).first();e&&e.length&&(this._open(e.parent()),this._delay(function(){this.focus(t,e)}))},next:function(t){this._move("next","first",t)},previous:function(t){this._move("prev","last",t)},isFirstItem:function(){return this.active&&!this.active.prevAll(".ui-menu-item").length},isLastItem:function(){return this.active&&!this.active.nextAll(".ui-menu-item").length},_move:function(t,e,i){var s;this.active&&(s="first"===t||"last"===t?this.active["first"===t?"prevAll":"nextAll"](".ui-menu-item").eq(-1):this.active[t+"All"](".ui-menu-item").eq(0)),s&&s.length&&this.active||(s=this.activeMenu.find(this.options.items)[e]()),this.focus(i,s)},nextPage:function(e){var i,s,n;return this.active?(this.isLastItem()||(this._hasScroll()?(s=this.active.offset().top,n=this.element.height(),this.active.nextAll(".ui-menu-item").each(function(){return i=t(this),0>i.offset().top-s-n}),this.focus(e,i)):this.focus(e,this.activeMenu.find(this.options.items)[this.active?"last":"first"]())),void 0):(this.next(e),void 0)},previousPage:function(e){var i,s,n;return this.active?(this.isFirstItem()||(this._hasScroll()?(s=this.active.offset().top,n=this.element.height(),this.active.prevAll(".ui-menu-item").each(function(){return i=t(this),i.offset().top-s+n>0}),this.focus(e,i)):this.focus(e,this.activeMenu.find(this.options.items).first())),void 0):(this.next(e),void 0)},_hasScroll:function(){return this.element.outerHeight()",options:{appendTo:null,autoFocus:!1,delay:300,minLength:1,position:{my:"left top",at:"left bottom",collision:"none"},source:null,change:null,close:null,focus:null,open:null,response:null,search:null,select:null},requestIndex:0,pending:0,_create:function(){var e,i,s,n=this.element[0].nodeName.toLowerCase(),o="textarea"===n,a="input"===n; +this.isMultiLine=o||!a&&this._isContentEditable(this.element),this.valueMethod=this.element[o||a?"val":"text"],this.isNewMenu=!0,this._addClass("ui-autocomplete-input"),this.element.attr("autocomplete","off"),this._on(this.element,{keydown:function(n){if(this.element.prop("readOnly"))return e=!0,s=!0,i=!0,void 0;e=!1,s=!1,i=!1;var o=t.ui.keyCode;switch(n.keyCode){case o.PAGE_UP:e=!0,this._move("previousPage",n);break;case o.PAGE_DOWN:e=!0,this._move("nextPage",n);break;case o.UP:e=!0,this._keyEvent("previous",n);break;case o.DOWN:e=!0,this._keyEvent("next",n);break;case o.ENTER:this.menu.active&&(e=!0,n.preventDefault(),this.menu.select(n));break;case o.TAB:this.menu.active&&this.menu.select(n);break;case o.ESCAPE:this.menu.element.is(":visible")&&(this.isMultiLine||this._value(this.term),this.close(n),n.preventDefault());break;default:i=!0,this._searchTimeout(n)}},keypress:function(s){if(e)return e=!1,(!this.isMultiLine||this.menu.element.is(":visible"))&&s.preventDefault(),void 0;if(!i){var n=t.ui.keyCode;switch(s.keyCode){case n.PAGE_UP:this._move("previousPage",s);break;case n.PAGE_DOWN:this._move("nextPage",s);break;case n.UP:this._keyEvent("previous",s);break;case n.DOWN:this._keyEvent("next",s)}}},input:function(t){return s?(s=!1,t.preventDefault(),void 0):(this._searchTimeout(t),void 0)},focus:function(){this.selectedItem=null,this.previous=this._value()},blur:function(t){return this.cancelBlur?(delete this.cancelBlur,void 0):(clearTimeout(this.searching),this.close(t),this._change(t),void 0)}}),this._initSource(),this.menu=t("