/* Origin (request): POST https://testtra.puntlandgov.org/login
   Query 1 - 2025-03-18 06:39:30 [1.69ms] */
select * from `users` where `email` = 'admin@admin.com' and `status` = 1 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/login
   Query 2 - 2025-03-18 06:39:30 [0.28ms] */
select * from `users` where `id` = 2 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/login
   Query 3 - 2025-03-18 06:39:30 [0.3ms] */
select * from `userprofiles` where `userprofiles`.`user_id` = 2 and `userprofiles`.`user_id` is not null and `userprofiles`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/login
   Query 4 - 2025-03-18 06:39:30 [12.04ms] */
update `userprofiles` set `login_count` = 471, `last_login` = '2025-03-18 06:39:30', `userprofiles`.`updated_at` = '2025-03-18 06:39:30' where `id` = 2;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/login
   Query 5 - 2025-03-18 06:39:30 [0.58ms] */
select column_name as `column_name` from information_schema.columns where table_schema = 'prod_rta_temp' and table_name = 'permissions';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/login
   Query 6 - 2025-03-18 06:39:31 [0.58ms] */
select column_name as `column_name` from information_schema.columns where table_schema = 'prod_rta_temp' and table_name = 'permissions';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/login
   Query 7 - 2025-03-18 06:39:31 [0.53ms] */
select column_name as `column_name` from information_schema.columns where table_schema = 'prod_rta_temp' and table_name = 'roles';
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org
   Query 1 - 2025-03-18 06:39:31 [2.09ms] */
select * from `users` where `id` = 2 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org
   Query 2 - 2025-03-18 06:39:31 [0.85ms] */
select column_name as `column_name` from information_schema.columns where table_schema = 'prod_rta_temp' and table_name = 'roles';
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org
   Query 3 - 2025-03-18 06:39:31 [0.68ms] */
select column_name as `column_name` from information_schema.columns where table_schema = 'prod_rta_temp' and table_name = 'permissions';
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org
   Query 4 - 2025-03-18 06:39:31 [0.38ms] */
select column_name as `column_name` from information_schema.columns where table_schema = 'prod_rta_temp' and table_name = 'permissions';
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org
   Query 5 - 2025-03-18 06:39:31 [14.07ms] */
select count(*) as aggregate from `party` where `party`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org
   Query 6 - 2025-03-18 06:39:31 [17.9ms] */
select count(*) as aggregate from `party` where `created_at` > '2025-03-18' and `party`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org
   Query 7 - 2025-03-18 06:39:31 [23.37ms] */
select count(*) as aggregate from `vehicle` where `vehicle`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org
   Query 8 - 2025-03-18 06:39:31 [37.34ms] */
select count(*) as aggregate from `vehicle` where `created_at` > '2025-03-18' and `vehicle`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org
   Query 9 - 2025-03-18 06:39:31 [61.45ms] */
select sum(`payment_amount`) as aggregate from `Payment` inner join `invoice_payment` on `invoice_payment`.`payment_id` = `payment`.`id` inner join `invoice` on `invoice_payment`.`invoice_id` = `invoice`.`id` inner join `transaction` on `invoice`.`transaction_id` = `transaction`.`id` where `transaction`.`service_id` = 1 and `transaction`.`status` = 'END' and `payment_date` > '2025-03-17' and `Payment`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org
   Query 10 - 2025-03-18 06:39:31 [43.93ms] */
select sum(`payment_amount`) as aggregate from `Payment` inner join `invoice_payment` on `invoice_payment`.`payment_id` = `payment`.`id` inner join `invoice` on `invoice_payment`.`invoice_id` = `invoice`.`id` inner join `transaction` on `invoice`.`transaction_id` = `transaction`.`id` where `transaction`.`service_id` = 2 and `transaction`.`status` = 'END' and `payment_date` > '2025-03-17' and `Payment`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org
   Query 11 - 2025-03-18 06:39:31 [265.64ms] */
select sum(`outstanding_balance`) as aggregate from `invoice` inner join `transaction` on `invoice`.`transaction_id` = `transaction`.`id` where `transaction`.`service_id` = 1 and `invoice`.`invoice_amount` <> 0.00 and `due_date` < '2025-03-18' and `invoice`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org
   Query 12 - 2025-03-18 06:39:32 [793.44ms] */
select sum(`outstanding_balance`) as aggregate from `invoice` inner join `transaction` on `invoice`.`transaction_id` = `transaction`.`id` where `transaction`.`service_id` = 2 and `invoice`.`invoice_amount` <> 0.00 and `due_date` < '2025-03-18' and `invoice`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 1 - 2025-03-18 07:01:59 [2.39ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 2 - 2025-03-18 07:01:59 [0.25ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 3 - 2025-03-18 07:01:59 [0.39ms] */
select * from `userprofiles` where `userprofiles`.`user_id` = 149 and `userprofiles`.`user_id` is not null and `userprofiles`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 4 - 2025-03-18 07:01:59 [6.47ms] */
update `userprofiles` set `login_count` = 6331, `last_login` = '2025-03-18 07:01:59', `userprofiles`.`updated_at` = '2025-03-18 07:01:59' where `id` = 149;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 5 - 2025-03-18 07:01:59 [0.42ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 6 - 2025-03-18 07:01:59 [0.56ms] */
select column_name as `column_name` from information_schema.columns where table_schema = 'prod_rta_temp' and table_name = 'roles';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 7 - 2025-03-18 07:01:59 [0.54ms] */
select `id`, `name`, `model_has_roles`.`model_id` as `pivot_model_id`, `model_has_roles`.`role_id` as `pivot_role_id`, `model_has_roles`.`model_type` as `pivot_model_type` from `roles` inner join `model_has_roles` on `roles`.`id` = `model_has_roles`.`role_id` where `model_has_roles`.`model_id` in (149) and `model_has_roles`.`model_type` = 'App\Models\User';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 8 - 2025-03-18 07:01:59 [0.34ms] */
select exists(select * from `oauth_personal_access_clients`) as `exists`;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 9 - 2025-03-18 07:01:59 [0.31ms] */
select * from `oauth_personal_access_clients` order by `id` desc limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 10 - 2025-03-18 07:01:59 [0.4ms] */
select * from `oauth_clients` where `oauth_clients`.`id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 11 - 2025-03-18 07:01:59 [0.33ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 12 - 2025-03-18 07:01:59 [0.22ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 13 - 2025-03-18 07:01:59 [3.49ms] */
insert into `oauth_access_tokens` (`id`, `user_id`, `client_id`, `scopes`, `revoked`, `created_at`, `updated_at`, `expires_at`) values ('52ccc63b69989d58dad00eeb52a85be9cdd0a6f8f4934bd7d6cbb91d9eae508012c2222315b831bb', 149, 5, '[]', 0, '2025-03-18 07:01:59', '2025-03-18 07:01:59', '2026-03-18 07:01:59');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 14 - 2025-03-18 07:01:59 [0.38ms] */
select * from `oauth_access_tokens` where `id` = '52ccc63b69989d58dad00eeb52a85be9cdd0a6f8f4934bd7d6cbb91d9eae508012c2222315b831bb' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 15 - 2025-03-18 07:01:59 [3.27ms] */
update `oauth_access_tokens` set `name` = 'Secret' where `id` = '52ccc63b69989d58dad00eeb52a85be9cdd0a6f8f4934bd7d6cbb91d9eae508012c2222315b831bb';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 1 - 2025-03-18 07:02:05 [2.13ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 2 - 2025-03-18 07:02:05 [0.17ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 3 - 2025-03-18 07:02:05 [0.41ms] */
select * from `userprofiles` where `userprofiles`.`user_id` = 149 and `userprofiles`.`user_id` is not null and `userprofiles`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 4 - 2025-03-18 07:02:05 [6.27ms] */
update `userprofiles` set `login_count` = 6332, `last_login` = '2025-03-18 07:02:05', `userprofiles`.`updated_at` = '2025-03-18 07:02:05' where `id` = 149;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 5 - 2025-03-18 07:02:05 [0.27ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 6 - 2025-03-18 07:02:05 [0.56ms] */
select column_name as `column_name` from information_schema.columns where table_schema = 'prod_rta_temp' and table_name = 'roles';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 7 - 2025-03-18 07:02:05 [0.24ms] */
select `id`, `name`, `model_has_roles`.`model_id` as `pivot_model_id`, `model_has_roles`.`role_id` as `pivot_role_id`, `model_has_roles`.`model_type` as `pivot_model_type` from `roles` inner join `model_has_roles` on `roles`.`id` = `model_has_roles`.`role_id` where `model_has_roles`.`model_id` in (149) and `model_has_roles`.`model_type` = 'App\Models\User';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 8 - 2025-03-18 07:02:05 [0.14ms] */
select exists(select * from `oauth_personal_access_clients`) as `exists`;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 9 - 2025-03-18 07:02:05 [0.12ms] */
select * from `oauth_personal_access_clients` order by `id` desc limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 10 - 2025-03-18 07:02:05 [0.14ms] */
select * from `oauth_clients` where `oauth_clients`.`id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 11 - 2025-03-18 07:02:05 [0.14ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 12 - 2025-03-18 07:02:05 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 13 - 2025-03-18 07:02:05 [3.22ms] */
insert into `oauth_access_tokens` (`id`, `user_id`, `client_id`, `scopes`, `revoked`, `created_at`, `updated_at`, `expires_at`) values ('f49f37f1ce80e8ce903271b1079b3c6c282864d8ee7a5f31d0eb0cbd41332002a16030dfa0366770', 149, 5, '[]', 0, '2025-03-18 07:02:05', '2025-03-18 07:02:05', '2026-03-18 07:02:05');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 14 - 2025-03-18 07:02:05 [0.35ms] */
select * from `oauth_access_tokens` where `id` = 'f49f37f1ce80e8ce903271b1079b3c6c282864d8ee7a5f31d0eb0cbd41332002a16030dfa0366770' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 15 - 2025-03-18 07:02:06 [3.14ms] */
update `oauth_access_tokens` set `name` = 'Secret' where `id` = 'f49f37f1ce80e8ce903271b1079b3c6c282864d8ee7a5f31d0eb0cbd41332002a16030dfa0366770';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 1 - 2025-03-18 07:02:19 [1.42ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 2 - 2025-03-18 07:02:19 [0.16ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 3 - 2025-03-18 07:02:19 [0.46ms] */
select * from `userprofiles` where `userprofiles`.`user_id` = 149 and `userprofiles`.`user_id` is not null and `userprofiles`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 4 - 2025-03-18 07:02:19 [11.28ms] */
update `userprofiles` set `login_count` = 6333, `last_login` = '2025-03-18 07:02:19', `userprofiles`.`updated_at` = '2025-03-18 07:02:19' where `id` = 149;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 5 - 2025-03-18 07:02:19 [0.33ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 6 - 2025-03-18 07:02:19 [0.74ms] */
select column_name as `column_name` from information_schema.columns where table_schema = 'prod_rta_temp' and table_name = 'roles';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 7 - 2025-03-18 07:02:19 [0.31ms] */
select `id`, `name`, `model_has_roles`.`model_id` as `pivot_model_id`, `model_has_roles`.`role_id` as `pivot_role_id`, `model_has_roles`.`model_type` as `pivot_model_type` from `roles` inner join `model_has_roles` on `roles`.`id` = `model_has_roles`.`role_id` where `model_has_roles`.`model_id` in (149) and `model_has_roles`.`model_type` = 'App\Models\User';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 8 - 2025-03-18 07:02:19 [0.13ms] */
select exists(select * from `oauth_personal_access_clients`) as `exists`;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 9 - 2025-03-18 07:02:19 [0.12ms] */
select * from `oauth_personal_access_clients` order by `id` desc limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 10 - 2025-03-18 07:02:19 [0.14ms] */
select * from `oauth_clients` where `oauth_clients`.`id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 11 - 2025-03-18 07:02:19 [0.14ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 12 - 2025-03-18 07:02:19 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 13 - 2025-03-18 07:02:19 [3.79ms] */
insert into `oauth_access_tokens` (`id`, `user_id`, `client_id`, `scopes`, `revoked`, `created_at`, `updated_at`, `expires_at`) values ('2c6fce58f197d8f053861a06a3af6f9e0f7782b3da12f577fc2c1ec62e9a69429753f5fecc97a12c', 149, 5, '[]', 0, '2025-03-18 07:02:19', '2025-03-18 07:02:19', '2026-03-18 07:02:19');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 14 - 2025-03-18 07:02:19 [0.35ms] */
select * from `oauth_access_tokens` where `id` = '2c6fce58f197d8f053861a06a3af6f9e0f7782b3da12f577fc2c1ec62e9a69429753f5fecc97a12c' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 15 - 2025-03-18 07:02:19 [3.31ms] */
update `oauth_access_tokens` set `name` = 'Secret' where `id` = '2c6fce58f197d8f053861a06a3af6f9e0f7782b3da12f577fc2c1ec62e9a69429753f5fecc97a12c';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 1 - 2025-03-18 07:02:21 [2.48ms] */
select * from `oauth_access_tokens` where `id` = '2c6fce58f197d8f053861a06a3af6f9e0f7782b3da12f577fc2c1ec62e9a69429753f5fecc97a12c' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 2 - 2025-03-18 07:02:21 [0.28ms] */
select * from `oauth_access_tokens` where `id` = '2c6fce58f197d8f053861a06a3af6f9e0f7782b3da12f577fc2c1ec62e9a69429753f5fecc97a12c' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 3 - 2025-03-18 07:02:21 [0.5ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 4 - 2025-03-18 07:02:21 [0.37ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 5 - 2025-03-18 07:02:21 [0.22ms] */
select * from `oauth_access_tokens` where `id` = '2c6fce58f197d8f053861a06a3af6f9e0f7782b3da12f577fc2c1ec62e9a69429753f5fecc97a12c' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 6 - 2025-03-18 07:02:21 [0.21ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 7 - 2025-03-18 07:02:21 [1.54ms] */
select `vehicle`.`id` as `vehicle_id`, `party`.`id` as `party_id`, `vehicle`.`license_plate`, `vehicle`.`year`, `vehicle`.`odometer`, `vehicle`.`vin`, `sub_category`.`name` as `sub_category`, `classification_type`.`name` as `classification`, `make`.`name` as `make`, `model`.`name` as `model`, `vehicle_color`.`name` as `vehicle_color`, `fuel_type`.`name` as `fuel_type`, `vehicle_type`.`name` as `vehicle_type`, CASE
                WHEN party_vehicle.id IS NULL THEN "UNREGISTERED" ELSE party_vehicle.status END AS status, CASE
                WHEN person.id IS NOT NULL THEN CONCAT(person.first_name, " ", person.second_name, " ", person.third_name, " ", person.fourth_name)
                WHEN company.id IS NOT NULL THEN company.company_name
                ELSE "No Entity Found"
                END AS owner, `party`.`partyable_type` as `owner_type`, `party_vehicle`.`registration_date`, `vehicle`.`created_at`, `vehicle`.`updated_at` from `vehicle` left join `party_vehicle` on `party_vehicle`.`vehicle_id` = `vehicle`.`id` left join `sub_category` on `vehicle`.`sub_category_id` = `sub_category`.`id` left join `classification_type` on `party_vehicle`.`classification_id` = `classification_type`.`id` left join `model` on `vehicle`.`model_id` = `model`.`id` left join `make` on `model`.`make_id` = `make`.`id` left join `vehicle_color` on `vehicle`.`vehicle_color_id` = `vehicle_color`.`id` left join `fuel_type` on `vehicle`.`fuel_type_id` = `fuel_type`.`id` left join `vehicle_type` on `vehicle`.`vehicle_type_id` = `vehicle_type`.`id` left join `party` on `party_vehicle`.`party_id` = `party`.`id` left join `person` on `person`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Person' left join `company` on `company`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Company' where `license_plate` = 'LI574' and `party_vehicle`.`is_owner` = 'Y' and `vehicle`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 8 - 2025-03-18 07:02:21 [0.43ms] */
select * from `party` where `party`.`id` = 39526 and `party`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 9 - 2025-03-18 07:02:21 [0.4ms] */
select * from `vehicle` where `id` = 50459 and `provisional` = 'Y' and `vehicle`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 10 - 2025-03-18 07:02:21 [0.38ms] */
select * from `party_vehicle` where `vehicle_id` = 50459 and `is_owner` = 'Y' and `party_vehicle`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 1 - 2025-03-18 07:02:36 [2.48ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 2 - 2025-03-18 07:02:36 [0.17ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 3 - 2025-03-18 07:02:36 [0.38ms] */
select * from `userprofiles` where `userprofiles`.`user_id` = 149 and `userprofiles`.`user_id` is not null and `userprofiles`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 4 - 2025-03-18 07:02:36 [11.25ms] */
update `userprofiles` set `login_count` = 6334, `last_login` = '2025-03-18 07:02:36', `userprofiles`.`updated_at` = '2025-03-18 07:02:36' where `id` = 149;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 5 - 2025-03-18 07:02:36 [0.34ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 6 - 2025-03-18 07:02:36 [0.73ms] */
select column_name as `column_name` from information_schema.columns where table_schema = 'prod_rta_temp' and table_name = 'roles';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 7 - 2025-03-18 07:02:36 [0.3ms] */
select `id`, `name`, `model_has_roles`.`model_id` as `pivot_model_id`, `model_has_roles`.`role_id` as `pivot_role_id`, `model_has_roles`.`model_type` as `pivot_model_type` from `roles` inner join `model_has_roles` on `roles`.`id` = `model_has_roles`.`role_id` where `model_has_roles`.`model_id` in (149) and `model_has_roles`.`model_type` = 'App\Models\User';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 8 - 2025-03-18 07:02:36 [0.13ms] */
select exists(select * from `oauth_personal_access_clients`) as `exists`;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 9 - 2025-03-18 07:02:36 [0.12ms] */
select * from `oauth_personal_access_clients` order by `id` desc limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 10 - 2025-03-18 07:02:36 [0.14ms] */
select * from `oauth_clients` where `oauth_clients`.`id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 11 - 2025-03-18 07:02:36 [0.18ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 12 - 2025-03-18 07:02:36 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 13 - 2025-03-18 07:02:36 [3.31ms] */
insert into `oauth_access_tokens` (`id`, `user_id`, `client_id`, `scopes`, `revoked`, `created_at`, `updated_at`, `expires_at`) values ('665f45b55968214aab9731a28a8fc5e3cc8487aaae7f52c101dac9dc682f5e402c034bfecb592c3b', 149, 5, '[]', 0, '2025-03-18 07:02:36', '2025-03-18 07:02:36', '2026-03-18 07:02:36');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 14 - 2025-03-18 07:02:36 [0.23ms] */
select * from `oauth_access_tokens` where `id` = '665f45b55968214aab9731a28a8fc5e3cc8487aaae7f52c101dac9dc682f5e402c034bfecb592c3b' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 15 - 2025-03-18 07:02:36 [3.15ms] */
update `oauth_access_tokens` set `name` = 'Secret' where `id` = '665f45b55968214aab9731a28a8fc5e3cc8487aaae7f52c101dac9dc682f5e402c034bfecb592c3b';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/invoices
   Query 1 - 2025-03-18 07:02:37 [1.42ms] */
select * from `oauth_access_tokens` where `id` = '665f45b55968214aab9731a28a8fc5e3cc8487aaae7f52c101dac9dc682f5e402c034bfecb592c3b' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/invoices
   Query 2 - 2025-03-18 07:02:37 [0.15ms] */
select * from `oauth_access_tokens` where `id` = '665f45b55968214aab9731a28a8fc5e3cc8487aaae7f52c101dac9dc682f5e402c034bfecb592c3b' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/invoices
   Query 3 - 2025-03-18 07:02:37 [0.15ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/invoices
   Query 4 - 2025-03-18 07:02:37 [0.17ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/invoices
   Query 5 - 2025-03-18 07:02:37 [0.14ms] */
select * from `oauth_access_tokens` where `id` = '665f45b55968214aab9731a28a8fc5e3cc8487aaae7f52c101dac9dc682f5e402c034bfecb592c3b' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/invoices
   Query 6 - 2025-03-18 07:02:37 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/invoices
   Query 7 - 2025-03-18 07:02:37 [1.34ms] */
select `invoice`.`id` as `invoice_id`, `invoice_number`, `term`.`year`, `term`.`quarter`, `invoice`.`transaction_id`, `party`.`id` as `customer_id`, CASE
                WHEN person.id IS NOT NULL THEN CONCAT(person.first_name, " ", person.second_name, " ", person.third_name, " ", person.fourth_name)
                WHEN company.id IS NOT NULL THEN company.company_name
                ELSE "No Entity Found"
                END AS customer_name, CASE
                WHEN party.phone_number_2 IS NOT NULL THEN CONCAT(party.phone_number_1," / ",party.phone_number_2)
                ELSE party.phone_number_1 END as mobile_number, `vehicle`.`license_plate`, `service`.`name` as `service_name`, `invoice`.`due_date`, `invoice`.`total_invoice_amount` as `invoice_amount`, `invoice`.`status`, `invoice`.`parent`, `invoice`.`created_at`, `invoice`.`updated_at`, CASE WHEN invoice_payment.id IS NULL THEN "Y" ELSE "N" END as make_payment from `invoice` left join `party` on `invoice`.`party_id` = `party`.`id` left join `person` on `person`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Person' left join `company` on `company`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Company' left join `transaction` on `invoice`.`transaction_id` = `transaction`.`id` left join `vehicle_tax` on `transaction`.`vehicle_tax_id` = `vehicle_tax`.`id` left join `term` on `vehicle_tax`.`term_id` = `term`.`id` left join `vehicle` on `transaction`.`vehicle_id` = `vehicle`.`id` left join `service` on `transaction`.`service_id` = `service`.`id` left join `invoice_payment` on `invoice_payment`.`invoice_id` = `invoice`.`id` where `invoice`.`total_invoice_amount` > 0 and `service`.`name` = 'Tax' and `vehicle_tax`.`exempt` = 'N' and `transaction`.`vehicle_tax_id` is not null and `invoice`.`parent` = 'N' and `invoice`.`party_id` = 39526 and `license_plate` = 'LI574' and `invoice`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 1 - 2025-03-18 07:02:59 [2.06ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 2 - 2025-03-18 07:02:59 [0.21ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 3 - 2025-03-18 07:02:59 [0.4ms] */
select * from `userprofiles` where `userprofiles`.`user_id` = 149 and `userprofiles`.`user_id` is not null and `userprofiles`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 4 - 2025-03-18 07:02:59 [11.74ms] */
update `userprofiles` set `login_count` = 6335, `last_login` = '2025-03-18 07:02:59', `userprofiles`.`updated_at` = '2025-03-18 07:02:59' where `id` = 149;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 5 - 2025-03-18 07:02:59 [0.26ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 6 - 2025-03-18 07:02:59 [0.58ms] */
select column_name as `column_name` from information_schema.columns where table_schema = 'prod_rta_temp' and table_name = 'roles';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 7 - 2025-03-18 07:02:59 [0.25ms] */
select `id`, `name`, `model_has_roles`.`model_id` as `pivot_model_id`, `model_has_roles`.`role_id` as `pivot_role_id`, `model_has_roles`.`model_type` as `pivot_model_type` from `roles` inner join `model_has_roles` on `roles`.`id` = `model_has_roles`.`role_id` where `model_has_roles`.`model_id` in (149) and `model_has_roles`.`model_type` = 'App\Models\User';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 8 - 2025-03-18 07:02:59 [0.2ms] */
select exists(select * from `oauth_personal_access_clients`) as `exists`;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 9 - 2025-03-18 07:02:59 [0.18ms] */
select * from `oauth_personal_access_clients` order by `id` desc limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 10 - 2025-03-18 07:02:59 [0.22ms] */
select * from `oauth_clients` where `oauth_clients`.`id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 11 - 2025-03-18 07:02:59 [0.23ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 12 - 2025-03-18 07:02:59 [0.21ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 13 - 2025-03-18 07:02:59 [3.54ms] */
insert into `oauth_access_tokens` (`id`, `user_id`, `client_id`, `scopes`, `revoked`, `created_at`, `updated_at`, `expires_at`) values ('f66645e9d55a6364d3d1851b18548a195b2c900f3955e157d20dbbaf367650ec83f41d104bd7df24', 149, 5, '[]', 0, '2025-03-18 07:02:59', '2025-03-18 07:02:59', '2026-03-18 07:02:59');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 14 - 2025-03-18 07:02:59 [0.22ms] */
select * from `oauth_access_tokens` where `id` = 'f66645e9d55a6364d3d1851b18548a195b2c900f3955e157d20dbbaf367650ec83f41d104bd7df24' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 15 - 2025-03-18 07:02:59 [2.98ms] */
update `oauth_access_tokens` set `name` = 'Secret' where `id` = 'f66645e9d55a6364d3d1851b18548a195b2c900f3955e157d20dbbaf367650ec83f41d104bd7df24';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 1 - 2025-03-18 07:02:59 [2.32ms] */
select * from `oauth_access_tokens` where `id` = 'f66645e9d55a6364d3d1851b18548a195b2c900f3955e157d20dbbaf367650ec83f41d104bd7df24' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 2 - 2025-03-18 07:02:59 [0.28ms] */
select * from `oauth_access_tokens` where `id` = 'f66645e9d55a6364d3d1851b18548a195b2c900f3955e157d20dbbaf367650ec83f41d104bd7df24' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 3 - 2025-03-18 07:02:59 [0.32ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 4 - 2025-03-18 07:02:59 [0.26ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 5 - 2025-03-18 07:02:59 [0.22ms] */
select * from `oauth_access_tokens` where `id` = 'f66645e9d55a6364d3d1851b18548a195b2c900f3955e157d20dbbaf367650ec83f41d104bd7df24' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 6 - 2025-03-18 07:02:59 [0.22ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 7 - 2025-03-18 07:02:59 [115.75ms] */
select DISTINCT payment.id as payment_id, `party`.`id` as `customer_id`, CASE
                WHEN person.id IS NOT NULL THEN CONCAT(person.first_name, " ", person.second_name, " ", person.third_name, " ", person.fourth_name)
                WHEN company.id IS NOT NULL THEN company.company_name
                ELSE "No Entity Found"
                END AS customer_name, `vehicle`.`license_plate`, `payment`.`payment_amount`, `external_payment_reference_no` as `payment_reference_number`, `payment`.`payment_date`, `payment_method`.`name` as `payment_method`, `payment`.`paid_by`, `payment`.`paid_by_mobile` from `payment` left join `invoice_payment` on `invoice_payment`.`payment_id` = `payment`.`id` left join `invoice` on `invoice_payment`.`invoice_id` = `invoice`.`id` and `invoice`.`parent` = 'N' left join `transaction` on `transaction`.`invoice_id` = `invoice`.`id` left join `service` on `transaction`.`service_id` = `service`.`id` left join `vehicle` on `transaction`.`vehicle_id` = `vehicle`.`id` left join `party` on `transaction`.`party_id` = `party`.`id` left join `payment_method` on `payment`.`payment_method_id` = `payment_method`.`id` left join `person` on `person`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Person' left join `company` on `company`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Company' where `service`.`name` = 'Tax' and `payment`.`id` = 89243 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 1 - 2025-03-18 07:03:38 [1.42ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 2 - 2025-03-18 07:03:38 [0.16ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 3 - 2025-03-18 07:03:38 [0.41ms] */
select * from `userprofiles` where `userprofiles`.`user_id` = 149 and `userprofiles`.`user_id` is not null and `userprofiles`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 4 - 2025-03-18 07:03:38 [6.13ms] */
update `userprofiles` set `login_count` = 6336, `last_login` = '2025-03-18 07:03:38', `userprofiles`.`updated_at` = '2025-03-18 07:03:38' where `id` = 149;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 5 - 2025-03-18 07:03:38 [0.25ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 6 - 2025-03-18 07:03:38 [0.57ms] */
select column_name as `column_name` from information_schema.columns where table_schema = 'prod_rta_temp' and table_name = 'roles';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 7 - 2025-03-18 07:03:38 [0.27ms] */
select `id`, `name`, `model_has_roles`.`model_id` as `pivot_model_id`, `model_has_roles`.`role_id` as `pivot_role_id`, `model_has_roles`.`model_type` as `pivot_model_type` from `roles` inner join `model_has_roles` on `roles`.`id` = `model_has_roles`.`role_id` where `model_has_roles`.`model_id` in (149) and `model_has_roles`.`model_type` = 'App\Models\User';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 8 - 2025-03-18 07:03:38 [0.15ms] */
select exists(select * from `oauth_personal_access_clients`) as `exists`;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 9 - 2025-03-18 07:03:38 [0.12ms] */
select * from `oauth_personal_access_clients` order by `id` desc limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 10 - 2025-03-18 07:03:38 [0.14ms] */
select * from `oauth_clients` where `oauth_clients`.`id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 11 - 2025-03-18 07:03:38 [0.14ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 12 - 2025-03-18 07:03:38 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 13 - 2025-03-18 07:03:38 [3.43ms] */
insert into `oauth_access_tokens` (`id`, `user_id`, `client_id`, `scopes`, `revoked`, `created_at`, `updated_at`, `expires_at`) values ('368375018f3a3e90fe05204c34f56d9ce9c4d94f2e688ffbae2e7eaedf0157d6a16b18bd2910de99', 149, 5, '[]', 0, '2025-03-18 07:03:38', '2025-03-18 07:03:38', '2026-03-18 07:03:38');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 14 - 2025-03-18 07:03:38 [0.42ms] */
select * from `oauth_access_tokens` where `id` = '368375018f3a3e90fe05204c34f56d9ce9c4d94f2e688ffbae2e7eaedf0157d6a16b18bd2910de99' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 15 - 2025-03-18 07:03:38 [3.37ms] */
update `oauth_access_tokens` set `name` = 'Secret' where `id` = '368375018f3a3e90fe05204c34f56d9ce9c4d94f2e688ffbae2e7eaedf0157d6a16b18bd2910de99';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 1 - 2025-03-18 07:03:38 [2.36ms] */
select * from `oauth_access_tokens` where `id` = '368375018f3a3e90fe05204c34f56d9ce9c4d94f2e688ffbae2e7eaedf0157d6a16b18bd2910de99' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 2 - 2025-03-18 07:03:38 [0.26ms] */
select * from `oauth_access_tokens` where `id` = '368375018f3a3e90fe05204c34f56d9ce9c4d94f2e688ffbae2e7eaedf0157d6a16b18bd2910de99' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 3 - 2025-03-18 07:03:38 [0.23ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 4 - 2025-03-18 07:03:38 [0.28ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 5 - 2025-03-18 07:03:38 [0.22ms] */
select * from `oauth_access_tokens` where `id` = '368375018f3a3e90fe05204c34f56d9ce9c4d94f2e688ffbae2e7eaedf0157d6a16b18bd2910de99' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 6 - 2025-03-18 07:03:38 [0.2ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 7 - 2025-03-18 07:03:38 [0.44ms] */
select DISTINCT payment.id as payment_id, `party`.`id` as `customer_id`, CASE
                WHEN person.id IS NOT NULL THEN CONCAT(person.first_name, " ", person.second_name, " ", person.third_name, " ", person.fourth_name)
                WHEN company.id IS NOT NULL THEN company.company_name
                ELSE "No Entity Found"
                END AS customer_name, `vehicle`.`license_plate`, `payment`.`payment_amount`, `external_payment_reference_no` as `payment_reference_number`, `payment`.`payment_date`, `payment_method`.`name` as `payment_method`, `payment`.`paid_by`, `payment`.`paid_by_mobile` from `payment` left join `invoice_payment` on `invoice_payment`.`payment_id` = `payment`.`id` left join `invoice` on `invoice_payment`.`invoice_id` = `invoice`.`id` and `invoice`.`parent` = 'N' left join `transaction` on `transaction`.`invoice_id` = `invoice`.`id` left join `service` on `transaction`.`service_id` = `service`.`id` left join `vehicle` on `transaction`.`vehicle_id` = `vehicle`.`id` left join `party` on `transaction`.`party_id` = `party`.`id` left join `payment_method` on `payment`.`payment_method_id` = `payment_method`.`id` left join `person` on `person`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Person' left join `company` on `company`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Company' where `service`.`name` = 'Tax' and `payment`.`id` = 89243 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 1 - 2025-03-18 07:06:24 [1.43ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 2 - 2025-03-18 07:06:24 [0.16ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 3 - 2025-03-18 07:06:24 [0.42ms] */
select * from `userprofiles` where `userprofiles`.`user_id` = 149 and `userprofiles`.`user_id` is not null and `userprofiles`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 4 - 2025-03-18 07:06:24 [11.16ms] */
update `userprofiles` set `login_count` = 6337, `last_login` = '2025-03-18 07:06:24', `userprofiles`.`updated_at` = '2025-03-18 07:06:24' where `id` = 149;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 5 - 2025-03-18 07:06:24 [0.33ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 6 - 2025-03-18 07:06:24 [0.72ms] */
select column_name as `column_name` from information_schema.columns where table_schema = 'prod_rta_temp' and table_name = 'roles';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 7 - 2025-03-18 07:06:24 [0.3ms] */
select `id`, `name`, `model_has_roles`.`model_id` as `pivot_model_id`, `model_has_roles`.`role_id` as `pivot_role_id`, `model_has_roles`.`model_type` as `pivot_model_type` from `roles` inner join `model_has_roles` on `roles`.`id` = `model_has_roles`.`role_id` where `model_has_roles`.`model_id` in (149) and `model_has_roles`.`model_type` = 'App\Models\User';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 8 - 2025-03-18 07:06:24 [0.14ms] */
select exists(select * from `oauth_personal_access_clients`) as `exists`;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 9 - 2025-03-18 07:06:24 [0.12ms] */
select * from `oauth_personal_access_clients` order by `id` desc limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 10 - 2025-03-18 07:06:24 [0.14ms] */
select * from `oauth_clients` where `oauth_clients`.`id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 11 - 2025-03-18 07:06:24 [0.14ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 12 - 2025-03-18 07:06:24 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 13 - 2025-03-18 07:06:24 [6.64ms] */
insert into `oauth_access_tokens` (`id`, `user_id`, `client_id`, `scopes`, `revoked`, `created_at`, `updated_at`, `expires_at`) values ('98dd4ae3d1753ed86a980c117d3867176fed97eb2bf6935710ad70451b01d9fb33c957429909e712', 149, 5, '[]', 0, '2025-03-18 07:06:24', '2025-03-18 07:06:24', '2026-03-18 07:06:24');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 14 - 2025-03-18 07:06:24 [0.38ms] */
select * from `oauth_access_tokens` where `id` = '98dd4ae3d1753ed86a980c117d3867176fed97eb2bf6935710ad70451b01d9fb33c957429909e712' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 15 - 2025-03-18 07:06:24 [3.45ms] */
update `oauth_access_tokens` set `name` = 'Secret' where `id` = '98dd4ae3d1753ed86a980c117d3867176fed97eb2bf6935710ad70451b01d9fb33c957429909e712';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 1 - 2025-03-18 07:06:24 [2.57ms] */
select * from `oauth_access_tokens` where `id` = '98dd4ae3d1753ed86a980c117d3867176fed97eb2bf6935710ad70451b01d9fb33c957429909e712' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 2 - 2025-03-18 07:06:24 [0.28ms] */
select * from `oauth_access_tokens` where `id` = '98dd4ae3d1753ed86a980c117d3867176fed97eb2bf6935710ad70451b01d9fb33c957429909e712' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 3 - 2025-03-18 07:06:24 [0.27ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 4 - 2025-03-18 07:06:24 [0.32ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 5 - 2025-03-18 07:06:24 [0.14ms] */
select * from `oauth_access_tokens` where `id` = '98dd4ae3d1753ed86a980c117d3867176fed97eb2bf6935710ad70451b01d9fb33c957429909e712' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 6 - 2025-03-18 07:06:24 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 7 - 2025-03-18 07:06:24 [0.29ms] */
select DISTINCT payment.id as payment_id, `party`.`id` as `customer_id`, CASE
                WHEN person.id IS NOT NULL THEN CONCAT(person.first_name, " ", person.second_name, " ", person.third_name, " ", person.fourth_name)
                WHEN company.id IS NOT NULL THEN company.company_name
                ELSE "No Entity Found"
                END AS customer_name, `vehicle`.`license_plate`, `payment`.`payment_amount`, `external_payment_reference_no` as `payment_reference_number`, `payment`.`payment_date`, `payment_method`.`name` as `payment_method`, `payment`.`paid_by`, `payment`.`paid_by_mobile` from `payment` left join `invoice_payment` on `invoice_payment`.`payment_id` = `payment`.`id` left join `invoice` on `invoice_payment`.`invoice_id` = `invoice`.`id` and `invoice`.`parent` = 'N' left join `transaction` on `transaction`.`invoice_id` = `invoice`.`id` left join `service` on `transaction`.`service_id` = `service`.`id` left join `vehicle` on `transaction`.`vehicle_id` = `vehicle`.`id` left join `party` on `transaction`.`party_id` = `party`.`id` left join `payment_method` on `payment`.`payment_method_id` = `payment_method`.`id` left join `person` on `person`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Person' left join `company` on `company`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Company' where `service`.`name` = 'Tax' and `payment`.`id` = 89243 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 1 - 2025-03-18 07:07:35 [2.12ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 2 - 2025-03-18 07:07:35 [0.17ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 3 - 2025-03-18 07:07:35 [0.39ms] */
select * from `userprofiles` where `userprofiles`.`user_id` = 149 and `userprofiles`.`user_id` is not null and `userprofiles`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 4 - 2025-03-18 07:07:35 [6ms] */
update `userprofiles` set `login_count` = 6338, `last_login` = '2025-03-18 07:07:35', `userprofiles`.`updated_at` = '2025-03-18 07:07:35' where `id` = 149;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 5 - 2025-03-18 07:07:35 [0.27ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 6 - 2025-03-18 07:07:35 [0.59ms] */
select column_name as `column_name` from information_schema.columns where table_schema = 'prod_rta_temp' and table_name = 'roles';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 7 - 2025-03-18 07:07:35 [0.24ms] */
select `id`, `name`, `model_has_roles`.`model_id` as `pivot_model_id`, `model_has_roles`.`role_id` as `pivot_role_id`, `model_has_roles`.`model_type` as `pivot_model_type` from `roles` inner join `model_has_roles` on `roles`.`id` = `model_has_roles`.`role_id` where `model_has_roles`.`model_id` in (149) and `model_has_roles`.`model_type` = 'App\Models\User';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 8 - 2025-03-18 07:07:35 [0.13ms] */
select exists(select * from `oauth_personal_access_clients`) as `exists`;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 9 - 2025-03-18 07:07:35 [0.12ms] */
select * from `oauth_personal_access_clients` order by `id` desc limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 10 - 2025-03-18 07:07:35 [0.14ms] */
select * from `oauth_clients` where `oauth_clients`.`id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 11 - 2025-03-18 07:07:35 [0.15ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 12 - 2025-03-18 07:07:35 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 13 - 2025-03-18 07:07:35 [3.38ms] */
insert into `oauth_access_tokens` (`id`, `user_id`, `client_id`, `scopes`, `revoked`, `created_at`, `updated_at`, `expires_at`) values ('8427c70dc4598f79c9633ee27002213ab9f06529aa18baa1c464702be3e512aa01fbfd2d563d0c3d', 149, 5, '[]', 0, '2025-03-18 07:07:35', '2025-03-18 07:07:35', '2026-03-18 07:07:35');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 14 - 2025-03-18 07:07:35 [0.38ms] */
select * from `oauth_access_tokens` where `id` = '8427c70dc4598f79c9633ee27002213ab9f06529aa18baa1c464702be3e512aa01fbfd2d563d0c3d' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 15 - 2025-03-18 07:07:35 [4.21ms] */
update `oauth_access_tokens` set `name` = 'Secret' where `id` = '8427c70dc4598f79c9633ee27002213ab9f06529aa18baa1c464702be3e512aa01fbfd2d563d0c3d';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 1 - 2025-03-18 07:07:36 [1.55ms] */
select * from `oauth_access_tokens` where `id` = '8427c70dc4598f79c9633ee27002213ab9f06529aa18baa1c464702be3e512aa01fbfd2d563d0c3d' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 2 - 2025-03-18 07:07:36 [0.14ms] */
select * from `oauth_access_tokens` where `id` = '8427c70dc4598f79c9633ee27002213ab9f06529aa18baa1c464702be3e512aa01fbfd2d563d0c3d' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 3 - 2025-03-18 07:07:36 [0.14ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 4 - 2025-03-18 07:07:36 [0.17ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 5 - 2025-03-18 07:07:36 [0.14ms] */
select * from `oauth_access_tokens` where `id` = '8427c70dc4598f79c9633ee27002213ab9f06529aa18baa1c464702be3e512aa01fbfd2d563d0c3d' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 6 - 2025-03-18 07:07:36 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 7 - 2025-03-18 07:07:36 [0.35ms] */
select DISTINCT payment.id as payment_id, `party`.`id` as `customer_id`, CASE
                WHEN person.id IS NOT NULL THEN CONCAT(person.first_name, " ", person.second_name, " ", person.third_name, " ", person.fourth_name)
                WHEN company.id IS NOT NULL THEN company.company_name
                ELSE "No Entity Found"
                END AS customer_name, `vehicle`.`license_plate`, `payment`.`payment_amount`, `external_payment_reference_no` as `payment_reference_number`, `payment`.`payment_date`, `payment_method`.`name` as `payment_method`, `payment`.`paid_by`, `payment`.`paid_by_mobile` from `payment` left join `invoice_payment` on `invoice_payment`.`payment_id` = `payment`.`id` left join `invoice` on `invoice_payment`.`invoice_id` = `invoice`.`id` and `invoice`.`parent` = 'N' left join `transaction` on `transaction`.`invoice_id` = `invoice`.`id` left join `service` on `transaction`.`service_id` = `service`.`id` left join `vehicle` on `transaction`.`vehicle_id` = `vehicle`.`id` left join `party` on `transaction`.`party_id` = `party`.`id` left join `payment_method` on `payment`.`payment_method_id` = `payment_method`.`id` left join `person` on `person`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Person' left join `company` on `company`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Company' where `service`.`name` = 'Tax' and `payment`.`id` = 89243 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 1 - 2025-03-18 07:11:12 [2.13ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 2 - 2025-03-18 07:11:12 [0.16ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 3 - 2025-03-18 07:11:12 [0.43ms] */
select * from `userprofiles` where `userprofiles`.`user_id` = 149 and `userprofiles`.`user_id` is not null and `userprofiles`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 4 - 2025-03-18 07:11:12 [11.29ms] */
update `userprofiles` set `login_count` = 6339, `last_login` = '2025-03-18 07:11:12', `userprofiles`.`updated_at` = '2025-03-18 07:11:12' where `id` = 149;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 5 - 2025-03-18 07:11:12 [0.32ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 6 - 2025-03-18 07:11:12 [0.69ms] */
select column_name as `column_name` from information_schema.columns where table_schema = 'prod_rta_temp' and table_name = 'roles';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 7 - 2025-03-18 07:11:12 [0.3ms] */
select `id`, `name`, `model_has_roles`.`model_id` as `pivot_model_id`, `model_has_roles`.`role_id` as `pivot_role_id`, `model_has_roles`.`model_type` as `pivot_model_type` from `roles` inner join `model_has_roles` on `roles`.`id` = `model_has_roles`.`role_id` where `model_has_roles`.`model_id` in (149) and `model_has_roles`.`model_type` = 'App\Models\User';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 8 - 2025-03-18 07:11:12 [0.13ms] */
select exists(select * from `oauth_personal_access_clients`) as `exists`;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 9 - 2025-03-18 07:11:12 [0.12ms] */
select * from `oauth_personal_access_clients` order by `id` desc limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 10 - 2025-03-18 07:11:12 [0.14ms] */
select * from `oauth_clients` where `oauth_clients`.`id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 11 - 2025-03-18 07:11:12 [0.14ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 12 - 2025-03-18 07:11:12 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 13 - 2025-03-18 07:11:12 [3.18ms] */
insert into `oauth_access_tokens` (`id`, `user_id`, `client_id`, `scopes`, `revoked`, `created_at`, `updated_at`, `expires_at`) values ('fa680b7b9055cef96ae3c7edd038167691c600510cb8b1553e007b094589cd15a815f03d7c17b6f4', 149, 5, '[]', 0, '2025-03-18 07:11:12', '2025-03-18 07:11:12', '2026-03-18 07:11:12');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 14 - 2025-03-18 07:11:12 [0.29ms] */
select * from `oauth_access_tokens` where `id` = 'fa680b7b9055cef96ae3c7edd038167691c600510cb8b1553e007b094589cd15a815f03d7c17b6f4' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 15 - 2025-03-18 07:11:12 [2.77ms] */
update `oauth_access_tokens` set `name` = 'Secret' where `id` = 'fa680b7b9055cef96ae3c7edd038167691c600510cb8b1553e007b094589cd15a815f03d7c17b6f4';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 1 - 2025-03-18 07:11:13 [1.55ms] */
select * from `oauth_access_tokens` where `id` = 'fa680b7b9055cef96ae3c7edd038167691c600510cb8b1553e007b094589cd15a815f03d7c17b6f4' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 2 - 2025-03-18 07:11:13 [0.14ms] */
select * from `oauth_access_tokens` where `id` = 'fa680b7b9055cef96ae3c7edd038167691c600510cb8b1553e007b094589cd15a815f03d7c17b6f4' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 3 - 2025-03-18 07:11:13 [0.14ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 4 - 2025-03-18 07:11:13 [0.17ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 5 - 2025-03-18 07:11:13 [0.14ms] */
select * from `oauth_access_tokens` where `id` = 'fa680b7b9055cef96ae3c7edd038167691c600510cb8b1553e007b094589cd15a815f03d7c17b6f4' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 6 - 2025-03-18 07:11:13 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 7 - 2025-03-18 07:11:13 [0.3ms] */
select DISTINCT payment.id as payment_id, `party`.`id` as `customer_id`, CASE
                WHEN person.id IS NOT NULL THEN CONCAT(person.first_name, " ", person.second_name, " ", person.third_name, " ", person.fourth_name)
                WHEN company.id IS NOT NULL THEN company.company_name
                ELSE "No Entity Found"
                END AS customer_name, `vehicle`.`license_plate`, `payment`.`payment_amount`, `external_payment_reference_no` as `payment_reference_number`, `payment`.`payment_date`, `payment_method`.`name` as `payment_method`, `payment`.`paid_by`, `payment`.`paid_by_mobile` from `payment` left join `invoice_payment` on `invoice_payment`.`payment_id` = `payment`.`id` left join `invoice` on `invoice_payment`.`invoice_id` = `invoice`.`id` and `invoice`.`parent` = 'N' left join `transaction` on `transaction`.`invoice_id` = `invoice`.`id` left join `service` on `transaction`.`service_id` = `service`.`id` left join `vehicle` on `transaction`.`vehicle_id` = `vehicle`.`id` left join `party` on `transaction`.`party_id` = `party`.`id` left join `payment_method` on `payment`.`payment_method_id` = `payment_method`.`id` left join `person` on `person`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Person' left join `company` on `company`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Company' where `service`.`name` = 'Tax' and `payment`.`id` = 89243 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 1 - 2025-03-18 07:11:59 [1.38ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 2 - 2025-03-18 07:11:59 [0.16ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 3 - 2025-03-18 07:11:59 [0.42ms] */
select * from `userprofiles` where `userprofiles`.`user_id` = 149 and `userprofiles`.`user_id` is not null and `userprofiles`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 4 - 2025-03-18 07:11:59 [11.41ms] */
update `userprofiles` set `login_count` = 6340, `last_login` = '2025-03-18 07:11:59', `userprofiles`.`updated_at` = '2025-03-18 07:11:59' where `id` = 149;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 5 - 2025-03-18 07:11:59 [0.33ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 6 - 2025-03-18 07:11:59 [0.73ms] */
select column_name as `column_name` from information_schema.columns where table_schema = 'prod_rta_temp' and table_name = 'roles';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 7 - 2025-03-18 07:11:59 [0.24ms] */
select `id`, `name`, `model_has_roles`.`model_id` as `pivot_model_id`, `model_has_roles`.`role_id` as `pivot_role_id`, `model_has_roles`.`model_type` as `pivot_model_type` from `roles` inner join `model_has_roles` on `roles`.`id` = `model_has_roles`.`role_id` where `model_has_roles`.`model_id` in (149) and `model_has_roles`.`model_type` = 'App\Models\User';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 8 - 2025-03-18 07:11:59 [0.21ms] */
select exists(select * from `oauth_personal_access_clients`) as `exists`;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 9 - 2025-03-18 07:11:59 [0.18ms] */
select * from `oauth_personal_access_clients` order by `id` desc limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 10 - 2025-03-18 07:11:59 [0.24ms] */
select * from `oauth_clients` where `oauth_clients`.`id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 11 - 2025-03-18 07:11:59 [0.22ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 12 - 2025-03-18 07:11:59 [0.2ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 13 - 2025-03-18 07:11:59 [3.29ms] */
insert into `oauth_access_tokens` (`id`, `user_id`, `client_id`, `scopes`, `revoked`, `created_at`, `updated_at`, `expires_at`) values ('1ccd2f93c0c706ccde861af5f0b68b487f596ef0f296fd7de59331f7b05b0e203fa560a072195c8a', 149, 5, '[]', 0, '2025-03-18 07:11:59', '2025-03-18 07:11:59', '2026-03-18 07:11:59');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 14 - 2025-03-18 07:11:59 [0.28ms] */
select * from `oauth_access_tokens` where `id` = '1ccd2f93c0c706ccde861af5f0b68b487f596ef0f296fd7de59331f7b05b0e203fa560a072195c8a' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 15 - 2025-03-18 07:11:59 [3.06ms] */
update `oauth_access_tokens` set `name` = 'Secret' where `id` = '1ccd2f93c0c706ccde861af5f0b68b487f596ef0f296fd7de59331f7b05b0e203fa560a072195c8a';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 1 - 2025-03-18 07:12:00 [2.27ms] */
select * from `oauth_access_tokens` where `id` = '1ccd2f93c0c706ccde861af5f0b68b487f596ef0f296fd7de59331f7b05b0e203fa560a072195c8a' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 2 - 2025-03-18 07:12:00 [0.27ms] */
select * from `oauth_access_tokens` where `id` = '1ccd2f93c0c706ccde861af5f0b68b487f596ef0f296fd7de59331f7b05b0e203fa560a072195c8a' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 3 - 2025-03-18 07:12:00 [0.26ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 4 - 2025-03-18 07:12:00 [0.29ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 5 - 2025-03-18 07:12:00 [0.23ms] */
select * from `oauth_access_tokens` where `id` = '1ccd2f93c0c706ccde861af5f0b68b487f596ef0f296fd7de59331f7b05b0e203fa560a072195c8a' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 6 - 2025-03-18 07:12:00 [0.21ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 7 - 2025-03-18 07:12:00 [0.51ms] */
select DISTINCT payment.id as payment_id, `party`.`id` as `customer_id`, CASE
                WHEN person.id IS NOT NULL THEN CONCAT(person.first_name, " ", person.second_name, " ", person.third_name, " ", person.fourth_name)
                WHEN company.id IS NOT NULL THEN company.company_name
                ELSE "No Entity Found"
                END AS customer_name, `vehicle`.`license_plate`, `payment`.`payment_amount`, `external_payment_reference_no` as `payment_reference_number`, `payment`.`payment_date`, `payment_method`.`name` as `payment_method`, `payment`.`paid_by`, `payment`.`paid_by_mobile` from `payment` left join `invoice_payment` on `invoice_payment`.`payment_id` = `payment`.`id` left join `invoice` on `invoice_payment`.`invoice_id` = `invoice`.`id` and `invoice`.`parent` = 'N' left join `transaction` on `transaction`.`invoice_id` = `invoice`.`id` left join `service` on `transaction`.`service_id` = `service`.`id` left join `vehicle` on `transaction`.`vehicle_id` = `vehicle`.`id` left join `party` on `transaction`.`party_id` = `party`.`id` left join `payment_method` on `payment`.`payment_method_id` = `payment_method`.`id` left join `person` on `person`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Person' left join `company` on `company`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Company' where `service`.`name` = 'Tax' and `payment`.`id` = 89243 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 1 - 2025-03-18 07:12:28 [1.41ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 2 - 2025-03-18 07:12:28 [0.16ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 3 - 2025-03-18 07:12:28 [0.38ms] */
select * from `userprofiles` where `userprofiles`.`user_id` = 149 and `userprofiles`.`user_id` is not null and `userprofiles`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 4 - 2025-03-18 07:12:28 [12.03ms] */
update `userprofiles` set `login_count` = 6341, `last_login` = '2025-03-18 07:12:28', `userprofiles`.`updated_at` = '2025-03-18 07:12:28' where `id` = 149;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 5 - 2025-03-18 07:12:28 [0.33ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 6 - 2025-03-18 07:12:28 [0.7ms] */
select column_name as `column_name` from information_schema.columns where table_schema = 'prod_rta_temp' and table_name = 'roles';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 7 - 2025-03-18 07:12:28 [0.33ms] */
select `id`, `name`, `model_has_roles`.`model_id` as `pivot_model_id`, `model_has_roles`.`role_id` as `pivot_role_id`, `model_has_roles`.`model_type` as `pivot_model_type` from `roles` inner join `model_has_roles` on `roles`.`id` = `model_has_roles`.`role_id` where `model_has_roles`.`model_id` in (149) and `model_has_roles`.`model_type` = 'App\Models\User';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 8 - 2025-03-18 07:12:28 [0.13ms] */
select exists(select * from `oauth_personal_access_clients`) as `exists`;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 9 - 2025-03-18 07:12:28 [0.12ms] */
select * from `oauth_personal_access_clients` order by `id` desc limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 10 - 2025-03-18 07:12:28 [0.14ms] */
select * from `oauth_clients` where `oauth_clients`.`id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 11 - 2025-03-18 07:12:28 [0.14ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 12 - 2025-03-18 07:12:28 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 13 - 2025-03-18 07:12:28 [4.79ms] */
insert into `oauth_access_tokens` (`id`, `user_id`, `client_id`, `scopes`, `revoked`, `created_at`, `updated_at`, `expires_at`) values ('6b38377176f5b45a2adbd4be367076e47afcc9a3756dcafec246db65849902a045f4a6dd271ce817', 149, 5, '[]', 0, '2025-03-18 07:12:28', '2025-03-18 07:12:28', '2026-03-18 07:12:28');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 14 - 2025-03-18 07:12:28 [0.27ms] */
select * from `oauth_access_tokens` where `id` = '6b38377176f5b45a2adbd4be367076e47afcc9a3756dcafec246db65849902a045f4a6dd271ce817' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 15 - 2025-03-18 07:12:28 [2.89ms] */
update `oauth_access_tokens` set `name` = 'Secret' where `id` = '6b38377176f5b45a2adbd4be367076e47afcc9a3756dcafec246db65849902a045f4a6dd271ce817';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 1 - 2025-03-18 07:12:29 [3.03ms] */
select * from `oauth_access_tokens` where `id` = '6b38377176f5b45a2adbd4be367076e47afcc9a3756dcafec246db65849902a045f4a6dd271ce817' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 2 - 2025-03-18 07:12:29 [0.31ms] */
select * from `oauth_access_tokens` where `id` = '6b38377176f5b45a2adbd4be367076e47afcc9a3756dcafec246db65849902a045f4a6dd271ce817' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 3 - 2025-03-18 07:12:29 [0.28ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 4 - 2025-03-18 07:12:29 [0.19ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 5 - 2025-03-18 07:12:29 [0.14ms] */
select * from `oauth_access_tokens` where `id` = '6b38377176f5b45a2adbd4be367076e47afcc9a3756dcafec246db65849902a045f4a6dd271ce817' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 6 - 2025-03-18 07:12:29 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 7 - 2025-03-18 07:12:29 [0.36ms] */
select DISTINCT payment.id as payment_id, `party`.`id` as `customer_id`, CASE
                WHEN person.id IS NOT NULL THEN CONCAT(person.first_name, " ", person.second_name, " ", person.third_name, " ", person.fourth_name)
                WHEN company.id IS NOT NULL THEN company.company_name
                ELSE "No Entity Found"
                END AS customer_name, `vehicle`.`license_plate`, `payment`.`payment_amount`, `external_payment_reference_no` as `payment_reference_number`, `payment`.`payment_date`, `payment_method`.`name` as `payment_method`, `payment`.`paid_by`, `payment`.`paid_by_mobile` from `payment` left join `invoice_payment` on `invoice_payment`.`payment_id` = `payment`.`id` left join `invoice` on `invoice_payment`.`invoice_id` = `invoice`.`id` and `invoice`.`parent` = 'N' left join `transaction` on `transaction`.`invoice_id` = `invoice`.`id` left join `service` on `transaction`.`service_id` = `service`.`id` left join `vehicle` on `transaction`.`vehicle_id` = `vehicle`.`id` left join `party` on `transaction`.`party_id` = `party`.`id` left join `payment_method` on `payment`.`payment_method_id` = `payment_method`.`id` left join `person` on `person`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Person' left join `company` on `company`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Company' where `service`.`name` = 'Tax' and `payment`.`id` = 89243 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 1 - 2025-03-18 07:13:34 [1.48ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 2 - 2025-03-18 07:13:34 [0.17ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 3 - 2025-03-18 07:13:34 [0.37ms] */
select * from `userprofiles` where `userprofiles`.`user_id` = 149 and `userprofiles`.`user_id` is not null and `userprofiles`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 4 - 2025-03-18 07:13:34 [11.34ms] */
update `userprofiles` set `login_count` = 6342, `last_login` = '2025-03-18 07:13:34', `userprofiles`.`updated_at` = '2025-03-18 07:13:34' where `id` = 149;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 5 - 2025-03-18 07:13:34 [0.28ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 6 - 2025-03-18 07:13:34 [0.57ms] */
select column_name as `column_name` from information_schema.columns where table_schema = 'prod_rta_temp' and table_name = 'roles';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 7 - 2025-03-18 07:13:34 [0.24ms] */
select `id`, `name`, `model_has_roles`.`model_id` as `pivot_model_id`, `model_has_roles`.`role_id` as `pivot_role_id`, `model_has_roles`.`model_type` as `pivot_model_type` from `roles` inner join `model_has_roles` on `roles`.`id` = `model_has_roles`.`role_id` where `model_has_roles`.`model_id` in (149) and `model_has_roles`.`model_type` = 'App\Models\User';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 8 - 2025-03-18 07:13:34 [0.2ms] */
select exists(select * from `oauth_personal_access_clients`) as `exists`;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 9 - 2025-03-18 07:13:34 [0.18ms] */
select * from `oauth_personal_access_clients` order by `id` desc limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 10 - 2025-03-18 07:13:34 [0.22ms] */
select * from `oauth_clients` where `oauth_clients`.`id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 11 - 2025-03-18 07:13:34 [0.22ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 12 - 2025-03-18 07:13:34 [0.24ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 13 - 2025-03-18 07:13:34 [3.16ms] */
insert into `oauth_access_tokens` (`id`, `user_id`, `client_id`, `scopes`, `revoked`, `created_at`, `updated_at`, `expires_at`) values ('ad127c71fffe74d2c8bcd7b714b29dc513cfbbbd4e7024a5e738b6a7dcb318061e37a7aa40feb733', 149, 5, '[]', 0, '2025-03-18 07:13:34', '2025-03-18 07:13:34', '2026-03-18 07:13:34');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 14 - 2025-03-18 07:13:34 [0.27ms] */
select * from `oauth_access_tokens` where `id` = 'ad127c71fffe74d2c8bcd7b714b29dc513cfbbbd4e7024a5e738b6a7dcb318061e37a7aa40feb733' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 15 - 2025-03-18 07:13:34 [2.91ms] */
update `oauth_access_tokens` set `name` = 'Secret' where `id` = 'ad127c71fffe74d2c8bcd7b714b29dc513cfbbbd4e7024a5e738b6a7dcb318061e37a7aa40feb733';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 1 - 2025-03-18 07:13:34 [2.59ms] */
select * from `oauth_access_tokens` where `id` = 'ad127c71fffe74d2c8bcd7b714b29dc513cfbbbd4e7024a5e738b6a7dcb318061e37a7aa40feb733' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 2 - 2025-03-18 07:13:34 [0.3ms] */
select * from `oauth_access_tokens` where `id` = 'ad127c71fffe74d2c8bcd7b714b29dc513cfbbbd4e7024a5e738b6a7dcb318061e37a7aa40feb733' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 3 - 2025-03-18 07:13:34 [0.27ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 4 - 2025-03-18 07:13:34 [0.17ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 5 - 2025-03-18 07:13:34 [0.14ms] */
select * from `oauth_access_tokens` where `id` = 'ad127c71fffe74d2c8bcd7b714b29dc513cfbbbd4e7024a5e738b6a7dcb318061e37a7aa40feb733' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 6 - 2025-03-18 07:13:34 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 7 - 2025-03-18 07:13:34 [0.3ms] */
select DISTINCT payment.id as payment_id, `party`.`id` as `customer_id`, CASE
                WHEN person.id IS NOT NULL THEN CONCAT(person.first_name, " ", person.second_name, " ", person.third_name, " ", person.fourth_name)
                WHEN company.id IS NOT NULL THEN company.company_name
                ELSE "No Entity Found"
                END AS customer_name, `vehicle`.`license_plate`, `payment`.`payment_amount`, `external_payment_reference_no` as `payment_reference_number`, `payment`.`payment_date`, `payment_method`.`name` as `payment_method`, `payment`.`paid_by`, `payment`.`paid_by_mobile` from `payment` left join `invoice_payment` on `invoice_payment`.`payment_id` = `payment`.`id` left join `invoice` on `invoice_payment`.`invoice_id` = `invoice`.`id` and `invoice`.`parent` = 'N' left join `transaction` on `transaction`.`invoice_id` = `invoice`.`id` left join `service` on `transaction`.`service_id` = `service`.`id` left join `vehicle` on `transaction`.`vehicle_id` = `vehicle`.`id` left join `party` on `transaction`.`party_id` = `party`.`id` left join `payment_method` on `payment`.`payment_method_id` = `payment_method`.`id` left join `person` on `person`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Person' left join `company` on `company`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Company' where `service`.`name` = 'Tax' and `payment`.`id` = 89243 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 1 - 2025-03-18 07:14:41 [1.66ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 2 - 2025-03-18 07:14:41 [0.27ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 3 - 2025-03-18 07:14:41 [0.43ms] */
select * from `userprofiles` where `userprofiles`.`user_id` = 149 and `userprofiles`.`user_id` is not null and `userprofiles`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 4 - 2025-03-18 07:14:41 [6.01ms] */
update `userprofiles` set `login_count` = 6343, `last_login` = '2025-03-18 07:14:41', `userprofiles`.`updated_at` = '2025-03-18 07:14:41' where `id` = 149;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 5 - 2025-03-18 07:14:41 [0.19ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 6 - 2025-03-18 07:14:41 [0.56ms] */
select column_name as `column_name` from information_schema.columns where table_schema = 'prod_rta_temp' and table_name = 'roles';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 7 - 2025-03-18 07:14:41 [0.25ms] */
select `id`, `name`, `model_has_roles`.`model_id` as `pivot_model_id`, `model_has_roles`.`role_id` as `pivot_role_id`, `model_has_roles`.`model_type` as `pivot_model_type` from `roles` inner join `model_has_roles` on `roles`.`id` = `model_has_roles`.`role_id` where `model_has_roles`.`model_id` in (149) and `model_has_roles`.`model_type` = 'App\Models\User';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 8 - 2025-03-18 07:14:41 [0.16ms] */
select exists(select * from `oauth_personal_access_clients`) as `exists`;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 9 - 2025-03-18 07:14:41 [0.12ms] */
select * from `oauth_personal_access_clients` order by `id` desc limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 10 - 2025-03-18 07:14:41 [0.14ms] */
select * from `oauth_clients` where `oauth_clients`.`id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 11 - 2025-03-18 07:14:41 [0.14ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 12 - 2025-03-18 07:14:41 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 13 - 2025-03-18 07:14:41 [3.42ms] */
insert into `oauth_access_tokens` (`id`, `user_id`, `client_id`, `scopes`, `revoked`, `created_at`, `updated_at`, `expires_at`) values ('40eb75dd2022c9bfe42aa268848b3903ac35ef59565bd17c0359b048b4ab8a01b1dd3d477ec0e3c1', 149, 5, '[]', 0, '2025-03-18 07:14:41', '2025-03-18 07:14:41', '2026-03-18 07:14:41');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 14 - 2025-03-18 07:14:41 [0.67ms] */
select * from `oauth_access_tokens` where `id` = '40eb75dd2022c9bfe42aa268848b3903ac35ef59565bd17c0359b048b4ab8a01b1dd3d477ec0e3c1' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 15 - 2025-03-18 07:14:41 [5.61ms] */
update `oauth_access_tokens` set `name` = 'Secret' where `id` = '40eb75dd2022c9bfe42aa268848b3903ac35ef59565bd17c0359b048b4ab8a01b1dd3d477ec0e3c1';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 1 - 2025-03-18 07:14:47 [2.25ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 2 - 2025-03-18 07:14:47 [0.19ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 3 - 2025-03-18 07:14:47 [0.38ms] */
select * from `userprofiles` where `userprofiles`.`user_id` = 149 and `userprofiles`.`user_id` is not null and `userprofiles`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 4 - 2025-03-18 07:14:47 [11.62ms] */
update `userprofiles` set `login_count` = 6344, `last_login` = '2025-03-18 07:14:47', `userprofiles`.`updated_at` = '2025-03-18 07:14:47' where `id` = 149;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 5 - 2025-03-18 07:14:47 [0.32ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 6 - 2025-03-18 07:14:47 [0.7ms] */
select column_name as `column_name` from information_schema.columns where table_schema = 'prod_rta_temp' and table_name = 'roles';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 7 - 2025-03-18 07:14:47 [0.3ms] */
select `id`, `name`, `model_has_roles`.`model_id` as `pivot_model_id`, `model_has_roles`.`role_id` as `pivot_role_id`, `model_has_roles`.`model_type` as `pivot_model_type` from `roles` inner join `model_has_roles` on `roles`.`id` = `model_has_roles`.`role_id` where `model_has_roles`.`model_id` in (149) and `model_has_roles`.`model_type` = 'App\Models\User';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 8 - 2025-03-18 07:14:47 [0.13ms] */
select exists(select * from `oauth_personal_access_clients`) as `exists`;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 9 - 2025-03-18 07:14:47 [0.11ms] */
select * from `oauth_personal_access_clients` order by `id` desc limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 10 - 2025-03-18 07:14:47 [0.14ms] */
select * from `oauth_clients` where `oauth_clients`.`id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 11 - 2025-03-18 07:14:47 [0.14ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 12 - 2025-03-18 07:14:47 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 13 - 2025-03-18 07:14:47 [3.33ms] */
insert into `oauth_access_tokens` (`id`, `user_id`, `client_id`, `scopes`, `revoked`, `created_at`, `updated_at`, `expires_at`) values ('e9a55cdf2b2089a873ff341713090c2b028f690cbaa7d94422c3aef0b1360b5da2fc534e17db3bd8', 149, 5, '[]', 0, '2025-03-18 07:14:47', '2025-03-18 07:14:47', '2026-03-18 07:14:47');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 14 - 2025-03-18 07:14:47 [0.26ms] */
select * from `oauth_access_tokens` where `id` = 'e9a55cdf2b2089a873ff341713090c2b028f690cbaa7d94422c3aef0b1360b5da2fc534e17db3bd8' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 15 - 2025-03-18 07:14:47 [3ms] */
update `oauth_access_tokens` set `name` = 'Secret' where `id` = 'e9a55cdf2b2089a873ff341713090c2b028f690cbaa7d94422c3aef0b1360b5da2fc534e17db3bd8';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/invoices
   Query 1 - 2025-03-18 07:14:48 [1.53ms] */
select * from `oauth_access_tokens` where `id` = 'e9a55cdf2b2089a873ff341713090c2b028f690cbaa7d94422c3aef0b1360b5da2fc534e17db3bd8' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/invoices
   Query 2 - 2025-03-18 07:14:48 [0.14ms] */
select * from `oauth_access_tokens` where `id` = 'e9a55cdf2b2089a873ff341713090c2b028f690cbaa7d94422c3aef0b1360b5da2fc534e17db3bd8' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/invoices
   Query 3 - 2025-03-18 07:14:48 [0.14ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/invoices
   Query 4 - 2025-03-18 07:14:48 [0.17ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/invoices
   Query 5 - 2025-03-18 07:14:48 [0.14ms] */
select * from `oauth_access_tokens` where `id` = 'e9a55cdf2b2089a873ff341713090c2b028f690cbaa7d94422c3aef0b1360b5da2fc534e17db3bd8' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/invoices
   Query 6 - 2025-03-18 07:14:48 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/invoices
   Query 7 - 2025-03-18 07:14:48 [0.34ms] */
select `invoice`.`id` as `invoice_id`, `invoice_number`, `term`.`year`, `term`.`quarter`, `invoice`.`transaction_id`, `party`.`id` as `customer_id`, CASE
                WHEN person.id IS NOT NULL THEN CONCAT(person.first_name, " ", person.second_name, " ", person.third_name, " ", person.fourth_name)
                WHEN company.id IS NOT NULL THEN company.company_name
                ELSE "No Entity Found"
                END AS customer_name, CASE
                WHEN party.phone_number_2 IS NOT NULL THEN CONCAT(party.phone_number_1," / ",party.phone_number_2)
                ELSE party.phone_number_1 END as mobile_number, `vehicle`.`license_plate`, `service`.`name` as `service_name`, `invoice`.`due_date`, `invoice`.`total_invoice_amount` as `invoice_amount`, `invoice`.`status`, `invoice`.`parent`, `invoice`.`created_at`, `invoice`.`updated_at`, CASE WHEN invoice_payment.id IS NULL THEN "Y" ELSE "N" END as make_payment from `invoice` left join `party` on `invoice`.`party_id` = `party`.`id` left join `person` on `person`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Person' left join `company` on `company`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Company' left join `transaction` on `invoice`.`transaction_id` = `transaction`.`id` left join `vehicle_tax` on `transaction`.`vehicle_tax_id` = `vehicle_tax`.`id` left join `term` on `vehicle_tax`.`term_id` = `term`.`id` left join `vehicle` on `transaction`.`vehicle_id` = `vehicle`.`id` left join `service` on `transaction`.`service_id` = `service`.`id` left join `invoice_payment` on `invoice_payment`.`invoice_id` = `invoice`.`id` where `invoice`.`total_invoice_amount` > 0 and `service`.`name` = 'Tax' and `vehicle_tax`.`exempt` = 'N' and `transaction`.`vehicle_tax_id` is not null and `invoice`.`parent` = 'N' and `invoice`.`party_id` = 39526 and `license_plate` = 'LI574' and `invoice`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 1 - 2025-03-18 07:15:04 [2.37ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 2 - 2025-03-18 07:15:04 [0.17ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 3 - 2025-03-18 07:15:04 [0.39ms] */
select * from `userprofiles` where `userprofiles`.`user_id` = 149 and `userprofiles`.`user_id` is not null and `userprofiles`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 4 - 2025-03-18 07:15:04 [11.04ms] */
update `userprofiles` set `login_count` = 6345, `last_login` = '2025-03-18 07:15:04', `userprofiles`.`updated_at` = '2025-03-18 07:15:04' where `id` = 149;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 5 - 2025-03-18 07:15:04 [0.26ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 6 - 2025-03-18 07:15:04 [0.56ms] */
select column_name as `column_name` from information_schema.columns where table_schema = 'prod_rta_temp' and table_name = 'roles';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 7 - 2025-03-18 07:15:04 [0.24ms] */
select `id`, `name`, `model_has_roles`.`model_id` as `pivot_model_id`, `model_has_roles`.`role_id` as `pivot_role_id`, `model_has_roles`.`model_type` as `pivot_model_type` from `roles` inner join `model_has_roles` on `roles`.`id` = `model_has_roles`.`role_id` where `model_has_roles`.`model_id` in (149) and `model_has_roles`.`model_type` = 'App\Models\User';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 8 - 2025-03-18 07:15:04 [0.2ms] */
select exists(select * from `oauth_personal_access_clients`) as `exists`;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 9 - 2025-03-18 07:15:04 [0.17ms] */
select * from `oauth_personal_access_clients` order by `id` desc limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 10 - 2025-03-18 07:15:04 [0.21ms] */
select * from `oauth_clients` where `oauth_clients`.`id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 11 - 2025-03-18 07:15:04 [0.21ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 12 - 2025-03-18 07:15:04 [0.2ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 13 - 2025-03-18 07:15:04 [3.27ms] */
insert into `oauth_access_tokens` (`id`, `user_id`, `client_id`, `scopes`, `revoked`, `created_at`, `updated_at`, `expires_at`) values ('52fa5382d5525ebd68d3f32c0a283df2b2ac9f00324203b97a6198d9d2dc64f284cb1f022659ebce', 149, 5, '[]', 0, '2025-03-18 07:15:04', '2025-03-18 07:15:04', '2026-03-18 07:15:04');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 14 - 2025-03-18 07:15:04 [0.24ms] */
select * from `oauth_access_tokens` where `id` = '52fa5382d5525ebd68d3f32c0a283df2b2ac9f00324203b97a6198d9d2dc64f284cb1f022659ebce' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 15 - 2025-03-18 07:15:04 [2.91ms] */
update `oauth_access_tokens` set `name` = 'Secret' where `id` = '52fa5382d5525ebd68d3f32c0a283df2b2ac9f00324203b97a6198d9d2dc64f284cb1f022659ebce';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/invoice
   Query 1 - 2025-03-18 07:15:04 [2.53ms] */
select * from `oauth_access_tokens` where `id` = '52fa5382d5525ebd68d3f32c0a283df2b2ac9f00324203b97a6198d9d2dc64f284cb1f022659ebce' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/invoice
   Query 2 - 2025-03-18 07:15:04 [0.29ms] */
select * from `oauth_access_tokens` where `id` = '52fa5382d5525ebd68d3f32c0a283df2b2ac9f00324203b97a6198d9d2dc64f284cb1f022659ebce' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/invoice
   Query 3 - 2025-03-18 07:15:04 [0.27ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/invoice
   Query 4 - 2025-03-18 07:15:04 [0.17ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/invoice
   Query 5 - 2025-03-18 07:15:04 [0.13ms] */
select * from `oauth_access_tokens` where `id` = '52fa5382d5525ebd68d3f32c0a283df2b2ac9f00324203b97a6198d9d2dc64f284cb1f022659ebce' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/invoice
   Query 6 - 2025-03-18 07:15:04 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/invoice
   Query 7 - 2025-03-18 07:15:05 [58.38ms] */
select `invoice`.`invoice_number`, `invoice`.`invoice_date` as `issue_date`, `invoice`.`due_date`, `invoice`.`status`, CASE
                WHEN person.id IS NOT NULL THEN CONCAT(person.first_name, " ", person.second_name, " ", person.third_name, " ", person.fourth_name)
                WHEN company.id IS NOT NULL THEN company.company_name
                ELSE "No Entity Found"
                END AS customer_name, CASE
                WHEN party.phone_number_2 IS NOT NULL THEN CONCAT(party.phone_number_1," / ",party.phone_number_2)
                ELSE party.phone_number_1 END as mobile_number, `invoice`.`total_invoice_amount`, `roles`.`name` as `role`, CASE WHEN invoice_payment.id IS NULL THEN "Y" ELSE "N" END as make_payment from `invoice` left join `party` on `invoice`.`party_id` = `party`.`id` left join `person` on `person`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Person' left join `company` on `company`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Company' left join `transaction` on `transaction`.`invoice_id` = `invoice`.`id` left join `workflow_definition` on `transaction`.`current_workflow_state_id` = `workflow_definition`.`id` left join `roles` on `workflow_definition`.`role_id` = `roles`.`id` left join `invoice_payment` on `invoice_payment`.`invoice_id` = `invoice`.`id` where `invoice`.`id` = 174954 and `invoice`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/invoice
   Query 8 - 2025-03-18 07:15:05 [0.73ms] */
select `id`, `item`, `description`, `quantity`, `unit_price`, `total_price` from `invoice_item` where `invoice_id` = 174954 and `invoice_item`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 1 - 2025-03-18 07:15:44 [1.41ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 2 - 2025-03-18 07:15:44 [0.17ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 3 - 2025-03-18 07:15:44 [0.45ms] */
select * from `userprofiles` where `userprofiles`.`user_id` = 149 and `userprofiles`.`user_id` is not null and `userprofiles`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 4 - 2025-03-18 07:15:44 [11.26ms] */
update `userprofiles` set `login_count` = 6346, `last_login` = '2025-03-18 07:15:44', `userprofiles`.`updated_at` = '2025-03-18 07:15:44' where `id` = 149;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 5 - 2025-03-18 07:15:44 [0.45ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 6 - 2025-03-18 07:15:44 [0.77ms] */
select column_name as `column_name` from information_schema.columns where table_schema = 'prod_rta_temp' and table_name = 'roles';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 7 - 2025-03-18 07:15:44 [0.3ms] */
select `id`, `name`, `model_has_roles`.`model_id` as `pivot_model_id`, `model_has_roles`.`role_id` as `pivot_role_id`, `model_has_roles`.`model_type` as `pivot_model_type` from `roles` inner join `model_has_roles` on `roles`.`id` = `model_has_roles`.`role_id` where `model_has_roles`.`model_id` in (149) and `model_has_roles`.`model_type` = 'App\Models\User';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 8 - 2025-03-18 07:15:44 [0.17ms] */
select exists(select * from `oauth_personal_access_clients`) as `exists`;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 9 - 2025-03-18 07:15:44 [0.12ms] */
select * from `oauth_personal_access_clients` order by `id` desc limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 10 - 2025-03-18 07:15:44 [0.15ms] */
select * from `oauth_clients` where `oauth_clients`.`id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 11 - 2025-03-18 07:15:44 [0.16ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 12 - 2025-03-18 07:15:44 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 13 - 2025-03-18 07:15:44 [3.36ms] */
insert into `oauth_access_tokens` (`id`, `user_id`, `client_id`, `scopes`, `revoked`, `created_at`, `updated_at`, `expires_at`) values ('cc0d32a9c6f45ba9caad924391926431c511b78f68daa2b8117e855df0cc5e56ad0ac604ec2cc31d', 149, 5, '[]', 0, '2025-03-18 07:15:44', '2025-03-18 07:15:44', '2026-03-18 07:15:44');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 14 - 2025-03-18 07:15:44 [0.29ms] */
select * from `oauth_access_tokens` where `id` = 'cc0d32a9c6f45ba9caad924391926431c511b78f68daa2b8117e855df0cc5e56ad0ac604ec2cc31d' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 15 - 2025-03-18 07:15:44 [4.55ms] */
update `oauth_access_tokens` set `name` = 'Secret' where `id` = 'cc0d32a9c6f45ba9caad924391926431c511b78f68daa2b8117e855df0cc5e56ad0ac604ec2cc31d';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 1 - 2025-03-18 07:15:48 [1.45ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 2 - 2025-03-18 07:15:48 [0.18ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 3 - 2025-03-18 07:15:48 [0.38ms] */
select * from `userprofiles` where `userprofiles`.`user_id` = 149 and `userprofiles`.`user_id` is not null and `userprofiles`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 4 - 2025-03-18 07:15:48 [11.15ms] */
update `userprofiles` set `login_count` = 6347, `last_login` = '2025-03-18 07:15:48', `userprofiles`.`updated_at` = '2025-03-18 07:15:48' where `id` = 149;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 5 - 2025-03-18 07:15:48 [0.32ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 6 - 2025-03-18 07:15:48 [0.7ms] */
select column_name as `column_name` from information_schema.columns where table_schema = 'prod_rta_temp' and table_name = 'roles';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 7 - 2025-03-18 07:15:48 [0.34ms] */
select `id`, `name`, `model_has_roles`.`model_id` as `pivot_model_id`, `model_has_roles`.`role_id` as `pivot_role_id`, `model_has_roles`.`model_type` as `pivot_model_type` from `roles` inner join `model_has_roles` on `roles`.`id` = `model_has_roles`.`role_id` where `model_has_roles`.`model_id` in (149) and `model_has_roles`.`model_type` = 'App\Models\User';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 8 - 2025-03-18 07:15:48 [0.13ms] */
select exists(select * from `oauth_personal_access_clients`) as `exists`;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 9 - 2025-03-18 07:15:48 [0.11ms] */
select * from `oauth_personal_access_clients` order by `id` desc limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 10 - 2025-03-18 07:15:48 [0.14ms] */
select * from `oauth_clients` where `oauth_clients`.`id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 11 - 2025-03-18 07:15:48 [0.14ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 12 - 2025-03-18 07:15:48 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 13 - 2025-03-18 07:15:48 [3.3ms] */
insert into `oauth_access_tokens` (`id`, `user_id`, `client_id`, `scopes`, `revoked`, `created_at`, `updated_at`, `expires_at`) values ('f78b9c8a32fea08be70ccb8db4fefda18042d514dbf35d7b336dfd126ad734a9b02b0add5a111a96', 149, 5, '[]', 0, '2025-03-18 07:15:48', '2025-03-18 07:15:48', '2026-03-18 07:15:48');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 14 - 2025-03-18 07:15:48 [0.25ms] */
select * from `oauth_access_tokens` where `id` = 'f78b9c8a32fea08be70ccb8db4fefda18042d514dbf35d7b336dfd126ad734a9b02b0add5a111a96' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 15 - 2025-03-18 07:15:48 [2.92ms] */
update `oauth_access_tokens` set `name` = 'Secret' where `id` = 'f78b9c8a32fea08be70ccb8db4fefda18042d514dbf35d7b336dfd126ad734a9b02b0add5a111a96';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 1 - 2025-03-18 07:15:49 [2.22ms] */
select * from `oauth_access_tokens` where `id` = 'f78b9c8a32fea08be70ccb8db4fefda18042d514dbf35d7b336dfd126ad734a9b02b0add5a111a96' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 2 - 2025-03-18 07:15:49 [0.26ms] */
select * from `oauth_access_tokens` where `id` = 'f78b9c8a32fea08be70ccb8db4fefda18042d514dbf35d7b336dfd126ad734a9b02b0add5a111a96' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 3 - 2025-03-18 07:15:49 [0.27ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 4 - 2025-03-18 07:15:49 [0.36ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 5 - 2025-03-18 07:15:49 [0.16ms] */
select * from `oauth_access_tokens` where `id` = 'f78b9c8a32fea08be70ccb8db4fefda18042d514dbf35d7b336dfd126ad734a9b02b0add5a111a96' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 6 - 2025-03-18 07:15:49 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 7 - 2025-03-18 07:15:49 [0.33ms] */
select `vehicle`.`id` as `vehicle_id`, `party`.`id` as `party_id`, `vehicle`.`license_plate`, `vehicle`.`year`, `vehicle`.`odometer`, `vehicle`.`vin`, `sub_category`.`name` as `sub_category`, `classification_type`.`name` as `classification`, `make`.`name` as `make`, `model`.`name` as `model`, `vehicle_color`.`name` as `vehicle_color`, `fuel_type`.`name` as `fuel_type`, `vehicle_type`.`name` as `vehicle_type`, CASE
                WHEN party_vehicle.id IS NULL THEN "UNREGISTERED" ELSE party_vehicle.status END AS status, CASE
                WHEN person.id IS NOT NULL THEN CONCAT(person.first_name, " ", person.second_name, " ", person.third_name, " ", person.fourth_name)
                WHEN company.id IS NOT NULL THEN company.company_name
                ELSE "No Entity Found"
                END AS owner, `party`.`partyable_type` as `owner_type`, `party_vehicle`.`registration_date`, `vehicle`.`created_at`, `vehicle`.`updated_at` from `vehicle` left join `party_vehicle` on `party_vehicle`.`vehicle_id` = `vehicle`.`id` left join `sub_category` on `vehicle`.`sub_category_id` = `sub_category`.`id` left join `classification_type` on `party_vehicle`.`classification_id` = `classification_type`.`id` left join `model` on `vehicle`.`model_id` = `model`.`id` left join `make` on `model`.`make_id` = `make`.`id` left join `vehicle_color` on `vehicle`.`vehicle_color_id` = `vehicle_color`.`id` left join `fuel_type` on `vehicle`.`fuel_type_id` = `fuel_type`.`id` left join `vehicle_type` on `vehicle`.`vehicle_type_id` = `vehicle_type`.`id` left join `party` on `party_vehicle`.`party_id` = `party`.`id` left join `person` on `person`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Person' left join `company` on `company`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Company' where `license_plate` = 'LI574' and `party_vehicle`.`is_owner` = 'Y' and `vehicle`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 8 - 2025-03-18 07:15:49 [0.15ms] */
select * from `party` where `party`.`id` = 39526 and `party`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 9 - 2025-03-18 07:15:49 [0.15ms] */
select * from `vehicle` where `id` = 50459 and `provisional` = 'Y' and `vehicle`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 10 - 2025-03-18 07:15:49 [0.15ms] */
select * from `party_vehicle` where `vehicle_id` = 50459 and `is_owner` = 'Y' and `party_vehicle`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 1 - 2025-03-18 07:15:58 [1.38ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 2 - 2025-03-18 07:15:58 [0.18ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 3 - 2025-03-18 07:15:58 [0.42ms] */
select * from `userprofiles` where `userprofiles`.`user_id` = 149 and `userprofiles`.`user_id` is not null and `userprofiles`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 4 - 2025-03-18 07:15:58 [11.29ms] */
update `userprofiles` set `login_count` = 6348, `last_login` = '2025-03-18 07:15:58', `userprofiles`.`updated_at` = '2025-03-18 07:15:58' where `id` = 149;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 5 - 2025-03-18 07:15:58 [0.41ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 6 - 2025-03-18 07:15:58 [0.73ms] */
select column_name as `column_name` from information_schema.columns where table_schema = 'prod_rta_temp' and table_name = 'roles';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 7 - 2025-03-18 07:15:58 [0.25ms] */
select `id`, `name`, `model_has_roles`.`model_id` as `pivot_model_id`, `model_has_roles`.`role_id` as `pivot_role_id`, `model_has_roles`.`model_type` as `pivot_model_type` from `roles` inner join `model_has_roles` on `roles`.`id` = `model_has_roles`.`role_id` where `model_has_roles`.`model_id` in (149) and `model_has_roles`.`model_type` = 'App\Models\User';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 8 - 2025-03-18 07:15:58 [0.2ms] */
select exists(select * from `oauth_personal_access_clients`) as `exists`;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 9 - 2025-03-18 07:15:58 [0.18ms] */
select * from `oauth_personal_access_clients` order by `id` desc limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 10 - 2025-03-18 07:15:58 [0.21ms] */
select * from `oauth_clients` where `oauth_clients`.`id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 11 - 2025-03-18 07:15:58 [0.22ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 12 - 2025-03-18 07:15:58 [0.2ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 13 - 2025-03-18 07:15:58 [3.22ms] */
insert into `oauth_access_tokens` (`id`, `user_id`, `client_id`, `scopes`, `revoked`, `created_at`, `updated_at`, `expires_at`) values ('3d15b5d363a4e97bd1ab32df8ada574715f07ce6039d6da7387a30b19c7e1a7dcf134e77fdc7af13', 149, 5, '[]', 0, '2025-03-18 07:15:58', '2025-03-18 07:15:58', '2026-03-18 07:15:58');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 14 - 2025-03-18 07:15:58 [0.38ms] */
select * from `oauth_access_tokens` where `id` = '3d15b5d363a4e97bd1ab32df8ada574715f07ce6039d6da7387a30b19c7e1a7dcf134e77fdc7af13' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 15 - 2025-03-18 07:15:58 [3.05ms] */
update `oauth_access_tokens` set `name` = 'Secret' where `id` = '3d15b5d363a4e97bd1ab32df8ada574715f07ce6039d6da7387a30b19c7e1a7dcf134e77fdc7af13';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/invoices
   Query 1 - 2025-03-18 07:15:59 [1.4ms] */
select * from `oauth_access_tokens` where `id` = '3d15b5d363a4e97bd1ab32df8ada574715f07ce6039d6da7387a30b19c7e1a7dcf134e77fdc7af13' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/invoices
   Query 2 - 2025-03-18 07:15:59 [0.14ms] */
select * from `oauth_access_tokens` where `id` = '3d15b5d363a4e97bd1ab32df8ada574715f07ce6039d6da7387a30b19c7e1a7dcf134e77fdc7af13' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/invoices
   Query 3 - 2025-03-18 07:15:59 [0.14ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/invoices
   Query 4 - 2025-03-18 07:15:59 [0.18ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/invoices
   Query 5 - 2025-03-18 07:15:59 [0.15ms] */
select * from `oauth_access_tokens` where `id` = '3d15b5d363a4e97bd1ab32df8ada574715f07ce6039d6da7387a30b19c7e1a7dcf134e77fdc7af13' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/invoices
   Query 6 - 2025-03-18 07:15:59 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/invoices
   Query 7 - 2025-03-18 07:15:59 [0.33ms] */
select `invoice`.`id` as `invoice_id`, `invoice_number`, `term`.`year`, `term`.`quarter`, `invoice`.`transaction_id`, `party`.`id` as `customer_id`, CASE
                WHEN person.id IS NOT NULL THEN CONCAT(person.first_name, " ", person.second_name, " ", person.third_name, " ", person.fourth_name)
                WHEN company.id IS NOT NULL THEN company.company_name
                ELSE "No Entity Found"
                END AS customer_name, CASE
                WHEN party.phone_number_2 IS NOT NULL THEN CONCAT(party.phone_number_1," / ",party.phone_number_2)
                ELSE party.phone_number_1 END as mobile_number, `vehicle`.`license_plate`, `service`.`name` as `service_name`, `invoice`.`due_date`, `invoice`.`total_invoice_amount` as `invoice_amount`, `invoice`.`status`, `invoice`.`parent`, `invoice`.`created_at`, `invoice`.`updated_at`, CASE WHEN invoice_payment.id IS NULL THEN "Y" ELSE "N" END as make_payment from `invoice` left join `party` on `invoice`.`party_id` = `party`.`id` left join `person` on `person`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Person' left join `company` on `company`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Company' left join `transaction` on `invoice`.`transaction_id` = `transaction`.`id` left join `vehicle_tax` on `transaction`.`vehicle_tax_id` = `vehicle_tax`.`id` left join `term` on `vehicle_tax`.`term_id` = `term`.`id` left join `vehicle` on `transaction`.`vehicle_id` = `vehicle`.`id` left join `service` on `transaction`.`service_id` = `service`.`id` left join `invoice_payment` on `invoice_payment`.`invoice_id` = `invoice`.`id` where `invoice`.`total_invoice_amount` > 0 and `service`.`name` = 'Tax' and `vehicle_tax`.`exempt` = 'N' and `transaction`.`vehicle_tax_id` is not null and `invoice`.`parent` = 'N' and `invoice`.`party_id` = 39526 and `license_plate` = 'LI574' and `invoice`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 1 - 2025-03-18 07:16:34 [2.37ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 2 - 2025-03-18 07:16:34 [0.17ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 3 - 2025-03-18 07:16:34 [0.38ms] */
select * from `userprofiles` where `userprofiles`.`user_id` = 149 and `userprofiles`.`user_id` is not null and `userprofiles`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 4 - 2025-03-18 07:16:34 [6.08ms] */
update `userprofiles` set `login_count` = 6349, `last_login` = '2025-03-18 07:16:34', `userprofiles`.`updated_at` = '2025-03-18 07:16:34' where `id` = 149;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 5 - 2025-03-18 07:16:34 [0.17ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 6 - 2025-03-18 07:16:34 [0.42ms] */
select column_name as `column_name` from information_schema.columns where table_schema = 'prod_rta_temp' and table_name = 'roles';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 7 - 2025-03-18 07:16:34 [0.16ms] */
select `id`, `name`, `model_has_roles`.`model_id` as `pivot_model_id`, `model_has_roles`.`role_id` as `pivot_role_id`, `model_has_roles`.`model_type` as `pivot_model_type` from `roles` inner join `model_has_roles` on `roles`.`id` = `model_has_roles`.`role_id` where `model_has_roles`.`model_id` in (149) and `model_has_roles`.`model_type` = 'App\Models\User';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 8 - 2025-03-18 07:16:34 [0.2ms] */
select exists(select * from `oauth_personal_access_clients`) as `exists`;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 9 - 2025-03-18 07:16:34 [0.2ms] */
select * from `oauth_personal_access_clients` order by `id` desc limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 10 - 2025-03-18 07:16:34 [0.22ms] */
select * from `oauth_clients` where `oauth_clients`.`id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 11 - 2025-03-18 07:16:34 [0.22ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 12 - 2025-03-18 07:16:34 [0.2ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 13 - 2025-03-18 07:16:34 [3.53ms] */
insert into `oauth_access_tokens` (`id`, `user_id`, `client_id`, `scopes`, `revoked`, `created_at`, `updated_at`, `expires_at`) values ('d4635bd0ebd0f29eeed360b95c6631a307f3af39377f4a21a87f0631814bffd4fca081ab682c175b', 149, 5, '[]', 0, '2025-03-18 07:16:34', '2025-03-18 07:16:34', '2026-03-18 07:16:34');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 14 - 2025-03-18 07:16:34 [0.25ms] */
select * from `oauth_access_tokens` where `id` = 'd4635bd0ebd0f29eeed360b95c6631a307f3af39377f4a21a87f0631814bffd4fca081ab682c175b' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 15 - 2025-03-18 07:16:34 [2.95ms] */
update `oauth_access_tokens` set `name` = 'Secret' where `id` = 'd4635bd0ebd0f29eeed360b95c6631a307f3af39377f4a21a87f0631814bffd4fca081ab682c175b';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/invoices
   Query 1 - 2025-03-18 07:16:35 [1.49ms] */
select * from `oauth_access_tokens` where `id` = 'd4635bd0ebd0f29eeed360b95c6631a307f3af39377f4a21a87f0631814bffd4fca081ab682c175b' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/invoices
   Query 2 - 2025-03-18 07:16:35 [0.14ms] */
select * from `oauth_access_tokens` where `id` = 'd4635bd0ebd0f29eeed360b95c6631a307f3af39377f4a21a87f0631814bffd4fca081ab682c175b' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/invoices
   Query 3 - 2025-03-18 07:16:35 [0.14ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/invoices
   Query 4 - 2025-03-18 07:16:35 [0.17ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/invoices
   Query 5 - 2025-03-18 07:16:35 [0.14ms] */
select * from `oauth_access_tokens` where `id` = 'd4635bd0ebd0f29eeed360b95c6631a307f3af39377f4a21a87f0631814bffd4fca081ab682c175b' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/invoices
   Query 6 - 2025-03-18 07:16:35 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/invoices
   Query 7 - 2025-03-18 07:16:35 [0.38ms] */
select `invoice`.`id` as `invoice_id`, `invoice_number`, `term`.`year`, `term`.`quarter`, `invoice`.`transaction_id`, `party`.`id` as `customer_id`, CASE
                WHEN person.id IS NOT NULL THEN CONCAT(person.first_name, " ", person.second_name, " ", person.third_name, " ", person.fourth_name)
                WHEN company.id IS NOT NULL THEN company.company_name
                ELSE "No Entity Found"
                END AS customer_name, CASE
                WHEN party.phone_number_2 IS NOT NULL THEN CONCAT(party.phone_number_1," / ",party.phone_number_2)
                ELSE party.phone_number_1 END as mobile_number, `vehicle`.`license_plate`, `service`.`name` as `service_name`, `invoice`.`due_date`, `invoice`.`total_invoice_amount` as `invoice_amount`, `invoice`.`status`, `invoice`.`parent`, `invoice`.`created_at`, `invoice`.`updated_at`, CASE WHEN invoice_payment.id IS NULL THEN "Y" ELSE "N" END as make_payment from `invoice` left join `party` on `invoice`.`party_id` = `party`.`id` left join `person` on `person`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Person' left join `company` on `company`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Company' left join `transaction` on `invoice`.`transaction_id` = `transaction`.`id` left join `vehicle_tax` on `transaction`.`vehicle_tax_id` = `vehicle_tax`.`id` left join `term` on `vehicle_tax`.`term_id` = `term`.`id` left join `vehicle` on `transaction`.`vehicle_id` = `vehicle`.`id` left join `service` on `transaction`.`service_id` = `service`.`id` left join `invoice_payment` on `invoice_payment`.`invoice_id` = `invoice`.`id` where `invoice`.`total_invoice_amount` > 0 and `service`.`name` = 'Tax' and `vehicle_tax`.`exempt` = 'N' and `transaction`.`vehicle_tax_id` is not null and `invoice`.`parent` = 'N' and `invoice`.`party_id` = 39526 and `license_plate` = 'LI574' and `invoice`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 1 - 2025-03-18 07:16:51 [2.09ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 2 - 2025-03-18 07:16:51 [0.16ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 3 - 2025-03-18 07:16:51 [0.38ms] */
select * from `userprofiles` where `userprofiles`.`user_id` = 149 and `userprofiles`.`user_id` is not null and `userprofiles`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 4 - 2025-03-18 07:16:51 [6.03ms] */
update `userprofiles` set `login_count` = 6350, `last_login` = '2025-03-18 07:16:51', `userprofiles`.`updated_at` = '2025-03-18 07:16:51' where `id` = 149;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 5 - 2025-03-18 07:16:51 [0.23ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 6 - 2025-03-18 07:16:51 [0.55ms] */
select column_name as `column_name` from information_schema.columns where table_schema = 'prod_rta_temp' and table_name = 'roles';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 7 - 2025-03-18 07:16:51 [0.24ms] */
select `id`, `name`, `model_has_roles`.`model_id` as `pivot_model_id`, `model_has_roles`.`role_id` as `pivot_role_id`, `model_has_roles`.`model_type` as `pivot_model_type` from `roles` inner join `model_has_roles` on `roles`.`id` = `model_has_roles`.`role_id` where `model_has_roles`.`model_id` in (149) and `model_has_roles`.`model_type` = 'App\Models\User';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 8 - 2025-03-18 07:16:51 [0.13ms] */
select exists(select * from `oauth_personal_access_clients`) as `exists`;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 9 - 2025-03-18 07:16:51 [0.12ms] */
select * from `oauth_personal_access_clients` order by `id` desc limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 10 - 2025-03-18 07:16:51 [0.14ms] */
select * from `oauth_clients` where `oauth_clients`.`id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 11 - 2025-03-18 07:16:51 [0.14ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 12 - 2025-03-18 07:16:51 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 13 - 2025-03-18 07:16:51 [3.32ms] */
insert into `oauth_access_tokens` (`id`, `user_id`, `client_id`, `scopes`, `revoked`, `created_at`, `updated_at`, `expires_at`) values ('69f02b1128df6b6b3b3a3b6b11c8fa87fee78b3f8775eb2df0c734dccbd4a36855aecaaba1f809f6', 149, 5, '[]', 0, '2025-03-18 07:16:51', '2025-03-18 07:16:51', '2026-03-18 07:16:51');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 14 - 2025-03-18 07:16:51 [0.23ms] */
select * from `oauth_access_tokens` where `id` = '69f02b1128df6b6b3b3a3b6b11c8fa87fee78b3f8775eb2df0c734dccbd4a36855aecaaba1f809f6' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 15 - 2025-03-18 07:16:51 [2.94ms] */
update `oauth_access_tokens` set `name` = 'Secret' where `id` = '69f02b1128df6b6b3b3a3b6b11c8fa87fee78b3f8775eb2df0c734dccbd4a36855aecaaba1f809f6';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/invoice
   Query 1 - 2025-03-18 07:16:52 [2.14ms] */
select * from `oauth_access_tokens` where `id` = '69f02b1128df6b6b3b3a3b6b11c8fa87fee78b3f8775eb2df0c734dccbd4a36855aecaaba1f809f6' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/invoice
   Query 2 - 2025-03-18 07:16:52 [0.23ms] */
select * from `oauth_access_tokens` where `id` = '69f02b1128df6b6b3b3a3b6b11c8fa87fee78b3f8775eb2df0c734dccbd4a36855aecaaba1f809f6' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/invoice
   Query 3 - 2025-03-18 07:16:52 [0.23ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/invoice
   Query 4 - 2025-03-18 07:16:52 [0.26ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/invoice
   Query 5 - 2025-03-18 07:16:52 [0.21ms] */
select * from `oauth_access_tokens` where `id` = '69f02b1128df6b6b3b3a3b6b11c8fa87fee78b3f8775eb2df0c734dccbd4a36855aecaaba1f809f6' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/invoice
   Query 6 - 2025-03-18 07:16:52 [0.2ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/invoice
   Query 7 - 2025-03-18 07:16:52 [0.31ms] */
select `invoice`.`invoice_number`, `invoice`.`invoice_date` as `issue_date`, `invoice`.`due_date`, `invoice`.`status`, CASE
                WHEN person.id IS NOT NULL THEN CONCAT(person.first_name, " ", person.second_name, " ", person.third_name, " ", person.fourth_name)
                WHEN company.id IS NOT NULL THEN company.company_name
                ELSE "No Entity Found"
                END AS customer_name, CASE
                WHEN party.phone_number_2 IS NOT NULL THEN CONCAT(party.phone_number_1," / ",party.phone_number_2)
                ELSE party.phone_number_1 END as mobile_number, `invoice`.`total_invoice_amount`, `roles`.`name` as `role`, CASE WHEN invoice_payment.id IS NULL THEN "Y" ELSE "N" END as make_payment from `invoice` left join `party` on `invoice`.`party_id` = `party`.`id` left join `person` on `person`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Person' left join `company` on `company`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Company' left join `transaction` on `transaction`.`invoice_id` = `invoice`.`id` left join `workflow_definition` on `transaction`.`current_workflow_state_id` = `workflow_definition`.`id` left join `roles` on `workflow_definition`.`role_id` = `roles`.`id` left join `invoice_payment` on `invoice_payment`.`invoice_id` = `invoice`.`id` where `invoice`.`id` = 174954 and `invoice`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/invoice
   Query 8 - 2025-03-18 07:16:52 [0.14ms] */
select `id`, `item`, `description`, `quantity`, `unit_price`, `total_price` from `invoice_item` where `invoice_id` = 174954 and `invoice_item`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 1 - 2025-03-18 07:17:20 [2.05ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 2 - 2025-03-18 07:17:20 [0.17ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 3 - 2025-03-18 07:17:20 [0.38ms] */
select * from `userprofiles` where `userprofiles`.`user_id` = 149 and `userprofiles`.`user_id` is not null and `userprofiles`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 4 - 2025-03-18 07:17:20 [4.29ms] */
update `userprofiles` set `login_count` = 6351, `last_login` = '2025-03-18 07:17:20', `userprofiles`.`updated_at` = '2025-03-18 07:17:20' where `id` = 149;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 5 - 2025-03-18 07:17:20 [0.18ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 6 - 2025-03-18 07:17:20 [0.42ms] */
select column_name as `column_name` from information_schema.columns where table_schema = 'prod_rta_temp' and table_name = 'roles';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 7 - 2025-03-18 07:17:20 [0.15ms] */
select `id`, `name`, `model_has_roles`.`model_id` as `pivot_model_id`, `model_has_roles`.`role_id` as `pivot_role_id`, `model_has_roles`.`model_type` as `pivot_model_type` from `roles` inner join `model_has_roles` on `roles`.`id` = `model_has_roles`.`role_id` where `model_has_roles`.`model_id` in (149) and `model_has_roles`.`model_type` = 'App\Models\User';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 8 - 2025-03-18 07:17:20 [0.13ms] */
select exists(select * from `oauth_personal_access_clients`) as `exists`;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 9 - 2025-03-18 07:17:20 [0.12ms] */
select * from `oauth_personal_access_clients` order by `id` desc limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 10 - 2025-03-18 07:17:20 [0.14ms] */
select * from `oauth_clients` where `oauth_clients`.`id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 11 - 2025-03-18 07:17:20 [0.14ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 12 - 2025-03-18 07:17:20 [0.15ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 13 - 2025-03-18 07:17:20 [3.17ms] */
insert into `oauth_access_tokens` (`id`, `user_id`, `client_id`, `scopes`, `revoked`, `created_at`, `updated_at`, `expires_at`) values ('16b345999757824ac34592cc70b831c7a61ae0232e44a9aac20415090f4424d456a70647d0f6f478', 149, 5, '[]', 0, '2025-03-18 07:17:20', '2025-03-18 07:17:20', '2026-03-18 07:17:20');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 14 - 2025-03-18 07:17:20 [0.3ms] */
select * from `oauth_access_tokens` where `id` = '16b345999757824ac34592cc70b831c7a61ae0232e44a9aac20415090f4424d456a70647d0f6f478' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 15 - 2025-03-18 07:17:20 [3.49ms] */
update `oauth_access_tokens` set `name` = 'Secret' where `id` = '16b345999757824ac34592cc70b831c7a61ae0232e44a9aac20415090f4424d456a70647d0f6f478';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 1 - 2025-03-18 07:17:21 [1.5ms] */
select * from `oauth_access_tokens` where `id` = '16b345999757824ac34592cc70b831c7a61ae0232e44a9aac20415090f4424d456a70647d0f6f478' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 2 - 2025-03-18 07:17:21 [0.15ms] */
select * from `oauth_access_tokens` where `id` = '16b345999757824ac34592cc70b831c7a61ae0232e44a9aac20415090f4424d456a70647d0f6f478' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 3 - 2025-03-18 07:17:21 [0.14ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 4 - 2025-03-18 07:17:21 [0.24ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 5 - 2025-03-18 07:17:21 [0.14ms] */
select * from `oauth_access_tokens` where `id` = '16b345999757824ac34592cc70b831c7a61ae0232e44a9aac20415090f4424d456a70647d0f6f478' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 6 - 2025-03-18 07:17:21 [0.14ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 7 - 2025-03-18 07:17:21 [0.34ms] */
select DISTINCT payment.id as payment_id, `party`.`id` as `customer_id`, CASE
                WHEN person.id IS NOT NULL THEN CONCAT(person.first_name, " ", person.second_name, " ", person.third_name, " ", person.fourth_name)
                WHEN company.id IS NOT NULL THEN company.company_name
                ELSE "No Entity Found"
                END AS customer_name, `vehicle`.`license_plate`, `payment`.`payment_amount`, `external_payment_reference_no` as `payment_reference_number`, `payment`.`payment_date`, `payment_method`.`name` as `payment_method`, `payment`.`paid_by`, `payment`.`paid_by_mobile` from `payment` left join `invoice_payment` on `invoice_payment`.`payment_id` = `payment`.`id` left join `invoice` on `invoice_payment`.`invoice_id` = `invoice`.`id` and `invoice`.`parent` = 'N' left join `transaction` on `transaction`.`invoice_id` = `invoice`.`id` left join `service` on `transaction`.`service_id` = `service`.`id` left join `vehicle` on `transaction`.`vehicle_id` = `vehicle`.`id` left join `party` on `transaction`.`party_id` = `party`.`id` left join `payment_method` on `payment`.`payment_method_id` = `payment_method`.`id` left join `person` on `person`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Person' left join `company` on `company`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Company' where `service`.`name` = 'Tax' and `payment`.`id` = 89243 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 1 - 2025-03-18 07:19:21 [1.68ms] */
select * from `users` where `email` = 'userpayment@puntlandgov.org' and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 2 - 2025-03-18 07:19:21 [0.25ms] */
select * from `users` where `id` = 154 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 3 - 2025-03-18 07:19:21 [0.47ms] */
select * from `userprofiles` where `userprofiles`.`user_id` = 154 and `userprofiles`.`user_id` is not null and `userprofiles`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 4 - 2025-03-18 07:19:21 [6.47ms] */
update `userprofiles` set `login_count` = 1333, `last_login` = '2025-03-18 07:19:21', `userprofiles`.`updated_at` = '2025-03-18 07:19:21' where `id` = 154;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 5 - 2025-03-18 07:19:21 [0.55ms] */
select * from `users` where `email` = 'userpayment@puntlandgov.org' and `users`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 6 - 2025-03-18 07:19:21 [0.56ms] */
select column_name as `column_name` from information_schema.columns where table_schema = 'prod_rta_temp' and table_name = 'roles';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 7 - 2025-03-18 07:19:21 [0.63ms] */
select `id`, `name`, `model_has_roles`.`model_id` as `pivot_model_id`, `model_has_roles`.`role_id` as `pivot_role_id`, `model_has_roles`.`model_type` as `pivot_model_type` from `roles` inner join `model_has_roles` on `roles`.`id` = `model_has_roles`.`role_id` where `model_has_roles`.`model_id` in (154) and `model_has_roles`.`model_type` = 'App\Models\User';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 8 - 2025-03-18 07:19:21 [0.2ms] */
select exists(select * from `oauth_personal_access_clients`) as `exists`;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 9 - 2025-03-18 07:19:21 [0.17ms] */
select * from `oauth_personal_access_clients` order by `id` desc limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 10 - 2025-03-18 07:19:21 [0.22ms] */
select * from `oauth_clients` where `oauth_clients`.`id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 11 - 2025-03-18 07:19:21 [0.14ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 12 - 2025-03-18 07:19:21 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 13 - 2025-03-18 07:19:21 [3.75ms] */
insert into `oauth_access_tokens` (`id`, `user_id`, `client_id`, `scopes`, `revoked`, `created_at`, `updated_at`, `expires_at`) values ('a77ab371472403d60f3d9c41087bf530e9d6813850f54c42104b9da53aa6f8138c538dfc6105e86e', 154, 5, '[]', 0, '2025-03-18 07:19:21', '2025-03-18 07:19:21', '2026-03-18 07:19:21');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 14 - 2025-03-18 07:19:21 [0.54ms] */
select * from `oauth_access_tokens` where `id` = 'a77ab371472403d60f3d9c41087bf530e9d6813850f54c42104b9da53aa6f8138c538dfc6105e86e' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 15 - 2025-03-18 07:19:21 [3.63ms] */
update `oauth_access_tokens` set `name` = 'Secret' where `id` = 'a77ab371472403d60f3d9c41087bf530e9d6813850f54c42104b9da53aa6f8138c538dfc6105e86e';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/transaction
   Query 1 - 2025-03-18 07:19:21 [1.49ms] */
select * from `oauth_access_tokens` where `id` = 'a77ab371472403d60f3d9c41087bf530e9d6813850f54c42104b9da53aa6f8138c538dfc6105e86e' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/transaction
   Query 2 - 2025-03-18 07:19:21 [0.14ms] */
select * from `oauth_access_tokens` where `id` = 'a77ab371472403d60f3d9c41087bf530e9d6813850f54c42104b9da53aa6f8138c538dfc6105e86e' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/transaction
   Query 3 - 2025-03-18 07:19:21 [0.15ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/transaction
   Query 4 - 2025-03-18 07:19:21 [0.26ms] */
select * from `users` where `id` = 154 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/transaction
   Query 5 - 2025-03-18 07:19:21 [0.14ms] */
select * from `oauth_access_tokens` where `id` = 'a77ab371472403d60f3d9c41087bf530e9d6813850f54c42104b9da53aa6f8138c538dfc6105e86e' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/transaction
   Query 6 - 2025-03-18 07:19:21 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/transaction
   Query 7 - 2025-03-18 07:19:21 [0.65ms] */
select `transaction`.`id` as `transaction_id`, `invoice`.`id` as `invoice_id`, `transaction`.`party_id` as `customer_id`, `transaction`.`vehicle_id`, `invoice`.`id` as `invoice_id`, `invoice`.`invoice_number`, `invoice`.`total_invoice_amount` as `total_tax_amount`, `invoice`.`status` as `invoice_status`, `service`.`name` as `service_name`, `transaction`.`status`, `users`.`name` as `assigned_to`, `transaction`.`created_at`, `transaction`.`updated_at`, `roles`.`name` as `role`, `district`.`name` as `deliver_district`, CASE WHEN invoice_payment.id IS NULL THEN "Y" ELSE "N" END as make_payment from `transaction` left join `service` on `transaction`.`service_id` = `service`.`id` left join `vehicle` on `transaction`.`vehicle_id` = `vehicle`.`id` left join `party` on `transaction`.`party_id` = `party`.`id` left join `users` on `transaction`.`assigned_to` = `users`.`id` left join `workflow_definition` on `transaction`.`current_workflow_state_id` = `workflow_definition`.`id` left join `roles` on `workflow_definition`.`role_id` = `roles`.`id` left join `invoice` on `transaction`.`invoice_id` = `invoice`.`id` left join `district` on `transaction`.`deliver_district_id` = `district`.`id` left join `invoice_payment` on `invoice_payment`.`invoice_id` = `invoice`.`id` where `transaction`.`id` = 101208 and `transaction`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/transaction
   Query 8 - 2025-03-18 07:19:21 [0.73ms] */
select `vehicle`.`id` as `vehicle_id`, `vehicle`.`license_plate`, `vehicle`.`year`, `vehicle`.`odometer`, `vehicle`.`vin`, `sub_category`.`name` as `sub_category`, `classification_type`.`name` as `classification`, `make`.`name` as `make`, `model`.`name` as `model`, `vehicle_color`.`name` as `vehicle_color`, `fuel_type`.`name` as `fuel_type`, `vehicle_type`.`name` as `vehicle_type`, `party_vehicle`.`status`, `vehicle`.`created_at`, `vehicle`.`updated_at` from `vehicle` left join `party_vehicle` on `party_vehicle`.`vehicle_id` = `vehicle`.`id` left join `sub_category` on `vehicle`.`sub_category_id` = `sub_category`.`id` left join `classification_type` on `party_vehicle`.`classification_id` = `classification_type`.`id` left join `model` on `vehicle`.`model_id` = `model`.`id` left join `make` on `model`.`make_id` = `make`.`id` left join `vehicle_color` on `vehicle`.`vehicle_color_id` = `vehicle_color`.`id` left join `fuel_type` on `vehicle`.`fuel_type_id` = `fuel_type`.`id` left join `vehicle_type` on `vehicle`.`vehicle_type_id` = `vehicle_type`.`id` where `vehicle`.`id` = 65642 and `vehicle`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/transaction
   Query 9 - 2025-03-18 07:19:21 [0.65ms] */
select `party`.`id` as `customer_id`, CASE
                WHEN party.phone_number_2 IS NOT NULL THEN CONCAT(party.phone_number_1," / ",party.phone_number_2)
                ELSE party.phone_number_1 END as contact, CASE
                WHEN person.id IS NOT NULL THEN CONCAT(person.first_name, " ", person.second_name, " ", person.third_name, " ", person.fourth_name)
                WHEN company.id IS NOT NULL THEN company.company_name
                ELSE "No Entity Found"
                END AS customer_name, `party`.`partyable_type` as `customer_type`, `person`.`can_vote`, `person`.`occupation`, `person`.`gender`, CASE
                WHEN person.id IS NOT NULL THEN CONCAT(person.father_first_name, " ", person.father_second_name, " ", person.father_third_name, " ", person.father_fourth_name)
                WHEN company.id IS NOT NULL THEN company.company_name
                ELSE "No Entity Found"
                END AS family_head, `person`.`place_of_birth`, `person`.`date_of_birth`, `district`.`name` as `district`, `region`.`name` as `region`, CONCAT(contact_person.first_name, " ", contact_person.second_name,
                " ", contact_person.third_name, " ", contact_person.fourth_name) as contact_person, `company_type`.`name` as `business_type`, CASE
                WHEN contact_party.phone_number_2 IS NOT NULL THEN CONCAT(contact_party.phone_number_1," / ",contact_party.phone_number_2)
                ELSE contact_party.phone_number_1 END as contact_person_mobile, `company`.`registration_date` as `company_registration_date` from `party` left join `person` on `person`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Person' left join (`company` left join `party` as `contact_party` on `company`.`contact_party_id` = `contact_party`.`id` left join `person` as `contact_person` on `contact_party`.`partyable_id` = `contact_person`.`id` left join `company_type` on `company`.`company_type_id` = `company_type`.`id`) on `company`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Company' left join `address` on `party`.`address_id` = `address`.`id` left join `district` on `address`.`district_id` = `district`.`id` left join `region` on `district`.`region_id` = `region`.`id` where `party`.`id` = 45771 and `party`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 1 - 2025-03-18 07:20:37 [2.11ms] */
select * from `users` where `email` = 'userpayment@puntlandgov.org' and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 2 - 2025-03-18 07:20:37 [0.16ms] */
select * from `users` where `id` = 154 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 3 - 2025-03-18 07:20:37 [0.44ms] */
select * from `userprofiles` where `userprofiles`.`user_id` = 154 and `userprofiles`.`user_id` is not null and `userprofiles`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 4 - 2025-03-18 07:20:37 [13.93ms] */
update `userprofiles` set `login_count` = 1334, `last_login` = '2025-03-18 07:20:37', `userprofiles`.`updated_at` = '2025-03-18 07:20:37' where `id` = 154;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 5 - 2025-03-18 07:20:37 [0.33ms] */
select * from `users` where `email` = 'userpayment@puntlandgov.org' and `users`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 6 - 2025-03-18 07:20:37 [0.7ms] */
select column_name as `column_name` from information_schema.columns where table_schema = 'prod_rta_temp' and table_name = 'roles';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 7 - 2025-03-18 07:20:37 [0.24ms] */
select `id`, `name`, `model_has_roles`.`model_id` as `pivot_model_id`, `model_has_roles`.`role_id` as `pivot_role_id`, `model_has_roles`.`model_type` as `pivot_model_type` from `roles` inner join `model_has_roles` on `roles`.`id` = `model_has_roles`.`role_id` where `model_has_roles`.`model_id` in (154) and `model_has_roles`.`model_type` = 'App\Models\User';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 8 - 2025-03-18 07:20:37 [0.2ms] */
select exists(select * from `oauth_personal_access_clients`) as `exists`;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 9 - 2025-03-18 07:20:37 [0.18ms] */
select * from `oauth_personal_access_clients` order by `id` desc limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 10 - 2025-03-18 07:20:37 [0.21ms] */
select * from `oauth_clients` where `oauth_clients`.`id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 11 - 2025-03-18 07:20:37 [0.22ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 12 - 2025-03-18 07:20:37 [0.2ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 13 - 2025-03-18 07:20:37 [3.55ms] */
insert into `oauth_access_tokens` (`id`, `user_id`, `client_id`, `scopes`, `revoked`, `created_at`, `updated_at`, `expires_at`) values ('07da2e568d99c6bc3b921a571d67a13a78084591dcac4a54c97ca55e4ff4624a73f7701e839167cd', 154, 5, '[]', 0, '2025-03-18 07:20:37', '2025-03-18 07:20:37', '2026-03-18 07:20:37');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 14 - 2025-03-18 07:20:37 [0.36ms] */
select * from `oauth_access_tokens` where `id` = '07da2e568d99c6bc3b921a571d67a13a78084591dcac4a54c97ca55e4ff4624a73f7701e839167cd' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 15 - 2025-03-18 07:20:37 [3.25ms] */
update `oauth_access_tokens` set `name` = 'Secret' where `id` = '07da2e568d99c6bc3b921a571d67a13a78084591dcac4a54c97ca55e4ff4624a73f7701e839167cd';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 1 - 2025-03-18 07:20:37 [2.29ms] */
select * from `oauth_access_tokens` where `id` = '07da2e568d99c6bc3b921a571d67a13a78084591dcac4a54c97ca55e4ff4624a73f7701e839167cd' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 2 - 2025-03-18 07:20:37 [0.26ms] */
select * from `oauth_access_tokens` where `id` = '07da2e568d99c6bc3b921a571d67a13a78084591dcac4a54c97ca55e4ff4624a73f7701e839167cd' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 3 - 2025-03-18 07:20:37 [0.25ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 4 - 2025-03-18 07:20:37 [0.17ms] */
select * from `users` where `id` = 154 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 5 - 2025-03-18 07:20:37 [0.14ms] */
select * from `oauth_access_tokens` where `id` = '07da2e568d99c6bc3b921a571d67a13a78084591dcac4a54c97ca55e4ff4624a73f7701e839167cd' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 6 - 2025-03-18 07:20:37 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 7 - 2025-03-18 07:20:37 [0.32ms] */
select DISTINCT payment.id as payment_id, `party`.`id` as `customer_id`, CASE
                WHEN person.id IS NOT NULL THEN CONCAT(person.first_name, " ", person.second_name, " ", person.third_name, " ", person.fourth_name)
                WHEN company.id IS NOT NULL THEN company.company_name
                ELSE "No Entity Found"
                END AS customer_name, `vehicle`.`license_plate`, `payment`.`payment_amount`, `external_payment_reference_no` as `payment_reference_number`, `payment`.`payment_date`, `payment_method`.`name` as `payment_method`, `payment`.`paid_by`, `payment`.`paid_by_mobile` from `payment` left join `invoice_payment` on `invoice_payment`.`payment_id` = `payment`.`id` left join `invoice` on `invoice_payment`.`invoice_id` = `invoice`.`id` and `invoice`.`parent` = 'N' left join `transaction` on `transaction`.`invoice_id` = `invoice`.`id` left join `service` on `transaction`.`service_id` = `service`.`id` left join `vehicle` on `transaction`.`vehicle_id` = `vehicle`.`id` left join `party` on `transaction`.`party_id` = `party`.`id` left join `payment_method` on `payment`.`payment_method_id` = `payment_method`.`id` left join `person` on `person`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Person' left join `company` on `company`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Company' where `service`.`name` = 'Tax' and `payment`.`id` = 89243 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 1 - 2025-03-18 07:23:14 [2.18ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 2 - 2025-03-18 07:23:14 [0.17ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 3 - 2025-03-18 07:23:14 [0.44ms] */
select * from `userprofiles` where `userprofiles`.`user_id` = 149 and `userprofiles`.`user_id` is not null and `userprofiles`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 4 - 2025-03-18 07:23:14 [11.34ms] */
update `userprofiles` set `login_count` = 6352, `last_login` = '2025-03-18 07:23:14', `userprofiles`.`updated_at` = '2025-03-18 07:23:14' where `id` = 149;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 5 - 2025-03-18 07:23:14 [0.36ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 6 - 2025-03-18 07:23:14 [0.71ms] */
select column_name as `column_name` from information_schema.columns where table_schema = 'prod_rta_temp' and table_name = 'roles';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 7 - 2025-03-18 07:23:14 [0.31ms] */
select `id`, `name`, `model_has_roles`.`model_id` as `pivot_model_id`, `model_has_roles`.`role_id` as `pivot_role_id`, `model_has_roles`.`model_type` as `pivot_model_type` from `roles` inner join `model_has_roles` on `roles`.`id` = `model_has_roles`.`role_id` where `model_has_roles`.`model_id` in (149) and `model_has_roles`.`model_type` = 'App\Models\User';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 8 - 2025-03-18 07:23:14 [0.13ms] */
select exists(select * from `oauth_personal_access_clients`) as `exists`;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 9 - 2025-03-18 07:23:14 [0.12ms] */
select * from `oauth_personal_access_clients` order by `id` desc limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 10 - 2025-03-18 07:23:14 [0.14ms] */
select * from `oauth_clients` where `oauth_clients`.`id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 11 - 2025-03-18 07:23:14 [0.14ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 12 - 2025-03-18 07:23:14 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 13 - 2025-03-18 07:23:14 [5.09ms] */
insert into `oauth_access_tokens` (`id`, `user_id`, `client_id`, `scopes`, `revoked`, `created_at`, `updated_at`, `expires_at`) values ('06005858331240a906412ff256fa783c27bc8bea9bbdd45b921282474f805c7205a30b7f0bfef060', 149, 5, '[]', 0, '2025-03-18 07:23:14', '2025-03-18 07:23:14', '2026-03-18 07:23:14');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 14 - 2025-03-18 07:23:14 [0.29ms] */
select * from `oauth_access_tokens` where `id` = '06005858331240a906412ff256fa783c27bc8bea9bbdd45b921282474f805c7205a30b7f0bfef060' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 15 - 2025-03-18 07:23:14 [3.08ms] */
update `oauth_access_tokens` set `name` = 'Secret' where `id` = '06005858331240a906412ff256fa783c27bc8bea9bbdd45b921282474f805c7205a30b7f0bfef060';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 1 - 2025-03-18 07:23:15 [2.36ms] */
select * from `oauth_access_tokens` where `id` = '06005858331240a906412ff256fa783c27bc8bea9bbdd45b921282474f805c7205a30b7f0bfef060' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 2 - 2025-03-18 07:23:15 [0.27ms] */
select * from `oauth_access_tokens` where `id` = '06005858331240a906412ff256fa783c27bc8bea9bbdd45b921282474f805c7205a30b7f0bfef060' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 3 - 2025-03-18 07:23:15 [0.26ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 4 - 2025-03-18 07:23:15 [0.18ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 5 - 2025-03-18 07:23:15 [0.14ms] */
select * from `oauth_access_tokens` where `id` = '06005858331240a906412ff256fa783c27bc8bea9bbdd45b921282474f805c7205a30b7f0bfef060' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 6 - 2025-03-18 07:23:15 [0.16ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 7 - 2025-03-18 07:23:15 [0.3ms] */
select DISTINCT payment.id as payment_id, `party`.`id` as `customer_id`, CASE
                WHEN person.id IS NOT NULL THEN CONCAT(person.first_name, " ", person.second_name, " ", person.third_name, " ", person.fourth_name)
                WHEN company.id IS NOT NULL THEN company.company_name
                ELSE "No Entity Found"
                END AS customer_name, `vehicle`.`license_plate`, `payment`.`payment_amount`, `external_payment_reference_no` as `payment_reference_number`, `payment`.`payment_date`, `payment_method`.`name` as `payment_method`, `payment`.`paid_by`, `payment`.`paid_by_mobile` from `payment` left join `invoice_payment` on `invoice_payment`.`payment_id` = `payment`.`id` left join `invoice` on `invoice_payment`.`invoice_id` = `invoice`.`id` and `invoice`.`parent` = 'N' left join `transaction` on `transaction`.`invoice_id` = `invoice`.`id` left join `service` on `transaction`.`service_id` = `service`.`id` left join `vehicle` on `transaction`.`vehicle_id` = `vehicle`.`id` left join `party` on `transaction`.`party_id` = `party`.`id` left join `payment_method` on `payment`.`payment_method_id` = `payment_method`.`id` left join `person` on `person`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Person' left join `company` on `company`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Company' where `service`.`name` = 'Tax' and `payment`.`id` = 89243 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 1 - 2025-03-18 07:23:43 [1.36ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 2 - 2025-03-18 07:23:43 [0.19ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 3 - 2025-03-18 07:23:43 [0.45ms] */
select * from `userprofiles` where `userprofiles`.`user_id` = 149 and `userprofiles`.`user_id` is not null and `userprofiles`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 4 - 2025-03-18 07:23:43 [11.15ms] */
update `userprofiles` set `login_count` = 6353, `last_login` = '2025-03-18 07:23:43', `userprofiles`.`updated_at` = '2025-03-18 07:23:43' where `id` = 149;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 5 - 2025-03-18 07:23:43 [0.25ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 6 - 2025-03-18 07:23:43 [0.58ms] */
select column_name as `column_name` from information_schema.columns where table_schema = 'prod_rta_temp' and table_name = 'roles';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 7 - 2025-03-18 07:23:43 [0.24ms] */
select `id`, `name`, `model_has_roles`.`model_id` as `pivot_model_id`, `model_has_roles`.`role_id` as `pivot_role_id`, `model_has_roles`.`model_type` as `pivot_model_type` from `roles` inner join `model_has_roles` on `roles`.`id` = `model_has_roles`.`role_id` where `model_has_roles`.`model_id` in (149) and `model_has_roles`.`model_type` = 'App\Models\User';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 8 - 2025-03-18 07:23:43 [0.16ms] */
select exists(select * from `oauth_personal_access_clients`) as `exists`;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 9 - 2025-03-18 07:23:43 [0.13ms] */
select * from `oauth_personal_access_clients` order by `id` desc limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 10 - 2025-03-18 07:23:43 [0.14ms] */
select * from `oauth_clients` where `oauth_clients`.`id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 11 - 2025-03-18 07:23:43 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 12 - 2025-03-18 07:23:43 [0.12ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 13 - 2025-03-18 07:23:43 [3.31ms] */
insert into `oauth_access_tokens` (`id`, `user_id`, `client_id`, `scopes`, `revoked`, `created_at`, `updated_at`, `expires_at`) values ('f644e94e27301d9aac1303ce02d3764b9a3b7fe336acb10be296a31567ca66fb3793dd7d61bf56d5', 149, 5, '[]', 0, '2025-03-18 07:23:43', '2025-03-18 07:23:43', '2026-03-18 07:23:43');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 14 - 2025-03-18 07:23:43 [0.41ms] */
select * from `oauth_access_tokens` where `id` = 'f644e94e27301d9aac1303ce02d3764b9a3b7fe336acb10be296a31567ca66fb3793dd7d61bf56d5' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 15 - 2025-03-18 07:23:43 [3.06ms] */
update `oauth_access_tokens` set `name` = 'Secret' where `id` = 'f644e94e27301d9aac1303ce02d3764b9a3b7fe336acb10be296a31567ca66fb3793dd7d61bf56d5';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 1 - 2025-03-18 07:23:44 [2.55ms] */
select * from `oauth_access_tokens` where `id` = 'f644e94e27301d9aac1303ce02d3764b9a3b7fe336acb10be296a31567ca66fb3793dd7d61bf56d5' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 2 - 2025-03-18 07:23:44 [0.27ms] */
select * from `oauth_access_tokens` where `id` = 'f644e94e27301d9aac1303ce02d3764b9a3b7fe336acb10be296a31567ca66fb3793dd7d61bf56d5' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 3 - 2025-03-18 07:23:44 [0.25ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 4 - 2025-03-18 07:23:44 [0.18ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 5 - 2025-03-18 07:23:44 [0.14ms] */
select * from `oauth_access_tokens` where `id` = 'f644e94e27301d9aac1303ce02d3764b9a3b7fe336acb10be296a31567ca66fb3793dd7d61bf56d5' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 6 - 2025-03-18 07:23:44 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 7 - 2025-03-18 07:23:44 [0.31ms] */
select DISTINCT payment.id as payment_id, `party`.`id` as `customer_id`, CASE
                WHEN person.id IS NOT NULL THEN CONCAT(person.first_name, " ", person.second_name, " ", person.third_name, " ", person.fourth_name)
                WHEN company.id IS NOT NULL THEN company.company_name
                ELSE "No Entity Found"
                END AS customer_name, `vehicle`.`license_plate`, `payment`.`payment_amount`, `external_payment_reference_no` as `payment_reference_number`, `payment`.`payment_date`, `payment_method`.`name` as `payment_method`, `payment`.`paid_by`, `payment`.`paid_by_mobile` from `payment` left join `invoice_payment` on `invoice_payment`.`payment_id` = `payment`.`id` left join `invoice` on `invoice_payment`.`invoice_id` = `invoice`.`id` and `invoice`.`parent` = 'N' left join `transaction` on `transaction`.`invoice_id` = `invoice`.`id` left join `service` on `transaction`.`service_id` = `service`.`id` left join `vehicle` on `transaction`.`vehicle_id` = `vehicle`.`id` left join `party` on `transaction`.`party_id` = `party`.`id` left join `payment_method` on `payment`.`payment_method_id` = `payment_method`.`id` left join `person` on `person`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Person' left join `company` on `company`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Company' where `service`.`name` = 'Tax' and `payment`.`id` = 89243 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 1 - 2025-03-18 07:24:00 [2.41ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 2 - 2025-03-18 07:24:00 [0.17ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 3 - 2025-03-18 07:24:00 [0.44ms] */
select * from `userprofiles` where `userprofiles`.`user_id` = 149 and `userprofiles`.`user_id` is not null and `userprofiles`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 4 - 2025-03-18 07:24:00 [5.1ms] */
update `userprofiles` set `login_count` = 6354, `last_login` = '2025-03-18 07:24:00', `userprofiles`.`updated_at` = '2025-03-18 07:24:00' where `id` = 149;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 5 - 2025-03-18 07:24:00 [0.17ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 6 - 2025-03-18 07:24:00 [0.4ms] */
select column_name as `column_name` from information_schema.columns where table_schema = 'prod_rta_temp' and table_name = 'roles';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 7 - 2025-03-18 07:24:00 [0.16ms] */
select `id`, `name`, `model_has_roles`.`model_id` as `pivot_model_id`, `model_has_roles`.`role_id` as `pivot_role_id`, `model_has_roles`.`model_type` as `pivot_model_type` from `roles` inner join `model_has_roles` on `roles`.`id` = `model_has_roles`.`role_id` where `model_has_roles`.`model_id` in (149) and `model_has_roles`.`model_type` = 'App\Models\User';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 8 - 2025-03-18 07:24:00 [0.2ms] */
select exists(select * from `oauth_personal_access_clients`) as `exists`;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 9 - 2025-03-18 07:24:00 [0.18ms] */
select * from `oauth_personal_access_clients` order by `id` desc limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 10 - 2025-03-18 07:24:00 [0.21ms] */
select * from `oauth_clients` where `oauth_clients`.`id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 11 - 2025-03-18 07:24:00 [0.22ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 12 - 2025-03-18 07:24:00 [0.2ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 13 - 2025-03-18 07:24:00 [3.43ms] */
insert into `oauth_access_tokens` (`id`, `user_id`, `client_id`, `scopes`, `revoked`, `created_at`, `updated_at`, `expires_at`) values ('7dfa279b24467d2088eae197566fce8fc4746a08d876d37eeedad61f5d7723cdd51b0ba384c7b8a3', 149, 5, '[]', 0, '2025-03-18 07:24:00', '2025-03-18 07:24:00', '2026-03-18 07:24:00');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 14 - 2025-03-18 07:24:00 [0.29ms] */
select * from `oauth_access_tokens` where `id` = '7dfa279b24467d2088eae197566fce8fc4746a08d876d37eeedad61f5d7723cdd51b0ba384c7b8a3' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 15 - 2025-03-18 07:24:00 [2.94ms] */
update `oauth_access_tokens` set `name` = 'Secret' where `id` = '7dfa279b24467d2088eae197566fce8fc4746a08d876d37eeedad61f5d7723cdd51b0ba384c7b8a3';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 1 - 2025-03-18 07:24:01 [2.55ms] */
select * from `oauth_access_tokens` where `id` = '7dfa279b24467d2088eae197566fce8fc4746a08d876d37eeedad61f5d7723cdd51b0ba384c7b8a3' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 2 - 2025-03-18 07:24:01 [0.29ms] */
select * from `oauth_access_tokens` where `id` = '7dfa279b24467d2088eae197566fce8fc4746a08d876d37eeedad61f5d7723cdd51b0ba384c7b8a3' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 3 - 2025-03-18 07:24:01 [0.27ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 4 - 2025-03-18 07:24:01 [0.17ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 5 - 2025-03-18 07:24:01 [0.14ms] */
select * from `oauth_access_tokens` where `id` = '7dfa279b24467d2088eae197566fce8fc4746a08d876d37eeedad61f5d7723cdd51b0ba384c7b8a3' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 6 - 2025-03-18 07:24:01 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 7 - 2025-03-18 07:24:01 [0.3ms] */
select DISTINCT payment.id as payment_id, `party`.`id` as `customer_id`, CASE
                WHEN person.id IS NOT NULL THEN CONCAT(person.first_name, " ", person.second_name, " ", person.third_name, " ", person.fourth_name)
                WHEN company.id IS NOT NULL THEN company.company_name
                ELSE "No Entity Found"
                END AS customer_name, `vehicle`.`license_plate`, `payment`.`payment_amount`, `external_payment_reference_no` as `payment_reference_number`, `payment`.`payment_date`, `payment_method`.`name` as `payment_method`, `payment`.`paid_by`, `payment`.`paid_by_mobile` from `payment` left join `invoice_payment` on `invoice_payment`.`payment_id` = `payment`.`id` left join `invoice` on `invoice_payment`.`invoice_id` = `invoice`.`id` and `invoice`.`parent` = 'N' left join `transaction` on `transaction`.`invoice_id` = `invoice`.`id` left join `service` on `transaction`.`service_id` = `service`.`id` left join `vehicle` on `transaction`.`vehicle_id` = `vehicle`.`id` left join `party` on `transaction`.`party_id` = `party`.`id` left join `payment_method` on `payment`.`payment_method_id` = `payment_method`.`id` left join `person` on `person`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Person' left join `company` on `company`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Company' where `service`.`name` = 'Tax' and `payment`.`id` = 89243 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 1 - 2025-03-18 07:24:28 [2.1ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 2 - 2025-03-18 07:24:28 [0.16ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 3 - 2025-03-18 07:24:28 [0.45ms] */
select * from `userprofiles` where `userprofiles`.`user_id` = 149 and `userprofiles`.`user_id` is not null and `userprofiles`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 4 - 2025-03-18 07:24:28 [11.16ms] */
update `userprofiles` set `login_count` = 6355, `last_login` = '2025-03-18 07:24:28', `userprofiles`.`updated_at` = '2025-03-18 07:24:28' where `id` = 149;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 5 - 2025-03-18 07:24:28 [0.36ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 6 - 2025-03-18 07:24:28 [0.72ms] */
select column_name as `column_name` from information_schema.columns where table_schema = 'prod_rta_temp' and table_name = 'roles';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 7 - 2025-03-18 07:24:28 [0.3ms] */
select `id`, `name`, `model_has_roles`.`model_id` as `pivot_model_id`, `model_has_roles`.`role_id` as `pivot_role_id`, `model_has_roles`.`model_type` as `pivot_model_type` from `roles` inner join `model_has_roles` on `roles`.`id` = `model_has_roles`.`role_id` where `model_has_roles`.`model_id` in (149) and `model_has_roles`.`model_type` = 'App\Models\User';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 8 - 2025-03-18 07:24:28 [0.13ms] */
select exists(select * from `oauth_personal_access_clients`) as `exists`;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 9 - 2025-03-18 07:24:28 [0.12ms] */
select * from `oauth_personal_access_clients` order by `id` desc limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 10 - 2025-03-18 07:24:28 [0.14ms] */
select * from `oauth_clients` where `oauth_clients`.`id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 11 - 2025-03-18 07:24:28 [0.15ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 12 - 2025-03-18 07:24:28 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 13 - 2025-03-18 07:24:28 [3.54ms] */
insert into `oauth_access_tokens` (`id`, `user_id`, `client_id`, `scopes`, `revoked`, `created_at`, `updated_at`, `expires_at`) values ('38ba8e5b23c7bc706d9fcb161f1fb2868dc35b68dce0fe15833b539b755e72c9fed8b482cf4a1b00', 149, 5, '[]', 0, '2025-03-18 07:24:28', '2025-03-18 07:24:28', '2026-03-18 07:24:28');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 14 - 2025-03-18 07:24:28 [0.26ms] */
select * from `oauth_access_tokens` where `id` = '38ba8e5b23c7bc706d9fcb161f1fb2868dc35b68dce0fe15833b539b755e72c9fed8b482cf4a1b00' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 15 - 2025-03-18 07:24:28 [3ms] */
update `oauth_access_tokens` set `name` = 'Secret' where `id` = '38ba8e5b23c7bc706d9fcb161f1fb2868dc35b68dce0fe15833b539b755e72c9fed8b482cf4a1b00';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 1 - 2025-03-18 07:24:29 [1.67ms] */
select * from `oauth_access_tokens` where `id` = '38ba8e5b23c7bc706d9fcb161f1fb2868dc35b68dce0fe15833b539b755e72c9fed8b482cf4a1b00' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 2 - 2025-03-18 07:24:29 [0.14ms] */
select * from `oauth_access_tokens` where `id` = '38ba8e5b23c7bc706d9fcb161f1fb2868dc35b68dce0fe15833b539b755e72c9fed8b482cf4a1b00' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 3 - 2025-03-18 07:24:29 [0.14ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 4 - 2025-03-18 07:24:29 [0.16ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 5 - 2025-03-18 07:24:29 [0.14ms] */
select * from `oauth_access_tokens` where `id` = '38ba8e5b23c7bc706d9fcb161f1fb2868dc35b68dce0fe15833b539b755e72c9fed8b482cf4a1b00' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 6 - 2025-03-18 07:24:29 [0.14ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 7 - 2025-03-18 07:24:29 [0.3ms] */
select DISTINCT payment.id as payment_id, `party`.`id` as `customer_id`, CASE
                WHEN person.id IS NOT NULL THEN CONCAT(person.first_name, " ", person.second_name, " ", person.third_name, " ", person.fourth_name)
                WHEN company.id IS NOT NULL THEN company.company_name
                ELSE "No Entity Found"
                END AS customer_name, `vehicle`.`license_plate`, `payment`.`payment_amount`, `external_payment_reference_no` as `payment_reference_number`, `payment`.`payment_date`, `payment_method`.`name` as `payment_method`, `payment`.`paid_by`, `payment`.`paid_by_mobile` from `payment` left join `invoice_payment` on `invoice_payment`.`payment_id` = `payment`.`id` left join `invoice` on `invoice_payment`.`invoice_id` = `invoice`.`id` and `invoice`.`parent` = 'N' left join `transaction` on `transaction`.`invoice_id` = `invoice`.`id` left join `service` on `transaction`.`service_id` = `service`.`id` left join `vehicle` on `transaction`.`vehicle_id` = `vehicle`.`id` left join `party` on `transaction`.`party_id` = `party`.`id` left join `payment_method` on `payment`.`payment_method_id` = `payment_method`.`id` left join `person` on `person`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Person' left join `company` on `company`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Company' where `service`.`name` = 'Tax' and `payment`.`id` = 89243 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 1 - 2025-03-18 07:25:09 [2.08ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 2 - 2025-03-18 07:25:09 [0.27ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 3 - 2025-03-18 07:25:09 [0.39ms] */
select * from `userprofiles` where `userprofiles`.`user_id` = 149 and `userprofiles`.`user_id` is not null and `userprofiles`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 4 - 2025-03-18 07:25:09 [12.24ms] */
update `userprofiles` set `login_count` = 6356, `last_login` = '2025-03-18 07:25:09', `userprofiles`.`updated_at` = '2025-03-18 07:25:09' where `id` = 149;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 5 - 2025-03-18 07:25:09 [0.33ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 6 - 2025-03-18 07:25:09 [0.69ms] */
select column_name as `column_name` from information_schema.columns where table_schema = 'prod_rta_temp' and table_name = 'roles';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 7 - 2025-03-18 07:25:09 [0.24ms] */
select `id`, `name`, `model_has_roles`.`model_id` as `pivot_model_id`, `model_has_roles`.`role_id` as `pivot_role_id`, `model_has_roles`.`model_type` as `pivot_model_type` from `roles` inner join `model_has_roles` on `roles`.`id` = `model_has_roles`.`role_id` where `model_has_roles`.`model_id` in (149) and `model_has_roles`.`model_type` = 'App\Models\User';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 8 - 2025-03-18 07:25:09 [0.2ms] */
select exists(select * from `oauth_personal_access_clients`) as `exists`;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 9 - 2025-03-18 07:25:09 [0.18ms] */
select * from `oauth_personal_access_clients` order by `id` desc limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 10 - 2025-03-18 07:25:09 [0.21ms] */
select * from `oauth_clients` where `oauth_clients`.`id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 11 - 2025-03-18 07:25:09 [0.22ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 12 - 2025-03-18 07:25:09 [0.2ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 13 - 2025-03-18 07:25:09 [5.9ms] */
insert into `oauth_access_tokens` (`id`, `user_id`, `client_id`, `scopes`, `revoked`, `created_at`, `updated_at`, `expires_at`) values ('e49760c12ccf3421a22c1825f02fa04af9af105147ada6811f66c6420c608b4caf2bd9a3b6fdcf82', 149, 5, '[]', 0, '2025-03-18 07:25:09', '2025-03-18 07:25:09', '2026-03-18 07:25:09');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 14 - 2025-03-18 07:25:09 [0.47ms] */
select * from `oauth_access_tokens` where `id` = 'e49760c12ccf3421a22c1825f02fa04af9af105147ada6811f66c6420c608b4caf2bd9a3b6fdcf82' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 15 - 2025-03-18 07:25:09 [3.24ms] */
update `oauth_access_tokens` set `name` = 'Secret' where `id` = 'e49760c12ccf3421a22c1825f02fa04af9af105147ada6811f66c6420c608b4caf2bd9a3b6fdcf82';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 1 - 2025-03-18 07:25:10 [2.53ms] */
select * from `oauth_access_tokens` where `id` = 'e49760c12ccf3421a22c1825f02fa04af9af105147ada6811f66c6420c608b4caf2bd9a3b6fdcf82' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 2 - 2025-03-18 07:25:10 [0.3ms] */
select * from `oauth_access_tokens` where `id` = 'e49760c12ccf3421a22c1825f02fa04af9af105147ada6811f66c6420c608b4caf2bd9a3b6fdcf82' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 3 - 2025-03-18 07:25:10 [0.27ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 4 - 2025-03-18 07:25:10 [0.32ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 5 - 2025-03-18 07:25:10 [0.27ms] */
select * from `oauth_access_tokens` where `id` = 'e49760c12ccf3421a22c1825f02fa04af9af105147ada6811f66c6420c608b4caf2bd9a3b6fdcf82' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 6 - 2025-03-18 07:25:10 [0.25ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 7 - 2025-03-18 07:25:10 [0.3ms] */
select DISTINCT payment.id as payment_id, `party`.`id` as `customer_id`, CASE
                WHEN person.id IS NOT NULL THEN CONCAT(person.first_name, " ", person.second_name, " ", person.third_name, " ", person.fourth_name)
                WHEN company.id IS NOT NULL THEN company.company_name
                ELSE "No Entity Found"
                END AS customer_name, `vehicle`.`license_plate`, `payment`.`payment_amount`, `external_payment_reference_no` as `payment_reference_number`, `payment`.`payment_date`, `payment_method`.`name` as `payment_method`, `payment`.`paid_by`, `payment`.`paid_by_mobile` from `payment` left join `invoice_payment` on `invoice_payment`.`payment_id` = `payment`.`id` left join `invoice` on `invoice_payment`.`invoice_id` = `invoice`.`id` and `invoice`.`parent` = 'N' left join `transaction` on `transaction`.`invoice_id` = `invoice`.`id` left join `service` on `transaction`.`service_id` = `service`.`id` left join `vehicle` on `transaction`.`vehicle_id` = `vehicle`.`id` left join `party` on `transaction`.`party_id` = `party`.`id` left join `payment_method` on `payment`.`payment_method_id` = `payment_method`.`id` left join `person` on `person`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Person' left join `company` on `company`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Company' where `service`.`name` = 'Tax' and `payment`.`id` = 89243 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 1 - 2025-03-18 07:25:41 [2.1ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 2 - 2025-03-18 07:25:41 [0.16ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 3 - 2025-03-18 07:25:41 [0.43ms] */
select * from `userprofiles` where `userprofiles`.`user_id` = 149 and `userprofiles`.`user_id` is not null and `userprofiles`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 4 - 2025-03-18 07:25:41 [11.48ms] */
update `userprofiles` set `login_count` = 6357, `last_login` = '2025-03-18 07:25:41', `userprofiles`.`updated_at` = '2025-03-18 07:25:41' where `id` = 149;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 5 - 2025-03-18 07:25:41 [0.32ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 6 - 2025-03-18 07:25:41 [0.71ms] */
select column_name as `column_name` from information_schema.columns where table_schema = 'prod_rta_temp' and table_name = 'roles';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 7 - 2025-03-18 07:25:41 [0.32ms] */
select `id`, `name`, `model_has_roles`.`model_id` as `pivot_model_id`, `model_has_roles`.`role_id` as `pivot_role_id`, `model_has_roles`.`model_type` as `pivot_model_type` from `roles` inner join `model_has_roles` on `roles`.`id` = `model_has_roles`.`role_id` where `model_has_roles`.`model_id` in (149) and `model_has_roles`.`model_type` = 'App\Models\User';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 8 - 2025-03-18 07:25:41 [0.32ms] */
select exists(select * from `oauth_personal_access_clients`) as `exists`;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 9 - 2025-03-18 07:25:41 [0.23ms] */
select * from `oauth_personal_access_clients` order by `id` desc limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 10 - 2025-03-18 07:25:41 [0.34ms] */
select * from `oauth_clients` where `oauth_clients`.`id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 11 - 2025-03-18 07:25:41 [0.27ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 12 - 2025-03-18 07:25:41 [0.25ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 13 - 2025-03-18 07:25:41 [4.2ms] */
insert into `oauth_access_tokens` (`id`, `user_id`, `client_id`, `scopes`, `revoked`, `created_at`, `updated_at`, `expires_at`) values ('b0f4f8f4cc8448458e3543431700cc3fcb2f8a649e13676d52c0b4c746a593351a832aa8453f76d0', 149, 5, '[]', 0, '2025-03-18 07:25:41', '2025-03-18 07:25:41', '2026-03-18 07:25:41');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 14 - 2025-03-18 07:25:41 [0.38ms] */
select * from `oauth_access_tokens` where `id` = 'b0f4f8f4cc8448458e3543431700cc3fcb2f8a649e13676d52c0b4c746a593351a832aa8453f76d0' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 15 - 2025-03-18 07:25:41 [3.25ms] */
update `oauth_access_tokens` set `name` = 'Secret' where `id` = 'b0f4f8f4cc8448458e3543431700cc3fcb2f8a649e13676d52c0b4c746a593351a832aa8453f76d0';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 1 - 2025-03-18 07:25:42 [2.53ms] */
select * from `oauth_access_tokens` where `id` = 'b0f4f8f4cc8448458e3543431700cc3fcb2f8a649e13676d52c0b4c746a593351a832aa8453f76d0' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 2 - 2025-03-18 07:25:42 [0.28ms] */
select * from `oauth_access_tokens` where `id` = 'b0f4f8f4cc8448458e3543431700cc3fcb2f8a649e13676d52c0b4c746a593351a832aa8453f76d0' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 3 - 2025-03-18 07:25:42 [0.27ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 4 - 2025-03-18 07:25:42 [0.32ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 5 - 2025-03-18 07:25:42 [0.26ms] */
select * from `oauth_access_tokens` where `id` = 'b0f4f8f4cc8448458e3543431700cc3fcb2f8a649e13676d52c0b4c746a593351a832aa8453f76d0' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 6 - 2025-03-18 07:25:42 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 7 - 2025-03-18 07:25:42 [0.3ms] */
select DISTINCT payment.id as payment_id, `party`.`id` as `customer_id`, CASE
                WHEN person.id IS NOT NULL THEN CONCAT(person.first_name, " ", person.second_name, " ", person.third_name, " ", person.fourth_name)
                WHEN company.id IS NOT NULL THEN company.company_name
                ELSE "No Entity Found"
                END AS customer_name, `vehicle`.`license_plate`, `payment`.`payment_amount`, `external_payment_reference_no` as `payment_reference_number`, `payment`.`payment_date`, `payment_method`.`name` as `payment_method`, `payment`.`paid_by`, `payment`.`paid_by_mobile` from `payment` left join `invoice_payment` on `invoice_payment`.`payment_id` = `payment`.`id` left join `invoice` on `invoice_payment`.`invoice_id` = `invoice`.`id` and `invoice`.`parent` = 'N' left join `transaction` on `transaction`.`invoice_id` = `invoice`.`id` left join `service` on `transaction`.`service_id` = `service`.`id` left join `vehicle` on `transaction`.`vehicle_id` = `vehicle`.`id` left join `party` on `transaction`.`party_id` = `party`.`id` left join `payment_method` on `payment`.`payment_method_id` = `payment_method`.`id` left join `person` on `person`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Person' left join `company` on `company`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Company' where `service`.`name` = 'Tax' and `payment`.`id` = 89243 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 1 - 2025-03-18 07:25:58 [1.38ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 2 - 2025-03-18 07:25:58 [0.16ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 3 - 2025-03-18 07:25:58 [0.44ms] */
select * from `userprofiles` where `userprofiles`.`user_id` = 149 and `userprofiles`.`user_id` is not null and `userprofiles`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 4 - 2025-03-18 07:25:58 [11.25ms] */
update `userprofiles` set `login_count` = 6358, `last_login` = '2025-03-18 07:25:58', `userprofiles`.`updated_at` = '2025-03-18 07:25:58' where `id` = 149;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 5 - 2025-03-18 07:25:58 [0.32ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 6 - 2025-03-18 07:25:58 [0.73ms] */
select column_name as `column_name` from information_schema.columns where table_schema = 'prod_rta_temp' and table_name = 'roles';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 7 - 2025-03-18 07:25:58 [0.24ms] */
select `id`, `name`, `model_has_roles`.`model_id` as `pivot_model_id`, `model_has_roles`.`role_id` as `pivot_role_id`, `model_has_roles`.`model_type` as `pivot_model_type` from `roles` inner join `model_has_roles` on `roles`.`id` = `model_has_roles`.`role_id` where `model_has_roles`.`model_id` in (149) and `model_has_roles`.`model_type` = 'App\Models\User';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 8 - 2025-03-18 07:25:58 [0.2ms] */
select exists(select * from `oauth_personal_access_clients`) as `exists`;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 9 - 2025-03-18 07:25:58 [0.18ms] */
select * from `oauth_personal_access_clients` order by `id` desc limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 10 - 2025-03-18 07:25:58 [0.21ms] */
select * from `oauth_clients` where `oauth_clients`.`id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 11 - 2025-03-18 07:25:58 [0.22ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 12 - 2025-03-18 07:25:58 [0.2ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 13 - 2025-03-18 07:25:58 [3.49ms] */
insert into `oauth_access_tokens` (`id`, `user_id`, `client_id`, `scopes`, `revoked`, `created_at`, `updated_at`, `expires_at`) values ('e898d02c78c5365e43a95f5a8defeb4220ab28eb9e8735e6891093bdfbc46374520aa61c2189fe74', 149, 5, '[]', 0, '2025-03-18 07:25:58', '2025-03-18 07:25:58', '2026-03-18 07:25:58');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 14 - 2025-03-18 07:25:58 [0.26ms] */
select * from `oauth_access_tokens` where `id` = 'e898d02c78c5365e43a95f5a8defeb4220ab28eb9e8735e6891093bdfbc46374520aa61c2189fe74' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 15 - 2025-03-18 07:25:58 [3.36ms] */
update `oauth_access_tokens` set `name` = 'Secret' where `id` = 'e898d02c78c5365e43a95f5a8defeb4220ab28eb9e8735e6891093bdfbc46374520aa61c2189fe74';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 1 - 2025-03-18 07:25:58 [2.26ms] */
select * from `oauth_access_tokens` where `id` = 'e898d02c78c5365e43a95f5a8defeb4220ab28eb9e8735e6891093bdfbc46374520aa61c2189fe74' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 2 - 2025-03-18 07:25:58 [0.27ms] */
select * from `oauth_access_tokens` where `id` = 'e898d02c78c5365e43a95f5a8defeb4220ab28eb9e8735e6891093bdfbc46374520aa61c2189fe74' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 3 - 2025-03-18 07:25:58 [0.25ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 4 - 2025-03-18 07:25:58 [0.36ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 5 - 2025-03-18 07:25:58 [0.14ms] */
select * from `oauth_access_tokens` where `id` = 'e898d02c78c5365e43a95f5a8defeb4220ab28eb9e8735e6891093bdfbc46374520aa61c2189fe74' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 6 - 2025-03-18 07:25:58 [0.22ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 7 - 2025-03-18 07:25:58 [0.46ms] */
select DISTINCT payment.id as payment_id, `party`.`id` as `customer_id`, CASE
                WHEN person.id IS NOT NULL THEN CONCAT(person.first_name, " ", person.second_name, " ", person.third_name, " ", person.fourth_name)
                WHEN company.id IS NOT NULL THEN company.company_name
                ELSE "No Entity Found"
                END AS customer_name, `vehicle`.`license_plate`, `payment`.`payment_amount`, `external_payment_reference_no` as `payment_reference_number`, `payment`.`payment_date`, `payment_method`.`name` as `payment_method`, `payment`.`paid_by`, `payment`.`paid_by_mobile` from `payment` left join `invoice_payment` on `invoice_payment`.`payment_id` = `payment`.`id` left join `invoice` on `invoice_payment`.`invoice_id` = `invoice`.`id` and `invoice`.`parent` = 'N' left join `transaction` on `transaction`.`invoice_id` = `invoice`.`id` left join `service` on `transaction`.`service_id` = `service`.`id` left join `vehicle` on `transaction`.`vehicle_id` = `vehicle`.`id` left join `party` on `transaction`.`party_id` = `party`.`id` left join `payment_method` on `payment`.`payment_method_id` = `payment_method`.`id` left join `person` on `person`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Person' left join `company` on `company`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Company' where `service`.`name` = 'Tax' and `payment`.`id` = 89243 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 1 - 2025-03-18 07:34:12 [1.58ms] */
select * from `users` where `email` = 'ahmeddaakir54@puntlandgov.org' and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 2 - 2025-03-18 07:34:12 [0.25ms] */
select * from `users` where `id` = 153 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 3 - 2025-03-18 07:34:12 [0.37ms] */
select * from `userprofiles` where `userprofiles`.`user_id` = 153 and `userprofiles`.`user_id` is not null and `userprofiles`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 4 - 2025-03-18 07:34:12 [6.21ms] */
update `userprofiles` set `last_ip` = '41.223.109.136', `login_count` = 23, `last_login` = '2025-03-18 07:34:12', `userprofiles`.`updated_at` = '2025-03-18 07:34:12' where `id` = 153;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 5 - 2025-03-18 07:34:12 [0.27ms] */
select * from `users` where `email` = 'ahmeddaakir54@puntlandgov.org' and `users`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 6 - 2025-03-18 07:34:12 [0.39ms] */
select column_name as `column_name` from information_schema.columns where table_schema = 'prod_rta_temp' and table_name = 'roles';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 7 - 2025-03-18 07:34:12 [0.28ms] */
select `id`, `name`, `model_has_roles`.`model_id` as `pivot_model_id`, `model_has_roles`.`role_id` as `pivot_role_id`, `model_has_roles`.`model_type` as `pivot_model_type` from `roles` inner join `model_has_roles` on `roles`.`id` = `model_has_roles`.`role_id` where `model_has_roles`.`model_id` in (153) and `model_has_roles`.`model_type` = 'App\Models\User';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 8 - 2025-03-18 07:34:12 [0.2ms] */
select exists(select * from `oauth_personal_access_clients`) as `exists`;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 9 - 2025-03-18 07:34:12 [0.18ms] */
select * from `oauth_personal_access_clients` order by `id` desc limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 10 - 2025-03-18 07:34:12 [0.21ms] */
select * from `oauth_clients` where `oauth_clients`.`id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 11 - 2025-03-18 07:34:12 [0.24ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 12 - 2025-03-18 07:34:12 [0.2ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 13 - 2025-03-18 07:34:12 [3.24ms] */
insert into `oauth_access_tokens` (`id`, `user_id`, `client_id`, `scopes`, `revoked`, `created_at`, `updated_at`, `expires_at`) values ('7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea', 153, 5, '[]', 0, '2025-03-18 07:34:12', '2025-03-18 07:34:12', '2026-03-18 07:34:12');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 14 - 2025-03-18 07:34:12 [0.35ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 15 - 2025-03-18 07:34:12 [3.21ms] */
update `oauth_access_tokens` set `name` = 'Secret' where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 1 - 2025-03-18 07:34:23 [2.82ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 2 - 2025-03-18 07:34:23 [0.28ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 3 - 2025-03-18 07:34:23 [0.27ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 4 - 2025-03-18 07:34:23 [0.27ms] */
select * from `users` where `id` = 153 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 5 - 2025-03-18 07:34:23 [0.14ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 6 - 2025-03-18 07:34:23 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 7 - 2025-03-18 07:34:23 [0.81ms] */
select `vehicle`.`id` as `vehicle_id`, `party`.`id` as `party_id`, `vehicle`.`license_plate`, `vehicle`.`year`, `vehicle`.`odometer`, `vehicle`.`vin`, `sub_category`.`name` as `sub_category`, `classification_type`.`name` as `classification`, `make`.`name` as `make`, `model`.`name` as `model`, `vehicle_color`.`name` as `vehicle_color`, `fuel_type`.`name` as `fuel_type`, `vehicle_type`.`name` as `vehicle_type`, CASE
                WHEN party_vehicle.id IS NULL THEN "UNREGISTERED" ELSE party_vehicle.status END AS status, CASE
                WHEN person.id IS NOT NULL THEN CONCAT(person.first_name, " ", person.second_name, " ", person.third_name, " ", person.fourth_name)
                WHEN company.id IS NOT NULL THEN company.company_name
                ELSE "No Entity Found"
                END AS owner, `party`.`partyable_type` as `owner_type`, `party_vehicle`.`registration_date`, `vehicle`.`created_at`, `vehicle`.`updated_at` from `vehicle` left join `party_vehicle` on `party_vehicle`.`vehicle_id` = `vehicle`.`id` left join `sub_category` on `vehicle`.`sub_category_id` = `sub_category`.`id` left join `classification_type` on `party_vehicle`.`classification_id` = `classification_type`.`id` left join `model` on `vehicle`.`model_id` = `model`.`id` left join `make` on `model`.`make_id` = `make`.`id` left join `vehicle_color` on `vehicle`.`vehicle_color_id` = `vehicle_color`.`id` left join `fuel_type` on `vehicle`.`fuel_type_id` = `fuel_type`.`id` left join `vehicle_type` on `vehicle`.`vehicle_type_id` = `vehicle_type`.`id` left join `party` on `party_vehicle`.`party_id` = `party`.`id` left join `person` on `person`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Person' left join `company` on `company`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Company' where `license_plate` = 'LQ204' and `party_vehicle`.`is_owner` = 'Y' and `vehicle`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 8 - 2025-03-18 07:34:23 [0.23ms] */
select * from `party` where `party`.`id` = 60588 and `party`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 9 - 2025-03-18 07:34:23 [0.23ms] */
select * from `vehicle` where `id` = 93422 and `provisional` = 'Y' and `vehicle`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 10 - 2025-03-18 07:34:23 [0.34ms] */
select * from `party_vehicle` where `vehicle_id` = 93422 and `is_owner` = 'Y' and `party_vehicle`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 1 - 2025-03-18 07:34:24 [1.36ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 2 - 2025-03-18 07:34:24 [0.14ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 3 - 2025-03-18 07:34:24 [0.2ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 4 - 2025-03-18 07:34:24 [0.17ms] */
select * from `users` where `id` = 153 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 5 - 2025-03-18 07:34:24 [0.15ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 6 - 2025-03-18 07:34:24 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 7 - 2025-03-18 07:34:24 [0.28ms] */
select * from `vehicle` where `vehicle`.`id` = 93422 and `vehicle`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 8 - 2025-03-18 07:34:24 [0.21ms] */
select * from `vehicle` where `id` = 93422 and `provisional` = 'Y' and `vehicle`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 9 - 2025-03-18 07:34:24 [0.26ms] */
select * from `party_vehicle` where `vehicle_id` = 93422 and `is_owner` = 'Y' and `party_vehicle`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 10 - 2025-03-18 07:34:24 [1ms] */
select `vehicle_tax`.`id`, `term`.`year`, `term`.`quarter`, `invoice`.`invoice_amount`, `invoice`.`outstanding_balance`, `vehicle_tax`.`exempt`, `invoice`.`status`, `tax_sticker`.`name` as `tax_sticker`, CASE
                WHEN term.quarter = 1 THEN DATE_FORMAT(CONCAT(term.year, "-03-31"), "%d-%m-%Y")
                WHEN term.quarter = 2 THEN DATE_FORMAT(CONCAT(term.year, "-06-30"), "%d-%m-%Y")
                WHEN term.quarter = 3 THEN DATE_FORMAT(CONCAT(term.year, "-09-30"), "%d-%m-%Y")
                WHEN term.quarter = 4 THEN DATE_FORMAT(CONCAT(term.year, "-12-31"), "%d-%m-%Y")
                ELSE NULL
                END as due_date from `vehicle_tax` left join `term` on `vehicle_tax`.`term_id` = `term`.`id` left join `transaction` on `vehicle_tax`.`transaction_id` = `transaction`.`id` left join `invoice` on `transaction`.`invoice_id` = `invoice`.`id` left join `tax_sticker` on `vehicle_tax`.`tax_sticker_id` = `tax_sticker`.`id` where `vehicle_tax`.`vehicle_id` = 93422 and `vehicle_tax`.`deleted_at` is null and `transaction`.`deleted_at` is null and `invoice`.`deleted_at` is null order by `term`.`year` asc, `term`.`quarter` asc;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/region-list
   Query 1 - 2025-03-18 07:34:24 [1.98ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/region-list
   Query 2 - 2025-03-18 07:34:24 [0.26ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/region-list
   Query 3 - 2025-03-18 07:34:24 [0.25ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/region-list
   Query 4 - 2025-03-18 07:34:24 [0.31ms] */
select * from `users` where `id` = 153 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/region-list
   Query 5 - 2025-03-18 07:34:24 [0.27ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/region-list
   Query 6 - 2025-03-18 07:34:24 [0.25ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/region-list
   Query 7 - 2025-03-18 07:34:24 [0.38ms] */
select `id`, `name` from `region` where `deleted_at` is null;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/payment_providers
   Query 1 - 2025-03-18 07:34:24 [1.31ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/payment_providers
   Query 2 - 2025-03-18 07:34:24 [0.16ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/payment_providers
   Query 3 - 2025-03-18 07:34:24 [0.14ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/payment_providers
   Query 4 - 2025-03-18 07:34:24 [0.16ms] */
select * from `users` where `id` = 153 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/payment_providers
   Query 5 - 2025-03-18 07:34:24 [0.14ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/payment_providers
   Query 6 - 2025-03-18 07:34:24 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/payment_providers
   Query 7 - 2025-03-18 07:34:24 [0.42ms] */
select * from `payment_method` where exists (select * from `payment_configurations` where `payment_method`.`id` = `payment_configurations`.`provider_id` and `fee_type` = 'Government' and `payment_configurations`.`deleted_at` is null) and `payment_method`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 1 - 2025-03-18 07:34:35 [2.37ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 2 - 2025-03-18 07:34:35 [0.28ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 3 - 2025-03-18 07:34:35 [0.27ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 4 - 2025-03-18 07:34:35 [0.18ms] */
select * from `users` where `id` = 153 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 5 - 2025-03-18 07:34:35 [0.14ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 6 - 2025-03-18 07:34:35 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 7 - 2025-03-18 07:34:35 [0.33ms] */
select `vehicle`.`id` as `vehicle_id`, `party`.`id` as `party_id`, `vehicle`.`license_plate`, `vehicle`.`year`, `vehicle`.`odometer`, `vehicle`.`vin`, `sub_category`.`name` as `sub_category`, `classification_type`.`name` as `classification`, `make`.`name` as `make`, `model`.`name` as `model`, `vehicle_color`.`name` as `vehicle_color`, `fuel_type`.`name` as `fuel_type`, `vehicle_type`.`name` as `vehicle_type`, CASE
                WHEN party_vehicle.id IS NULL THEN "UNREGISTERED" ELSE party_vehicle.status END AS status, CASE
                WHEN person.id IS NOT NULL THEN CONCAT(person.first_name, " ", person.second_name, " ", person.third_name, " ", person.fourth_name)
                WHEN company.id IS NOT NULL THEN company.company_name
                ELSE "No Entity Found"
                END AS owner, `party`.`partyable_type` as `owner_type`, `party_vehicle`.`registration_date`, `vehicle`.`created_at`, `vehicle`.`updated_at` from `vehicle` left join `party_vehicle` on `party_vehicle`.`vehicle_id` = `vehicle`.`id` left join `sub_category` on `vehicle`.`sub_category_id` = `sub_category`.`id` left join `classification_type` on `party_vehicle`.`classification_id` = `classification_type`.`id` left join `model` on `vehicle`.`model_id` = `model`.`id` left join `make` on `model`.`make_id` = `make`.`id` left join `vehicle_color` on `vehicle`.`vehicle_color_id` = `vehicle_color`.`id` left join `fuel_type` on `vehicle`.`fuel_type_id` = `fuel_type`.`id` left join `vehicle_type` on `vehicle`.`vehicle_type_id` = `vehicle_type`.`id` left join `party` on `party_vehicle`.`party_id` = `party`.`id` left join `person` on `person`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Person' left join `company` on `company`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Company' where `license_plate` = 'LI574' and `party_vehicle`.`is_owner` = 'Y' and `vehicle`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 8 - 2025-03-18 07:34:35 [0.15ms] */
select * from `party` where `party`.`id` = 39526 and `party`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 9 - 2025-03-18 07:34:35 [0.15ms] */
select * from `vehicle` where `id` = 50459 and `provisional` = 'Y' and `vehicle`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 10 - 2025-03-18 07:34:35 [0.15ms] */
select * from `party_vehicle` where `vehicle_id` = 50459 and `is_owner` = 'Y' and `party_vehicle`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 1 - 2025-03-18 07:34:35 [1.38ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 2 - 2025-03-18 07:34:35 [0.14ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 3 - 2025-03-18 07:34:35 [0.14ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 4 - 2025-03-18 07:34:35 [0.19ms] */
select * from `users` where `id` = 153 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 5 - 2025-03-18 07:34:35 [0.14ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 6 - 2025-03-18 07:34:35 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 7 - 2025-03-18 07:34:35 [0.31ms] */
select * from `vehicle` where `vehicle`.`id` = 50459 and `vehicle`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 8 - 2025-03-18 07:34:35 [0.22ms] */
select * from `vehicle` where `id` = 50459 and `provisional` = 'Y' and `vehicle`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 9 - 2025-03-18 07:34:35 [0.34ms] */
select * from `party_vehicle` where `vehicle_id` = 50459 and `is_owner` = 'Y' and `party_vehicle`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 10 - 2025-03-18 07:34:35 [0.66ms] */
select `vehicle_tax`.`id`, `term`.`year`, `term`.`quarter`, `invoice`.`invoice_amount`, `invoice`.`outstanding_balance`, `vehicle_tax`.`exempt`, `invoice`.`status`, `tax_sticker`.`name` as `tax_sticker`, CASE
                WHEN term.quarter = 1 THEN DATE_FORMAT(CONCAT(term.year, "-03-31"), "%d-%m-%Y")
                WHEN term.quarter = 2 THEN DATE_FORMAT(CONCAT(term.year, "-06-30"), "%d-%m-%Y")
                WHEN term.quarter = 3 THEN DATE_FORMAT(CONCAT(term.year, "-09-30"), "%d-%m-%Y")
                WHEN term.quarter = 4 THEN DATE_FORMAT(CONCAT(term.year, "-12-31"), "%d-%m-%Y")
                ELSE NULL
                END as due_date from `vehicle_tax` left join `term` on `vehicle_tax`.`term_id` = `term`.`id` left join `transaction` on `vehicle_tax`.`transaction_id` = `transaction`.`id` left join `invoice` on `transaction`.`invoice_id` = `invoice`.`id` left join `tax_sticker` on `vehicle_tax`.`tax_sticker_id` = `tax_sticker`.`id` where `vehicle_tax`.`vehicle_id` = 50459 and `vehicle_tax`.`deleted_at` is null and `transaction`.`deleted_at` is null and `invoice`.`deleted_at` is null order by `term`.`year` asc, `term`.`quarter` asc;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/region-list
   Query 1 - 2025-03-18 07:34:36 [1.29ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/region-list
   Query 2 - 2025-03-18 07:34:36 [0.14ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/region-list
   Query 3 - 2025-03-18 07:34:36 [0.14ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/region-list
   Query 4 - 2025-03-18 07:34:36 [0.17ms] */
select * from `users` where `id` = 153 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/region-list
   Query 5 - 2025-03-18 07:34:36 [0.14ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/region-list
   Query 6 - 2025-03-18 07:34:36 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/region-list
   Query 7 - 2025-03-18 07:34:36 [0.14ms] */
select `id`, `name` from `region` where `deleted_at` is null;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/payment_providers
   Query 1 - 2025-03-18 07:34:36 [1.96ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/payment_providers
   Query 2 - 2025-03-18 07:34:36 [0.27ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/payment_providers
   Query 3 - 2025-03-18 07:34:36 [0.27ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/payment_providers
   Query 4 - 2025-03-18 07:34:36 [0.34ms] */
select * from `users` where `id` = 153 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/payment_providers
   Query 5 - 2025-03-18 07:34:36 [0.31ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/payment_providers
   Query 6 - 2025-03-18 07:34:36 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/payment_providers
   Query 7 - 2025-03-18 07:34:36 [0.18ms] */
select * from `payment_method` where exists (select * from `payment_configurations` where `payment_method`.`id` = `payment_configurations`.`provider_id` and `fee_type` = 'Government' and `payment_configurations`.`deleted_at` is null) and `payment_method`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 1 - 2025-03-18 07:34:45 [2.01ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 2 - 2025-03-18 07:34:45 [0.26ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 3 - 2025-03-18 07:34:45 [0.25ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 4 - 2025-03-18 07:34:45 [0.36ms] */
select * from `users` where `id` = 153 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 5 - 2025-03-18 07:34:45 [0.14ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 6 - 2025-03-18 07:34:45 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 7 - 2025-03-18 07:34:45 [0.86ms] */
select `vehicle`.`id` as `vehicle_id`, `party`.`id` as `party_id`, `vehicle`.`license_plate`, `vehicle`.`year`, `vehicle`.`odometer`, `vehicle`.`vin`, `sub_category`.`name` as `sub_category`, `classification_type`.`name` as `classification`, `make`.`name` as `make`, `model`.`name` as `model`, `vehicle_color`.`name` as `vehicle_color`, `fuel_type`.`name` as `fuel_type`, `vehicle_type`.`name` as `vehicle_type`, CASE
                WHEN party_vehicle.id IS NULL THEN "UNREGISTERED" ELSE party_vehicle.status END AS status, CASE
                WHEN person.id IS NOT NULL THEN CONCAT(person.first_name, " ", person.second_name, " ", person.third_name, " ", person.fourth_name)
                WHEN company.id IS NOT NULL THEN company.company_name
                ELSE "No Entity Found"
                END AS owner, `party`.`partyable_type` as `owner_type`, `party_vehicle`.`registration_date`, `vehicle`.`created_at`, `vehicle`.`updated_at` from `vehicle` left join `party_vehicle` on `party_vehicle`.`vehicle_id` = `vehicle`.`id` left join `sub_category` on `vehicle`.`sub_category_id` = `sub_category`.`id` left join `classification_type` on `party_vehicle`.`classification_id` = `classification_type`.`id` left join `model` on `vehicle`.`model_id` = `model`.`id` left join `make` on `model`.`make_id` = `make`.`id` left join `vehicle_color` on `vehicle`.`vehicle_color_id` = `vehicle_color`.`id` left join `fuel_type` on `vehicle`.`fuel_type_id` = `fuel_type`.`id` left join `vehicle_type` on `vehicle`.`vehicle_type_id` = `vehicle_type`.`id` left join `party` on `party_vehicle`.`party_id` = `party`.`id` left join `person` on `person`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Person' left join `company` on `company`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Company' where `license_plate` = 'M3584' and `party_vehicle`.`is_owner` = 'Y' and `vehicle`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 8 - 2025-03-18 07:34:45 [0.24ms] */
select * from `party` where `party`.`id` = 58693 and `party`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 9 - 2025-03-18 07:34:45 [0.28ms] */
select * from `vehicle` where `id` = 90219 and `provisional` = 'Y' and `vehicle`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 10 - 2025-03-18 07:34:45 [0.24ms] */
select * from `party_vehicle` where `vehicle_id` = 90219 and `is_owner` = 'Y' and `party_vehicle`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 1 - 2025-03-18 07:34:45 [2.25ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 2 - 2025-03-18 07:34:45 [0.28ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 3 - 2025-03-18 07:34:45 [0.27ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 4 - 2025-03-18 07:34:45 [0.31ms] */
select * from `users` where `id` = 153 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 5 - 2025-03-18 07:34:45 [0.27ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 6 - 2025-03-18 07:34:45 [0.26ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 7 - 2025-03-18 07:34:45 [0.3ms] */
select * from `vehicle` where `vehicle`.`id` = 90219 and `vehicle`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 8 - 2025-03-18 07:34:45 [0.23ms] */
select * from `vehicle` where `id` = 90219 and `provisional` = 'Y' and `vehicle`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 9 - 2025-03-18 07:34:45 [0.26ms] */
select * from `party_vehicle` where `vehicle_id` = 90219 and `is_owner` = 'Y' and `party_vehicle`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 10 - 2025-03-18 07:34:45 [0.56ms] */
select `vehicle_tax`.`id`, `term`.`year`, `term`.`quarter`, `invoice`.`invoice_amount`, `invoice`.`outstanding_balance`, `vehicle_tax`.`exempt`, `invoice`.`status`, `tax_sticker`.`name` as `tax_sticker`, CASE
                WHEN term.quarter = 1 THEN DATE_FORMAT(CONCAT(term.year, "-03-31"), "%d-%m-%Y")
                WHEN term.quarter = 2 THEN DATE_FORMAT(CONCAT(term.year, "-06-30"), "%d-%m-%Y")
                WHEN term.quarter = 3 THEN DATE_FORMAT(CONCAT(term.year, "-09-30"), "%d-%m-%Y")
                WHEN term.quarter = 4 THEN DATE_FORMAT(CONCAT(term.year, "-12-31"), "%d-%m-%Y")
                ELSE NULL
                END as due_date from `vehicle_tax` left join `term` on `vehicle_tax`.`term_id` = `term`.`id` left join `transaction` on `vehicle_tax`.`transaction_id` = `transaction`.`id` left join `invoice` on `transaction`.`invoice_id` = `invoice`.`id` left join `tax_sticker` on `vehicle_tax`.`tax_sticker_id` = `tax_sticker`.`id` where `vehicle_tax`.`vehicle_id` = 90219 and `vehicle_tax`.`deleted_at` is null and `transaction`.`deleted_at` is null and `invoice`.`deleted_at` is null order by `term`.`year` asc, `term`.`quarter` asc;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/region-list
   Query 1 - 2025-03-18 07:34:46 [1.34ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/region-list
   Query 2 - 2025-03-18 07:34:46 [0.14ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/region-list
   Query 3 - 2025-03-18 07:34:46 [0.14ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/region-list
   Query 4 - 2025-03-18 07:34:46 [0.17ms] */
select * from `users` where `id` = 153 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/region-list
   Query 5 - 2025-03-18 07:34:46 [0.14ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/region-list
   Query 6 - 2025-03-18 07:34:46 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/region-list
   Query 7 - 2025-03-18 07:34:46 [0.14ms] */
select `id`, `name` from `region` where `deleted_at` is null;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/payment_providers
   Query 1 - 2025-03-18 07:34:46 [1.17ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/payment_providers
   Query 2 - 2025-03-18 07:34:46 [0.19ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/payment_providers
   Query 3 - 2025-03-18 07:34:46 [0.15ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/payment_providers
   Query 4 - 2025-03-18 07:34:46 [0.25ms] */
select * from `users` where `id` = 153 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/payment_providers
   Query 5 - 2025-03-18 07:34:46 [0.15ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/payment_providers
   Query 6 - 2025-03-18 07:34:46 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/payment_providers
   Query 7 - 2025-03-18 07:34:46 [0.18ms] */
select * from `payment_method` where exists (select * from `payment_configurations` where `payment_method`.`id` = `payment_configurations`.`provider_id` and `fee_type` = 'Government' and `payment_configurations`.`deleted_at` is null) and `payment_method`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 1 - 2025-03-18 07:35:02 [1.28ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 2 - 2025-03-18 07:35:02 [0.14ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 3 - 2025-03-18 07:35:02 [0.14ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 4 - 2025-03-18 07:35:02 [0.17ms] */
select * from `users` where `id` = 153 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 5 - 2025-03-18 07:35:02 [0.15ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 6 - 2025-03-18 07:35:02 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 7 - 2025-03-18 07:35:02 [0.7ms] */
select `vehicle`.`id` as `vehicle_id`, `party`.`id` as `party_id`, `vehicle`.`license_plate`, `vehicle`.`year`, `vehicle`.`odometer`, `vehicle`.`vin`, `sub_category`.`name` as `sub_category`, `classification_type`.`name` as `classification`, `make`.`name` as `make`, `model`.`name` as `model`, `vehicle_color`.`name` as `vehicle_color`, `fuel_type`.`name` as `fuel_type`, `vehicle_type`.`name` as `vehicle_type`, CASE
                WHEN party_vehicle.id IS NULL THEN "UNREGISTERED" ELSE party_vehicle.status END AS status, CASE
                WHEN person.id IS NOT NULL THEN CONCAT(person.first_name, " ", person.second_name, " ", person.third_name, " ", person.fourth_name)
                WHEN company.id IS NOT NULL THEN company.company_name
                ELSE "No Entity Found"
                END AS owner, `party`.`partyable_type` as `owner_type`, `party_vehicle`.`registration_date`, `vehicle`.`created_at`, `vehicle`.`updated_at` from `vehicle` left join `party_vehicle` on `party_vehicle`.`vehicle_id` = `vehicle`.`id` left join `sub_category` on `vehicle`.`sub_category_id` = `sub_category`.`id` left join `classification_type` on `party_vehicle`.`classification_id` = `classification_type`.`id` left join `model` on `vehicle`.`model_id` = `model`.`id` left join `make` on `model`.`make_id` = `make`.`id` left join `vehicle_color` on `vehicle`.`vehicle_color_id` = `vehicle_color`.`id` left join `fuel_type` on `vehicle`.`fuel_type_id` = `fuel_type`.`id` left join `vehicle_type` on `vehicle`.`vehicle_type_id` = `vehicle_type`.`id` left join `party` on `party_vehicle`.`party_id` = `party`.`id` left join `person` on `person`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Person' left join `company` on `company`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Company' where `license_plate` = 'M1034' and `party_vehicle`.`is_owner` = 'Y' and `vehicle`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 8 - 2025-03-18 07:35:02 [0.24ms] */
select * from `vehicle` where `license_plate` = 'M1034' and `vehicle`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 1 - 2025-03-18 07:35:09 [2.08ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 2 - 2025-03-18 07:35:09 [0.26ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 3 - 2025-03-18 07:35:09 [0.28ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 4 - 2025-03-18 07:35:09 [0.26ms] */
select * from `users` where `id` = 153 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 5 - 2025-03-18 07:35:09 [0.22ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 6 - 2025-03-18 07:35:09 [0.2ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 7 - 2025-03-18 07:35:09 [1.19ms] */
select `vehicle`.`id` as `vehicle_id`, `party`.`id` as `party_id`, `vehicle`.`license_plate`, `vehicle`.`year`, `vehicle`.`odometer`, `vehicle`.`vin`, `sub_category`.`name` as `sub_category`, `classification_type`.`name` as `classification`, `make`.`name` as `make`, `model`.`name` as `model`, `vehicle_color`.`name` as `vehicle_color`, `fuel_type`.`name` as `fuel_type`, `vehicle_type`.`name` as `vehicle_type`, CASE
                WHEN party_vehicle.id IS NULL THEN "UNREGISTERED" ELSE party_vehicle.status END AS status, CASE
                WHEN person.id IS NOT NULL THEN CONCAT(person.first_name, " ", person.second_name, " ", person.third_name, " ", person.fourth_name)
                WHEN company.id IS NOT NULL THEN company.company_name
                ELSE "No Entity Found"
                END AS owner, `party`.`partyable_type` as `owner_type`, `party_vehicle`.`registration_date`, `vehicle`.`created_at`, `vehicle`.`updated_at` from `vehicle` left join `party_vehicle` on `party_vehicle`.`vehicle_id` = `vehicle`.`id` left join `sub_category` on `vehicle`.`sub_category_id` = `sub_category`.`id` left join `classification_type` on `party_vehicle`.`classification_id` = `classification_type`.`id` left join `model` on `vehicle`.`model_id` = `model`.`id` left join `make` on `model`.`make_id` = `make`.`id` left join `vehicle_color` on `vehicle`.`vehicle_color_id` = `vehicle_color`.`id` left join `fuel_type` on `vehicle`.`fuel_type_id` = `fuel_type`.`id` left join `vehicle_type` on `vehicle`.`vehicle_type_id` = `vehicle_type`.`id` left join `party` on `party_vehicle`.`party_id` = `party`.`id` left join `person` on `person`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Person' left join `company` on `company`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Company' where `license_plate` = 'VE444' and `party_vehicle`.`is_owner` = 'Y' and `vehicle`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 8 - 2025-03-18 07:35:09 [0.52ms] */
select * from `party` where `party`.`id` = 53832 and `party`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 9 - 2025-03-18 07:35:09 [0.49ms] */
select * from `vehicle` where `id` = 87428 and `provisional` = 'Y' and `vehicle`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 10 - 2025-03-18 07:35:09 [0.54ms] */
select * from `party_vehicle` where `vehicle_id` = 87428 and `is_owner` = 'Y' and `party_vehicle`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 1 - 2025-03-18 07:35:09 [1.36ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 2 - 2025-03-18 07:35:09 [0.14ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 3 - 2025-03-18 07:35:09 [0.14ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 4 - 2025-03-18 07:35:09 [0.17ms] */
select * from `users` where `id` = 153 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 5 - 2025-03-18 07:35:09 [0.14ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 6 - 2025-03-18 07:35:09 [0.14ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 7 - 2025-03-18 07:35:09 [0.32ms] */
select * from `vehicle` where `vehicle`.`id` = 87428 and `vehicle`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 8 - 2025-03-18 07:35:09 [0.25ms] */
select * from `vehicle` where `id` = 87428 and `provisional` = 'Y' and `vehicle`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 9 - 2025-03-18 07:35:09 [0.28ms] */
select * from `party_vehicle` where `vehicle_id` = 87428 and `is_owner` = 'Y' and `party_vehicle`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 10 - 2025-03-18 07:35:09 [0.73ms] */
select `vehicle_tax`.`id`, `term`.`year`, `term`.`quarter`, `invoice`.`invoice_amount`, `invoice`.`outstanding_balance`, `vehicle_tax`.`exempt`, `invoice`.`status`, `tax_sticker`.`name` as `tax_sticker`, CASE
                WHEN term.quarter = 1 THEN DATE_FORMAT(CONCAT(term.year, "-03-31"), "%d-%m-%Y")
                WHEN term.quarter = 2 THEN DATE_FORMAT(CONCAT(term.year, "-06-30"), "%d-%m-%Y")
                WHEN term.quarter = 3 THEN DATE_FORMAT(CONCAT(term.year, "-09-30"), "%d-%m-%Y")
                WHEN term.quarter = 4 THEN DATE_FORMAT(CONCAT(term.year, "-12-31"), "%d-%m-%Y")
                ELSE NULL
                END as due_date from `vehicle_tax` left join `term` on `vehicle_tax`.`term_id` = `term`.`id` left join `transaction` on `vehicle_tax`.`transaction_id` = `transaction`.`id` left join `invoice` on `transaction`.`invoice_id` = `invoice`.`id` left join `tax_sticker` on `vehicle_tax`.`tax_sticker_id` = `tax_sticker`.`id` where `vehicle_tax`.`vehicle_id` = 87428 and `vehicle_tax`.`deleted_at` is null and `transaction`.`deleted_at` is null and `invoice`.`deleted_at` is null order by `term`.`year` asc, `term`.`quarter` asc;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/region-list
   Query 1 - 2025-03-18 07:35:10 [2.07ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/region-list
   Query 2 - 2025-03-18 07:35:10 [0.31ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/region-list
   Query 3 - 2025-03-18 07:35:10 [0.3ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/region-list
   Query 4 - 2025-03-18 07:35:10 [0.25ms] */
select * from `users` where `id` = 153 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/region-list
   Query 5 - 2025-03-18 07:35:10 [0.23ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/region-list
   Query 6 - 2025-03-18 07:35:10 [0.2ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/region-list
   Query 7 - 2025-03-18 07:35:10 [0.19ms] */
select `id`, `name` from `region` where `deleted_at` is null;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/payment_providers
   Query 1 - 2025-03-18 07:35:10 [2.26ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/payment_providers
   Query 2 - 2025-03-18 07:35:10 [0.28ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/payment_providers
   Query 3 - 2025-03-18 07:35:10 [0.27ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/payment_providers
   Query 4 - 2025-03-18 07:35:10 [0.25ms] */
select * from `users` where `id` = 153 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/payment_providers
   Query 5 - 2025-03-18 07:35:10 [0.22ms] */
select * from `oauth_access_tokens` where `id` = '7e744beca3001ed530fb578579a83f6b1f6aa157a0efe8572025b8eed76d50afb1aa464b961756ea' limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/payment_providers
   Query 6 - 2025-03-18 07:35:10 [0.2ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/payment_providers
   Query 7 - 2025-03-18 07:35:10 [0.27ms] */
select * from `payment_method` where exists (select * from `payment_configurations` where `payment_method`.`id` = `payment_configurations`.`provider_id` and `fee_type` = 'Government' and `payment_configurations`.`deleted_at` is null) and `payment_method`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 1 - 2025-03-18 07:39:05 [2.08ms] */
select * from `users` where `email` = 'ahmeddaakir54@puntlandgov.org' and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 2 - 2025-03-18 07:39:05 [0.18ms] */
select * from `users` where `id` = 153 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 3 - 2025-03-18 07:39:05 [0.37ms] */
select * from `userprofiles` where `userprofiles`.`user_id` = 153 and `userprofiles`.`user_id` is not null and `userprofiles`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 4 - 2025-03-18 07:39:05 [10.11ms] */
update `userprofiles` set `login_count` = 24, `last_login` = '2025-03-18 07:39:05', `userprofiles`.`updated_at` = '2025-03-18 07:39:05' where `id` = 153;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 5 - 2025-03-18 07:39:05 [0.33ms] */
select * from `users` where `email` = 'ahmeddaakir54@puntlandgov.org' and `users`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 6 - 2025-03-18 07:39:05 [0.58ms] */
select column_name as `column_name` from information_schema.columns where table_schema = 'prod_rta_temp' and table_name = 'roles';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 7 - 2025-03-18 07:39:05 [0.24ms] */
select `id`, `name`, `model_has_roles`.`model_id` as `pivot_model_id`, `model_has_roles`.`role_id` as `pivot_role_id`, `model_has_roles`.`model_type` as `pivot_model_type` from `roles` inner join `model_has_roles` on `roles`.`id` = `model_has_roles`.`role_id` where `model_has_roles`.`model_id` in (153) and `model_has_roles`.`model_type` = 'App\Models\User';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 8 - 2025-03-18 07:39:05 [0.21ms] */
select exists(select * from `oauth_personal_access_clients`) as `exists`;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 9 - 2025-03-18 07:39:05 [0.17ms] */
select * from `oauth_personal_access_clients` order by `id` desc limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 10 - 2025-03-18 07:39:05 [0.21ms] */
select * from `oauth_clients` where `oauth_clients`.`id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 11 - 2025-03-18 07:39:05 [0.21ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 12 - 2025-03-18 07:39:05 [0.23ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 13 - 2025-03-18 07:39:05 [3.4ms] */
insert into `oauth_access_tokens` (`id`, `user_id`, `client_id`, `scopes`, `revoked`, `created_at`, `updated_at`, `expires_at`) values ('be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d', 153, 5, '[]', 0, '2025-03-18 07:39:05', '2025-03-18 07:39:05', '2026-03-18 07:39:05');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 14 - 2025-03-18 07:39:05 [0.34ms] */
select * from `oauth_access_tokens` where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 15 - 2025-03-18 07:39:05 [3.3ms] */
update `oauth_access_tokens` set `name` = 'Secret' where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 1 - 2025-03-18 07:39:36 [1.53ms] */
select * from `oauth_access_tokens` where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 2 - 2025-03-18 07:39:36 [0.15ms] */
select * from `oauth_access_tokens` where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 3 - 2025-03-18 07:39:36 [0.14ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 4 - 2025-03-18 07:39:36 [0.18ms] */
select * from `users` where `id` = 153 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 5 - 2025-03-18 07:39:36 [0.14ms] */
select * from `oauth_access_tokens` where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 6 - 2025-03-18 07:39:36 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 7 - 2025-03-18 07:39:36 [0.34ms] */
select `vehicle`.`id` as `vehicle_id`, `party`.`id` as `party_id`, `vehicle`.`license_plate`, `vehicle`.`year`, `vehicle`.`odometer`, `vehicle`.`vin`, `sub_category`.`name` as `sub_category`, `classification_type`.`name` as `classification`, `make`.`name` as `make`, `model`.`name` as `model`, `vehicle_color`.`name` as `vehicle_color`, `fuel_type`.`name` as `fuel_type`, `vehicle_type`.`name` as `vehicle_type`, CASE
                WHEN party_vehicle.id IS NULL THEN "UNREGISTERED" ELSE party_vehicle.status END AS status, CASE
                WHEN person.id IS NOT NULL THEN CONCAT(person.first_name, " ", person.second_name, " ", person.third_name, " ", person.fourth_name)
                WHEN company.id IS NOT NULL THEN company.company_name
                ELSE "No Entity Found"
                END AS owner, `party`.`partyable_type` as `owner_type`, `party_vehicle`.`registration_date`, `vehicle`.`created_at`, `vehicle`.`updated_at` from `vehicle` left join `party_vehicle` on `party_vehicle`.`vehicle_id` = `vehicle`.`id` left join `sub_category` on `vehicle`.`sub_category_id` = `sub_category`.`id` left join `classification_type` on `party_vehicle`.`classification_id` = `classification_type`.`id` left join `model` on `vehicle`.`model_id` = `model`.`id` left join `make` on `model`.`make_id` = `make`.`id` left join `vehicle_color` on `vehicle`.`vehicle_color_id` = `vehicle_color`.`id` left join `fuel_type` on `vehicle`.`fuel_type_id` = `fuel_type`.`id` left join `vehicle_type` on `vehicle`.`vehicle_type_id` = `vehicle_type`.`id` left join `party` on `party_vehicle`.`party_id` = `party`.`id` left join `person` on `person`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Person' left join `company` on `company`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Company' where `license_plate` = 'VE444' and `party_vehicle`.`is_owner` = 'Y' and `vehicle`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 8 - 2025-03-18 07:39:36 [0.16ms] */
select * from `party` where `party`.`id` = 53832 and `party`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 9 - 2025-03-18 07:39:36 [0.16ms] */
select * from `vehicle` where `id` = 87428 and `provisional` = 'Y' and `vehicle`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/vehicle
   Query 10 - 2025-03-18 07:39:36 [0.16ms] */
select * from `party_vehicle` where `vehicle_id` = 87428 and `is_owner` = 'Y' and `party_vehicle`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 1 - 2025-03-18 07:39:37 [2.06ms] */
select * from `oauth_access_tokens` where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 2 - 2025-03-18 07:39:37 [0.27ms] */
select * from `oauth_access_tokens` where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 3 - 2025-03-18 07:39:37 [0.26ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 4 - 2025-03-18 07:39:37 [0.32ms] */
select * from `users` where `id` = 153 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 5 - 2025-03-18 07:39:37 [0.29ms] */
select * from `oauth_access_tokens` where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 6 - 2025-03-18 07:39:37 [0.26ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 7 - 2025-03-18 07:39:37 [0.18ms] */
select * from `vehicle` where `vehicle`.`id` = 87428 and `vehicle`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 8 - 2025-03-18 07:39:37 [0.14ms] */
select * from `vehicle` where `id` = 87428 and `provisional` = 'Y' and `vehicle`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 9 - 2025-03-18 07:39:37 [0.16ms] */
select * from `party_vehicle` where `vehicle_id` = 87428 and `is_owner` = 'Y' and `party_vehicle`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/taxes
   Query 10 - 2025-03-18 07:39:37 [0.25ms] */
select `vehicle_tax`.`id`, `term`.`year`, `term`.`quarter`, `invoice`.`invoice_amount`, `invoice`.`outstanding_balance`, `vehicle_tax`.`exempt`, `invoice`.`status`, `tax_sticker`.`name` as `tax_sticker`, CASE
                WHEN term.quarter = 1 THEN DATE_FORMAT(CONCAT(term.year, "-03-31"), "%d-%m-%Y")
                WHEN term.quarter = 2 THEN DATE_FORMAT(CONCAT(term.year, "-06-30"), "%d-%m-%Y")
                WHEN term.quarter = 3 THEN DATE_FORMAT(CONCAT(term.year, "-09-30"), "%d-%m-%Y")
                WHEN term.quarter = 4 THEN DATE_FORMAT(CONCAT(term.year, "-12-31"), "%d-%m-%Y")
                ELSE NULL
                END as due_date from `vehicle_tax` left join `term` on `vehicle_tax`.`term_id` = `term`.`id` left join `transaction` on `vehicle_tax`.`transaction_id` = `transaction`.`id` left join `invoice` on `transaction`.`invoice_id` = `invoice`.`id` left join `tax_sticker` on `vehicle_tax`.`tax_sticker_id` = `tax_sticker`.`id` where `vehicle_tax`.`vehicle_id` = 87428 and `vehicle_tax`.`deleted_at` is null and `transaction`.`deleted_at` is null and `invoice`.`deleted_at` is null order by `term`.`year` asc, `term`.`quarter` asc;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/region-list
   Query 1 - 2025-03-18 07:39:37 [1.42ms] */
select * from `oauth_access_tokens` where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d' limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/region-list
   Query 2 - 2025-03-18 07:39:37 [0.14ms] */
select * from `oauth_access_tokens` where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d' limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/region-list
   Query 3 - 2025-03-18 07:39:37 [0.14ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/region-list
   Query 4 - 2025-03-18 07:39:37 [0.19ms] */
select * from `users` where `id` = 153 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/region-list
   Query 5 - 2025-03-18 07:39:37 [0.14ms] */
select * from `oauth_access_tokens` where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d' limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/region-list
   Query 6 - 2025-03-18 07:39:37 [0.14ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/region-list
   Query 7 - 2025-03-18 07:39:37 [0.15ms] */
select `id`, `name` from `region` where `deleted_at` is null;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/payment_providers
   Query 1 - 2025-03-18 07:39:38 [1.94ms] */
select * from `oauth_access_tokens` where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d' limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/payment_providers
   Query 2 - 2025-03-18 07:39:38 [0.14ms] */
select * from `oauth_access_tokens` where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d' limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/payment_providers
   Query 3 - 2025-03-18 07:39:38 [0.14ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/payment_providers
   Query 4 - 2025-03-18 07:39:38 [0.17ms] */
select * from `users` where `id` = 153 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/payment_providers
   Query 5 - 2025-03-18 07:39:38 [0.14ms] */
select * from `oauth_access_tokens` where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d' limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/payment_providers
   Query 6 - 2025-03-18 07:39:38 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/payment_providers
   Query 7 - 2025-03-18 07:39:38 [0.18ms] */
select * from `payment_method` where exists (select * from `payment_configurations` where `payment_method`.`id` = `payment_configurations`.`provider_id` and `fee_type` = 'Government' and `payment_configurations`.`deleted_at` is null) and `payment_method`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 1 - 2025-03-18 07:40:21 [2.46ms] */
select * from `oauth_access_tokens` where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 2 - 2025-03-18 07:40:21 [0.28ms] */
select * from `oauth_access_tokens` where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 3 - 2025-03-18 07:40:21 [0.27ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 4 - 2025-03-18 07:40:21 [0.38ms] */
select * from `users` where `id` = 153 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 5 - 2025-03-18 07:40:21 [0.15ms] */
select * from `oauth_access_tokens` where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 6 - 2025-03-18 07:40:21 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 7 - 2025-03-18 07:40:21 [0.48ms] */
select * from `payment_configurations` where `provider_id` = 1 and `status` = 1 and `payment_configurations`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 8 - 2025-03-18 07:40:21 [0.36ms] */
select `transaction_id` from `vehicle_tax` where `id` in (401155) and `vehicle_tax`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 9 - 2025-03-18 07:40:21 [0.33ms] */
select `parent_id` from `transaction` where `id` in (510937) and `transaction`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 10 - 2025-03-18 07:40:21 [0.26ms] */
select `id` from `transaction` where 0 = 1 and `transaction`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 11 - 2025-03-18 07:40:21 [0.31ms] */
select * from `transaction` where 0 = 1 and `transaction`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 12 - 2025-03-18 07:40:21 [0.36ms] */
select * from `transaction` where `id` in (510937) and `transaction`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 13 - 2025-03-18 07:40:21 [0.39ms] */
select * from `invoice` where `invoice`.`id` = 486612 and `invoice`.`id` is not null and `invoice`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 14 - 2025-03-18 07:40:21 [3.58ms] */
update `invoice` set `updated_by` = 153, `invoice`.`updated_at` = '2025-03-18 07:40:21' where `id` = 486612;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 15 - 2025-03-18 07:40:21 [0.36ms] */
select * from `invoice` where `id` = 486612 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 16 - 2025-03-18 07:40:21 [3.44ms] */
insert into `activity_log` (`log_name`, `properties`, `causer_id`, `causer_type`, `subject_id`, `subject_type`, `description`, `updated_at`, `created_at`) values ('invoice', '{"attributes":[],"old":[]}', 153, 'App\Models\User', 486612, 'Modules\Transaction\Entities\Invoice', 'updated', '2025-03-18 07:40:21', '2025-03-18 07:40:21');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 17 - 2025-03-18 07:40:21 [0.58ms] */
select * from `service_workflow` where `service_id` = 2 and `service_workflow`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 18 - 2025-03-18 07:40:21 [0.55ms] */
select * from `workflow_definition` where `workflow_id` = 2 and `step_number` = 1 and `workflow_definition`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 19 - 2025-03-18 07:40:21 [3.58ms] */
update `transaction` set `updated_by` = 153, `transaction`.`updated_at` = '2025-03-18 07:40:21' where `id` = 510937;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 20 - 2025-03-18 07:40:21 [3.32ms] */
update `vehicle_tax` set `status` = 'OPEN', `vehicle_tax`.`updated_at` = '2025-03-18 07:40:21' where `id` in (401155) and `vehicle_tax`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 21 - 2025-03-18 07:40:21 [0.51ms] */
select * from `vehicle` where `vehicle`.`id` = 87428 and `vehicle`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 22 - 2025-03-18 07:40:21 [0.33ms] */
select * from `service` where `service`.`id` = 2 and `service`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 23 - 2025-03-18 07:40:21 [0.33ms] */
select count(*) as aggregate from `party_vehicle` where `vehicle_id` = 87428 and `status` = 'TRANSFER_INPROGRESS' and `party_vehicle`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 24 - 2025-03-18 07:40:21 [0.45ms] */
select * from `party_vehicle` where `vehicle_id` = 87428 and `is_owner` = 'Y' and `status` = 'REGISTERED' and `party_vehicle`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 25 - 2025-03-18 07:40:21 [0.33ms] */
select * from `party` where `party`.`id` = 53832 and `party`.`id` is not null and `party`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 26 - 2025-03-18 07:40:21 [0.38ms] */
select * from `vehicle` where `vehicle`.`id` = 87428 and `vehicle`.`id` is not null and `vehicle`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 27 - 2025-03-18 07:40:21 [0.2ms] */
select * from `service_workflow` where ((`service_id` = 2)) and `service_workflow`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 28 - 2025-03-18 07:40:21 [0.25ms] */
select * from `workflow_definition` where `workflow_id` = 2 and `step_number` = 1 and `workflow_definition`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 29 - 2025-03-18 07:40:21 [0.24ms] */
select * from `branches` where `branches`.`id` = 16 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 30 - 2025-03-18 07:40:21 [0.51ms] */
insert into `transaction` (`party_id`, `service_id`, `vehicle_id`, `driver_license_id`, `service_workflow_id`, `current_workflow_state_id`, `branch_id`, `deliver_district_id`, `district_id`, `status`, `tax_collection_point_id`, `comments`, `updated_by`, `created_by`, `created_at`, `updated_at`) values (53832, 2, 87428, null, 2, 6, 16, 37, 37, 'OPEN', 26, null, 153, 153, '2025-03-18 07:40:21', '2025-03-18 07:40:21');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 31 - 2025-03-18 07:40:21 [0.33ms] */
insert into `transaction_workflow` (`transaction_id`, `action`, `action_date`, `role_id`, `user_id`, `updated_by`, `created_by`, `created_at`, `updated_at`) values (511044, 'INITIATED', '2025-03-18 07:40:21', 5, 153, 153, 153, '2025-03-18 07:40:21', '2025-03-18 07:40:21');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 32 - 2025-03-18 07:40:21 [0.2ms] */
update `transaction` set `grouped` = 'N', `parent` = 'Y', `party_vehicle_id` = 9232, `transaction`.`updated_at` = '2025-03-18 07:40:21' where `id` = 511044;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 33 - 2025-03-18 07:40:21 [0.23ms] */
select sum(`invoice`.`outstanding_balance`) as aggregate from `vehicle_tax` inner join `transaction` on `transaction`.`id` = `vehicle_tax`.`transaction_id` inner join `invoice` on `invoice`.`id` = `transaction`.`invoice_id` where `vehicle_tax`.`id` in (401155) and `vehicle_tax`.`status` = 'OPEN' and `vehicle_tax`.`exempt` = 'N' and `vehicle_tax`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 34 - 2025-03-18 07:40:21 [0.2ms] */
select sum(`invoice`.`outstanding_balance`) as aggregate from `vehicle_tax` inner join `transaction` on `transaction`.`id` = `vehicle_tax`.`transaction_id` inner join `invoice` on `invoice`.`id` = `transaction`.`invoice_id` where `vehicle_tax`.`id` in (401155) and `vehicle_tax`.`status` = 'OPEN' and `vehicle_tax`.`exempt` = 'Y' and `vehicle_tax`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 35 - 2025-03-18 07:40:21 [0.29ms] */
insert into `invoice` (`transaction_id`, `party_id`, `invoice_date`, `due_date`, `invoice_amount`, `discounts`, `total_invoice_amount`, `outstanding_balance`, `taxes`, `status`, `grouped`, `parent`, `updated_by`, `created_by`, `created_at`, `updated_at`) values (511044, 53832, '2025-03-18 07:40:21', '2025-03-18 07:40:21', 64.00, 0, 64.00, 64.00, 0, 'OPEN', 'N', 'Y', 153, 153, '2025-03-18 07:40:21', '2025-03-18 07:40:21');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 36 - 2025-03-18 07:40:21 [0.2ms] */
select * from `invoice` where `id` = 486716 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 37 - 2025-03-18 07:40:21 [0.19ms] */
insert into `activity_log` (`log_name`, `properties`, `causer_id`, `causer_type`, `subject_id`, `subject_type`, `description`, `updated_at`, `created_at`) values ('invoice', '{"attributes":{"transaction_id":511044,"party_id":53832,"invoice_amount":"64.00","invoice_date":"2025-03-18 07:40:21","due_date":"2025-03-18 07:40:21","outstanding_balance":"64.00","discounts":"0.00","taxes":"0.00","total_invoice_amount":"64.00","status":"OPEN","siinpay_invoice_number":null,"invoice_number":null,"invoice_group_id":null,"parent_id":null,"grouped":"N","migration_id":null}}', 153, 'App\Models\User', 486716, 'Modules\Transaction\Entities\Invoice', 'created', '2025-03-18 07:40:21', '2025-03-18 07:40:21');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 38 - 2025-03-18 07:40:21 [0.25ms] */
select `invoice`.* from `vehicle_tax` inner join `transaction` on `transaction`.`id` = `vehicle_tax`.`transaction_id` inner join `invoice` on `invoice`.`id` = `transaction`.`invoice_id` where `vehicle_tax`.`id` in (401155) and `vehicle_tax`.`status` = 'OPEN' and `vehicle_tax`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 39 - 2025-03-18 07:40:21 [0.32ms] */
insert into `invoice_item` (`item`, `description`, `quantity`, `unit_price`, `total_price`, `invoice_id`, `updated_by`, `created_by`, `created_at`, `updated_at`) values ('Tax Service Fee', 'Combined Quarterly Tax Fees', 1, 64.00, 64, 486716, 153, 153, '2025-03-18 07:40:21', '2025-03-18 07:40:21');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 40 - 2025-03-18 07:40:21 [0.44ms] */
select * from `invoice_item` where `id` = 872821 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 41 - 2025-03-18 07:40:21 [0.45ms] */
insert into `activity_log` (`log_name`, `properties`, `causer_id`, `causer_type`, `subject_id`, `subject_type`, `description`, `updated_at`, `created_at`) values ('invoice_item', '{"attributes":{"item":"Tax Service Fee","description":"Combined Quarterly Tax Fees","unit_price":"64.00","quantity":1,"total_price":"64.00","invoice_id":486716}}', 153, 'App\Models\User', 872821, 'Modules\Transaction\Entities\InvoiceItem', 'created', '2025-03-18 07:40:21', '2025-03-18 07:40:21');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 42 - 2025-03-18 07:40:21 [0.36ms] */
update `invoice` set `invoice_number` = 'INV-667-486716782', `invoice`.`updated_at` = '2025-03-18 07:40:21' where `id` = 486716;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 43 - 2025-03-18 07:40:21 [0.39ms] */
select * from `invoice` where `id` = 486716 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 44 - 2025-03-18 07:40:21 [0.33ms] */
insert into `activity_log` (`log_name`, `properties`, `causer_id`, `causer_type`, `subject_id`, `subject_type`, `description`, `updated_at`, `created_at`) values ('invoice', '{"attributes":{"invoice_number":"INV-667-486716782"},"old":{"invoice_number":null}}', 153, 'App\Models\User', 486716, 'Modules\Transaction\Entities\Invoice', 'updated', '2025-03-18 07:40:21', '2025-03-18 07:40:21');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 45 - 2025-03-18 07:40:21 [0.41ms] */
select * from `vehicle_tax` where `vehicle_tax`.`id` = 401155 and `vehicle_tax`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 46 - 2025-03-18 07:40:21 [0.43ms] */
update `vehicle_tax` set `status` = 'INPROGRESS', `updated_by` = 153, `vehicle_tax`.`updated_at` = '2025-03-18 07:40:21' where `id` = 401155;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 47 - 2025-03-18 07:40:21 [0.35ms] */
select * from `vehicle_tax` where `id` = 401155 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 48 - 2025-03-18 07:40:21 [0.39ms] */
insert into `activity_log` (`log_name`, `properties`, `causer_id`, `causer_type`, `subject_id`, `subject_type`, `description`, `updated_at`, `created_at`) values ('vehicle_tax', '{"attributes":{"status":"INPROGRESS"},"old":{"status":"OPEN"}}', 153, 'App\Models\User', 401155, 'Modules\Vehicle\Entities\VehicleTax', 'updated', '2025-03-18 07:40:21', '2025-03-18 07:40:21');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 49 - 2025-03-18 07:40:21 [0.36ms] */
select * from `transaction` where `transaction`.`id` = 510937 and `transaction`.`id` is not null and `transaction`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 50 - 2025-03-18 07:40:21 [0.32ms] */
update `transaction` set `tax_collection_point_id` = 26, `parent_id` = 511044, `child` = 'Y', `grouped` = 'Y', `transaction`.`updated_at` = '2025-03-18 07:40:21' where `id` = 510937;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 51 - 2025-03-18 07:40:21 [0.3ms] */
select * from `invoice` where `invoice`.`id` = 486612 and `invoice`.`id` is not null and `invoice`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 52 - 2025-03-18 07:40:21 [0.47ms] */
update `invoice` set `parent_id` = 486716, `grouped` = 'Y', `invoice`.`updated_at` = '2025-03-18 07:40:21' where `id` = 486612;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 53 - 2025-03-18 07:40:21 [0.28ms] */
select * from `invoice` where `id` = 486612 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 54 - 2025-03-18 07:40:21 [0.28ms] */
insert into `activity_log` (`log_name`, `properties`, `causer_id`, `causer_type`, `subject_id`, `subject_type`, `description`, `updated_at`, `created_at`) values ('invoice', '{"attributes":{"parent_id":486716,"grouped":"Y"},"old":{"parent_id":null,"grouped":"N"}}', 153, 'App\Models\User', 486612, 'Modules\Transaction\Entities\Invoice', 'updated', '2025-03-18 07:40:21', '2025-03-18 07:40:21');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 55 - 2025-03-18 07:40:21 [0.33ms] */
select * from `transaction` where `transaction`.`id` = 510937 and `transaction`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 56 - 2025-03-18 07:40:21 [0.27ms] */
select * from `service_workflow` where `service_workflow`.`id` = 2 and `service_workflow`.`id` is not null and `service_workflow`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 57 - 2025-03-18 07:40:21 [0.26ms] */
select * from `service` where `service`.`id` = 2 and `service`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 58 - 2025-03-18 07:40:21 [0.27ms] */
select * from `workflow_definition` where `workflow_definition`.`id` = 6 and `workflow_definition`.`id` is not null and `workflow_definition`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 59 - 2025-03-18 07:40:21 [0.54ms] */
select column_name as `column_name` from information_schema.columns where table_schema = 'prod_rta_temp' and table_name = 'roles';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 60 - 2025-03-18 07:40:21 [0.26ms] */
select * from `roles` where `roles`.`id` = 5 and `roles`.`id` is not null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 61 - 2025-03-18 07:40:21 [0.2ms] */
insert into `transaction_workflow` (`transaction_id`, `action`, `action_date`, `role_id`, `user_id`, `comments`, `updated_by`, `created_by`, `created_at`, `updated_at`) values (510937, 'APPROVED', '2025-03-18 07:40:21', 5, 153, null, 153, 153, '2025-03-18 07:40:21', '2025-03-18 07:40:21');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 62 - 2025-03-18 07:40:21 [0.2ms] */
select * from `workflow_definition` where `workflow_id` = 2 and `step_number` = 2 and `workflow_definition`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 63 - 2025-03-18 07:40:21 [0.2ms] */
update `transaction` set `current_workflow_state_id` = 7, `status` = 'INPROGRESS', `transaction`.`updated_at` = '2025-03-18 07:40:21' where `id` = 510937;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 64 - 2025-03-18 07:40:21 [0.17ms] */
select * from `service` where `service`.`id` = 2 and `service`.`id` is not null and `service`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 65 - 2025-03-18 07:40:21 [0.2ms] */
select * from `invoice` where `invoice`.`id` = 486612 and `invoice`.`id` is not null and `invoice`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 66 - 2025-03-18 07:40:21 [0.17ms] */
update `transaction` set `invoice_id` = 486716, `transaction`.`updated_at` = '2025-03-18 07:40:21' where `id` = 511044;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 67 - 2025-03-18 07:40:21 [0.53ms] */
update `vehicle` set `updated_by` = 153, `vehicle`.`updated_at` = '2025-03-18 07:40:21' where `id` = 87428;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 68 - 2025-03-18 07:40:21 [0.2ms] */
select * from `vehicle` where `id` = 87428 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 69 - 2025-03-18 07:40:21 [0.24ms] */
insert into `activity_log` (`log_name`, `properties`, `causer_id`, `causer_type`, `subject_id`, `subject_type`, `description`, `updated_at`, `created_at`) values ('vehicle', '{"attributes":[],"old":[]}', 153, 'App\Models\User', 87428, 'Modules\Vehicle\Entities\Vehicle', 'updated', '2025-03-18 07:40:21', '2025-03-18 07:40:21');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 70 - 2025-03-18 07:40:21 [0.3ms] */
insert into `audits` (`old_values`, `new_values`, `event`, `auditable_id`, `auditable_type`, `user_id`, `user_type`, `tags`, `ip_address`, `user_agent`, `url`, `updated_at`, `created_at`) values ('{"updated_by":25}', '{"updated_by":153}', 'updated', 87428, 'Modules\Vehicle\Entities\Vehicle', 153, 'App\Models\User', null, '41.223.109.136', 'Dart/3.4 (dart:io)', 'https://testtra.puntlandgov.org/api/make_payment', '2025-03-18 07:40:21', '2025-03-18 07:40:21');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 71 - 2025-03-18 07:40:21 [0.22ms] */
select * from `transaction` where `transaction`.`id` = 511044 and `transaction`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 72 - 2025-03-18 07:40:21 [0.17ms] */
select * from `service_workflow` where `service_workflow`.`id` = 2 and `service_workflow`.`id` is not null and `service_workflow`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 73 - 2025-03-18 07:40:21 [0.16ms] */
select * from `service` where `service`.`id` = 2 and `service`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 74 - 2025-03-18 07:40:21 [0.2ms] */
select * from `workflow_definition` where `workflow_definition`.`id` = 6 and `workflow_definition`.`id` is not null and `workflow_definition`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 75 - 2025-03-18 07:40:21 [0.17ms] */
insert into `transaction_workflow` (`transaction_id`, `action`, `action_date`, `role_id`, `user_id`, `comments`, `updated_by`, `created_by`, `created_at`, `updated_at`) values (511044, 'APPROVED', '2025-03-18 07:40:21', 5, 153, null, 153, 153, '2025-03-18 07:40:21', '2025-03-18 07:40:21');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 76 - 2025-03-18 07:40:21 [0.19ms] */
select * from `workflow_definition` where `workflow_id` = 2 and `step_number` = 2 and `workflow_definition`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 77 - 2025-03-18 07:40:21 [0.2ms] */
update `transaction` set `current_workflow_state_id` = 7, `status` = 'INPROGRESS', `transaction`.`updated_at` = '2025-03-18 07:40:21' where `id` = 511044;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 78 - 2025-03-18 07:40:21 [0.17ms] */
select * from `service` where `service`.`id` = 2 and `service`.`id` is not null and `service`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 79 - 2025-03-18 07:40:21 [0.2ms] */
select * from `invoice` where `invoice`.`id` = 486716 and `invoice`.`id` is not null and `invoice`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 80 - 2025-03-18 07:40:21 [0.19ms] */
select `transaction_id` from `vehicle_tax` where `id` in (401155) and `vehicle_tax`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 81 - 2025-03-18 07:40:21 [0.23ms] */
select * from `invoice` where `transaction_id` = 510937 and `invoice`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 82 - 2025-03-18 07:40:21 [0.28ms] */
select * from `invoice_item` where `invoice_item`.`invoice_id` = 486612 and `invoice_item`.`invoice_id` is not null and `invoice_item`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 83 - 2025-03-18 07:40:21 [0.27ms] */
select * from `transaction` where `transaction`.`id` = 510937 and `transaction`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 84 - 2025-03-18 07:40:21 [0.27ms] */
select * from `merchants` where `merchants`.`id` = 1 and `merchants`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 85 - 2025-03-18 07:40:21 [0.25ms] */
select * from `user_accounts` where `user_accounts`.`payment_provider_id` = 1 and `user_accounts`.`payment_provider_id` is not null and `user_accounts`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 86 - 2025-03-18 07:40:21 [0.22ms] */
select * from `merchants` where `merchants`.`id` = 3 and `merchants`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/make_payment
   Query 87 - 2025-03-18 07:40:21 [0.21ms] */
select * from `user_accounts` where `user_accounts`.`payment_provider_id` = 3 and `user_accounts`.`payment_provider_id` is not null and `user_accounts`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/payment_providers
   Query 1 - 2025-03-18 07:40:21 [2.28ms] */
select * from `oauth_access_tokens` where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d' limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/payment_providers
   Query 2 - 2025-03-18 07:40:21 [0.28ms] */
select * from `oauth_access_tokens` where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d' limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/payment_providers
   Query 3 - 2025-03-18 07:40:21 [0.27ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/payment_providers
   Query 4 - 2025-03-18 07:40:21 [0.26ms] */
select * from `users` where `id` = 153 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/payment_providers
   Query 5 - 2025-03-18 07:40:21 [0.22ms] */
select * from `oauth_access_tokens` where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d' limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/payment_providers
   Query 6 - 2025-03-18 07:40:21 [0.21ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): GET https://testtra.puntlandgov.org/api/payment_providers
   Query 7 - 2025-03-18 07:40:21 [0.26ms] */
select * from `payment_method` where exists (select * from `payment_configurations` where `payment_method`.`id` = `payment_configurations`.`provider_id` and `fee_type` = 'Government' and `payment_configurations`.`deleted_at` is null) and `payment_method`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/get_receipt_number
   Query 1 - 2025-03-18 07:41:34 [2.09ms] */
select * from `oauth_access_tokens` where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/get_receipt_number
   Query 2 - 2025-03-18 07:41:34 [0.26ms] */
select * from `oauth_access_tokens` where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/get_receipt_number
   Query 3 - 2025-03-18 07:41:34 [0.3ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/get_receipt_number
   Query 4 - 2025-03-18 07:41:34 [0.38ms] */
select * from `users` where `id` = 153 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/get_receipt_number
   Query 5 - 2025-03-18 07:41:34 [0.18ms] */
select * from `oauth_access_tokens` where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/get_receipt_number
   Query 6 - 2025-03-18 07:41:34 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/get_receipt_number
   Query 7 - 2025-03-18 07:41:34 [1.78ms] */
select `id`, `receipt_number` from `receipts` where `used` = 'No' and `user_id` = 153 and `type` = 'GOV_RECEIPT_NUMBER' and `receipts`.`deleted_at` is null order by `id` asc limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 1 - 2025-03-18 07:41:36 [1.36ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 2 - 2025-03-18 07:41:36 [0.16ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 3 - 2025-03-18 07:41:36 [0.39ms] */
select * from `userprofiles` where `userprofiles`.`user_id` = 149 and `userprofiles`.`user_id` is not null and `userprofiles`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 4 - 2025-03-18 07:41:36 [13.1ms] */
update `userprofiles` set `login_count` = 6359, `last_login` = '2025-03-18 07:41:36', `userprofiles`.`updated_at` = '2025-03-18 07:41:36' where `id` = 149;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 5 - 2025-03-18 07:41:36 [0.25ms] */
select * from `users` where `email` = 'sivaprasad@admin.com' and `users`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 6 - 2025-03-18 07:41:36 [0.58ms] */
select column_name as `column_name` from information_schema.columns where table_schema = 'prod_rta_temp' and table_name = 'roles';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 7 - 2025-03-18 07:41:36 [0.24ms] */
select `id`, `name`, `model_has_roles`.`model_id` as `pivot_model_id`, `model_has_roles`.`role_id` as `pivot_role_id`, `model_has_roles`.`model_type` as `pivot_model_type` from `roles` inner join `model_has_roles` on `roles`.`id` = `model_has_roles`.`role_id` where `model_has_roles`.`model_id` in (149) and `model_has_roles`.`model_type` = 'App\Models\User';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 8 - 2025-03-18 07:41:36 [0.2ms] */
select exists(select * from `oauth_personal_access_clients`) as `exists`;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 9 - 2025-03-18 07:41:36 [0.17ms] */
select * from `oauth_personal_access_clients` order by `id` desc limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 10 - 2025-03-18 07:41:36 [0.21ms] */
select * from `oauth_clients` where `oauth_clients`.`id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 11 - 2025-03-18 07:41:36 [0.21ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 12 - 2025-03-18 07:41:36 [0.2ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 13 - 2025-03-18 07:41:36 [4.75ms] */
insert into `oauth_access_tokens` (`id`, `user_id`, `client_id`, `scopes`, `revoked`, `created_at`, `updated_at`, `expires_at`) values ('7cf17992082f0554bc13d22e3f01d135f39cd1437dd010a9244f278a4712be6dab7c4c7644c009fc', 149, 5, '[]', 0, '2025-03-18 07:41:36', '2025-03-18 07:41:36', '2026-03-18 07:41:36');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 14 - 2025-03-18 07:41:36 [0.25ms] */
select * from `oauth_access_tokens` where `id` = '7cf17992082f0554bc13d22e3f01d135f39cd1437dd010a9244f278a4712be6dab7c4c7644c009fc' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/login
   Query 15 - 2025-03-18 07:41:36 [4.9ms] */
update `oauth_access_tokens` set `name` = 'Secret' where `id` = '7cf17992082f0554bc13d22e3f01d135f39cd1437dd010a9244f278a4712be6dab7c4c7644c009fc';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 1 - 2025-03-18 07:41:37 [2.23ms] */
select * from `oauth_access_tokens` where `id` = '7cf17992082f0554bc13d22e3f01d135f39cd1437dd010a9244f278a4712be6dab7c4c7644c009fc' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 2 - 2025-03-18 07:41:37 [0.27ms] */
select * from `oauth_access_tokens` where `id` = '7cf17992082f0554bc13d22e3f01d135f39cd1437dd010a9244f278a4712be6dab7c4c7644c009fc' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 3 - 2025-03-18 07:41:37 [0.26ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 4 - 2025-03-18 07:41:37 [0.26ms] */
select * from `users` where `id` = 149 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 5 - 2025-03-18 07:41:37 [0.22ms] */
select * from `oauth_access_tokens` where `id` = '7cf17992082f0554bc13d22e3f01d135f39cd1437dd010a9244f278a4712be6dab7c4c7644c009fc' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 6 - 2025-03-18 07:41:37 [0.2ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payments
   Query 7 - 2025-03-18 07:41:37 [97.65ms] */
select DISTINCT payment.id as payment_id, `party`.`id` as `customer_id`, CASE
                WHEN person.id IS NOT NULL THEN CONCAT(person.first_name, " ", person.second_name, " ", person.third_name, " ", person.fourth_name)
                WHEN company.id IS NOT NULL THEN company.company_name
                ELSE "No Entity Found"
                END AS customer_name, `vehicle`.`license_plate`, `payment`.`payment_amount`, `external_payment_reference_no` as `payment_reference_number`, `payment`.`payment_date`, `payment_method`.`name` as `payment_method`, `payment`.`paid_by`, `payment`.`paid_by_mobile` from `payment` left join `invoice_payment` on `invoice_payment`.`payment_id` = `payment`.`id` left join `invoice` on `invoice_payment`.`invoice_id` = `invoice`.`id` and `invoice`.`parent` = 'N' left join `transaction` on `transaction`.`invoice_id` = `invoice`.`id` left join `service` on `transaction`.`service_id` = `service`.`id` left join `vehicle` on `transaction`.`vehicle_id` = `vehicle`.`id` left join `party` on `transaction`.`party_id` = `party`.`id` left join `payment_method` on `payment`.`payment_method_id` = `payment_method`.`id` left join `person` on `person`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Person' left join `company` on `company`.`id` = `party`.`partyable_id` and `party`.`partyable_type` = 'Company' where `service`.`name` = 'Tax' and `payment`.`id` = 89243 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payment_confirm_image
   Query 1 - 2025-03-18 07:42:25 [1.91ms] */
select * from `oauth_access_tokens` where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payment_confirm_image
   Query 2 - 2025-03-18 07:42:25 [0.27ms] */
select * from `oauth_access_tokens` where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payment_confirm_image
   Query 3 - 2025-03-18 07:42:25 [0.27ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payment_confirm_image
   Query 4 - 2025-03-18 07:42:25 [0.39ms] */
select * from `users` where `id` = 153 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payment_confirm_image
   Query 5 - 2025-03-18 07:42:25 [0.31ms] */
select * from `oauth_access_tokens` where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payment_confirm_image
   Query 6 - 2025-03-18 07:42:25 [0.29ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payment_confirm_image
   Query 7 - 2025-03-18 07:42:25 [0.58ms] */
delete from `payment_documents` where `transaction_id` = 510937 and `type` = 'GOV_RECEIPT_IMAGE';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payment_confirm_image
   Query 8 - 2025-03-18 07:42:25 [0.52ms] */
select * from `payment_documents` where `type` = 'GOV_RECEIPT_IMAGE' and `receipt_number` = 2510011;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payment_confirm_image
   Query 9 - 2025-03-18 07:42:25 [0.29ms] */
select * from `transaction` where `transaction`.`id` = 510937 and `transaction`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payment_confirm_image
   Query 10 - 2025-03-18 07:42:26 [365.72ms] */
select * from `transaction` where `parent_id` = 511044 and `transaction`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payment_confirm_image
   Query 11 - 2025-03-18 07:42:26 [6.31ms] */
insert into `payment_documents` (`transaction_id`, `type`, `receipt_number`, `payment_provider_id`, `updated_at`, `created_at`) values (510937, 'GOV_RECEIPT_IMAGE', 2510011, 1, '2025-03-18 07:42:26', '2025-03-18 07:42:26');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payment_confirm_image
   Query 12 - 2025-03-18 07:42:26 [3.1ms] */
insert into `payment_documents` (`transaction_id`, `type`, `receipt_number`, `payment_provider_id`, `updated_at`, `created_at`) values (511044, 'GOV_RECEIPT_IMAGE', 2510011, 1, '2025-03-18 07:42:26', '2025-03-18 07:42:26');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payment_confirm_image
   Query 13 - 2025-03-18 07:42:26 [9.08ms] */
update `receipts` set `used` = 'Yes', `receipts`.`updated_at` = '2025-03-18 07:42:26' where `receipt_number` = 2510011 and `type` = 'GOV_RECEIPT_NUMBER' and `receipts`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/get_receipt_number
   Query 1 - 2025-03-18 07:42:57 [1.36ms] */
select * from `oauth_access_tokens` where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/get_receipt_number
   Query 2 - 2025-03-18 07:42:57 [0.14ms] */
select * from `oauth_access_tokens` where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/get_receipt_number
   Query 3 - 2025-03-18 07:42:57 [0.17ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/get_receipt_number
   Query 4 - 2025-03-18 07:42:57 [0.17ms] */
select * from `users` where `id` = 153 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/get_receipt_number
   Query 5 - 2025-03-18 07:42:57 [0.15ms] */
select * from `oauth_access_tokens` where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/get_receipt_number
   Query 6 - 2025-03-18 07:42:57 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/get_receipt_number
   Query 7 - 2025-03-18 07:42:57 [1.49ms] */
select `id`, `receipt_number` from `receipts` where `used` = 'No' and `user_id` = 153 and `type` = 'SERVICE_RECEIPT_NUMBER' and `receipts`.`deleted_at` is null order by `id` asc limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/get_receipt_number
   Query 1 - 2025-03-18 07:42:58 [1.42ms] */
select * from `oauth_access_tokens` where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/get_receipt_number
   Query 2 - 2025-03-18 07:42:58 [0.14ms] */
select * from `oauth_access_tokens` where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/get_receipt_number
   Query 3 - 2025-03-18 07:42:58 [0.18ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/get_receipt_number
   Query 4 - 2025-03-18 07:42:58 [0.25ms] */
select * from `users` where `id` = 153 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/get_receipt_number
   Query 5 - 2025-03-18 07:42:58 [0.23ms] */
select * from `oauth_access_tokens` where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/get_receipt_number
   Query 6 - 2025-03-18 07:42:58 [0.21ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/get_receipt_number
   Query 7 - 2025-03-18 07:42:58 [0.15ms] */
select `id`, `receipt_number` from `receipts` where `used` = 'No' and `user_id` = 153 and `type` = 'SERVICE_RECEIPT_NUMBER' and `receipts`.`deleted_at` is null order by `id` asc limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payment_confirm_image
   Query 1 - 2025-03-18 07:43:15 [2.04ms] */
select * from `oauth_access_tokens` where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payment_confirm_image
   Query 2 - 2025-03-18 07:43:15 [0.26ms] */
select * from `oauth_access_tokens` where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payment_confirm_image
   Query 3 - 2025-03-18 07:43:15 [0.35ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payment_confirm_image
   Query 4 - 2025-03-18 07:43:15 [0.25ms] */
select * from `users` where `id` = 153 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payment_confirm_image
   Query 5 - 2025-03-18 07:43:15 [0.22ms] */
select * from `oauth_access_tokens` where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payment_confirm_image
   Query 6 - 2025-03-18 07:43:15 [0.2ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payment_confirm_image
   Query 7 - 2025-03-18 07:43:15 [0.71ms] */
delete from `payment_documents` where `transaction_id` = 510937 and `type` = 'SERVICE_RECEIPT_IMAGE';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payment_confirm_image
   Query 8 - 2025-03-18 07:43:15 [0.77ms] */
select * from `payment_documents` where `type` = 'SERVICE_RECEIPT_IMAGE' and `receipt_number` = 1110011;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payment_confirm_image
   Query 9 - 2025-03-18 07:43:15 [0.31ms] */
select * from `transaction` where `transaction`.`id` = 510937 and `transaction`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payment_confirm_image
   Query 10 - 2025-03-18 07:43:15 [0.28ms] */
select * from `transaction` where `parent_id` = 511044 and `transaction`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payment_confirm_image
   Query 11 - 2025-03-18 07:43:15 [6.17ms] */
insert into `payment_documents` (`transaction_id`, `type`, `receipt_number`, `payment_provider_id`, `updated_at`, `created_at`) values (510937, 'SERVICE_RECEIPT_IMAGE', 1110011, 1, '2025-03-18 07:43:15', '2025-03-18 07:43:15');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payment_confirm_image
   Query 12 - 2025-03-18 07:43:15 [3.29ms] */
insert into `payment_documents` (`transaction_id`, `type`, `receipt_number`, `payment_provider_id`, `updated_at`, `created_at`) values (511044, 'SERVICE_RECEIPT_IMAGE', 1110011, 1, '2025-03-18 07:43:15', '2025-03-18 07:43:15');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payment_confirm_image
   Query 13 - 2025-03-18 07:43:15 [10.05ms] */
update `receipts` set `used` = 'Yes', `receipts`.`updated_at` = '2025-03-18 07:43:15' where `receipt_number` = 1110011 and `type` = 'SERVICE_RECEIPT_NUMBER' and `receipts`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 1 - 2025-03-18 07:43:15 [1.95ms] */
select * from `oauth_access_tokens` where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 2 - 2025-03-18 07:43:15 [0.28ms] */
select * from `oauth_access_tokens` where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 3 - 2025-03-18 07:43:15 [0.27ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 4 - 2025-03-18 07:43:15 [0.26ms] */
select * from `users` where `id` = 153 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 5 - 2025-03-18 07:43:15 [0.22ms] */
select * from `oauth_access_tokens` where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 6 - 2025-03-18 07:43:15 [0.2ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 7 - 2025-03-18 07:43:15 [0.26ms] */
select * from `transaction` where `transaction`.`id` = 510937 and `transaction`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 8 - 2025-03-18 07:43:15 [0.45ms] */
select * from `transaction` where `transaction`.`id` = 511044 and `transaction`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 9 - 2025-03-18 07:43:15 [0.25ms] */
select * from `invoice_payment` where `invoice_id` = 486716 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 10 - 2025-03-18 07:43:15 [102.48ms] */
select `invoice`.* from `invoice` inner join `transaction` on `invoice`.`id` = `transaction`.`invoice_id` where `invoice`.`invoice_amount` <> 0.00 and `transaction`.`parent_id` = 511044 and `invoice`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 11 - 2025-03-18 07:43:15 [98.02ms] */
select sum(`outstanding_balance`) as aggregate from `invoice` inner join `transaction` on `invoice`.`id` = `transaction`.`invoice_id` where `invoice`.`invoice_amount` <> 0.00 and `transaction`.`parent_id` = 511044 and `invoice`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 12 - 2025-03-18 07:43:15 [0.23ms] */
select * from `transaction` where `transaction`.`id` = 511044 and `transaction`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 13 - 2025-03-18 07:43:15 [0.29ms] */
select * from `service_workflow` where `service_workflow`.`id` = 2 and `service_workflow`.`id` is not null and `service_workflow`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 14 - 2025-03-18 07:43:15 [0.21ms] */
select * from `service` where `service`.`id` = 2 and `service`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 15 - 2025-03-18 07:43:15 [0.18ms] */
select * from `service` where `service`.`id` = 2 and `service`.`id` is not null and `service`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 16 - 2025-03-18 07:43:15 [149.03ms] */
select sum(`invoice`.`invoice_amount`) as aggregate from `vehicle_tax` inner join `term` on `term`.`id` = `vehicle_tax`.`term_id` inner join `transaction` on `transaction`.`id` = `vehicle_tax`.`transaction_id` inner join `invoice` on `invoice`.`id` = `transaction`.`invoice_id` where `transaction`.`parent_id` = 511044 and `vehicle_tax`.`exempt` = 'Y' and `vehicle_tax`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 17 - 2025-03-18 07:43:15 [0.47ms] */
select * from `party` where `party`.`id` = 53832 and `party`.`id` is not null and `party`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 18 - 2025-03-18 07:43:15 [0.78ms] */
insert into `Payment` (`payment_date`, `external_payment_reference_no`, `payment_receipt_number`, `payment_method_id`, `payment_amount`, `paid_by`, `paid_by_mobile`, `siinpay_payref_number`, `district_id`, `payment_collected_by`, `updated_by`, `created_by`, `created_at`, `updated_at`) values ('2025-03-18 07:43:15', 123, 2510011, 1, 64.00, 'sharmaake said', 6740558, null, 37, 153, 153, 153, '2025-03-18 07:43:15', '2025-03-18 07:43:15');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 19 - 2025-03-18 07:43:15 [0.3ms] */
select * from `Payment` where `id` = 177677 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 20 - 2025-03-18 07:43:15 [0.46ms] */
insert into `activity_log` (`log_name`, `properties`, `causer_id`, `causer_type`, `subject_id`, `subject_type`, `description`, `updated_at`, `created_at`) values ('Payment', '{"attributes":{"payment_method_id":1,"payment_amount":"64.00","payment_date":"2025-03-18 07:43:15","external_payment_reference_no":"123","payment_receipt_number":"2510011","siinpay_payref_number":null,"paid_by":"sharmaake said","paid_by_mobile":"6740558","district_id":37,"migration_id":null,"payment_collected_by":153}}', 153, 'App\Models\User', 177677, 'Modules\Transaction\Entities\Payment', 'created', '2025-03-18 07:43:15', '2025-03-18 07:43:15');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 21 - 2025-03-18 07:43:15 [0.37ms] */
select * from `transaction` where `transaction`.`id` = 511044 and `transaction`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 22 - 2025-03-18 07:43:15 [0.3ms] */
select * from `service_workflow` where `service_workflow`.`id` = 2 and `service_workflow`.`id` is not null and `service_workflow`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 23 - 2025-03-18 07:43:15 [0.32ms] */
select * from `service` where `service`.`id` = 2 and `service`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 24 - 2025-03-18 07:43:15 [0.38ms] */
select * from `invoice` where `invoice`.`id` = 486612 and `invoice`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 25 - 2025-03-18 07:43:15 [0.23ms] */
insert into `invoice_payment` (`created_at`, `invoice_id`, `payment_id`, `updated_at`) values ('2025-03-18 07:43:15', 486612, 177677, '2025-03-18 07:43:15');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 26 - 2025-03-18 07:43:15 [0.2ms] */
select * from `invoice` where `invoice`.`id` = 486612 and `invoice`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 27 - 2025-03-18 07:43:15 [0.28ms] */
select `Payment`.*, `invoice_payment`.`invoice_id` as `pivot_invoice_id`, `invoice_payment`.`payment_id` as `pivot_payment_id`, `invoice_payment`.`created_at` as `pivot_created_at`, `invoice_payment`.`updated_at` as `pivot_updated_at` from `Payment` inner join `invoice_payment` on `Payment`.`id` = `invoice_payment`.`payment_id` where `invoice_payment`.`invoice_id` = 486612 and `Payment`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 28 - 2025-03-18 07:43:15 [0.3ms] */
select * from `invoice_item` where `invoice_item`.`invoice_id` = 486612 and `invoice_item`.`invoice_id` is not null and `invoice_item`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 29 - 2025-03-18 07:43:15 [0.31ms] */
update `invoice` set `invoice_amount` = 64, `outstanding_balance` = 0, `discounts` = 0, `total_invoice_amount` = 64, `status` = 'PAID', `invoice`.`updated_at` = '2025-03-18 07:43:15' where `id` = 486612;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 30 - 2025-03-18 07:43:15 [0.18ms] */
select * from `invoice` where `id` = 486612 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 31 - 2025-03-18 07:43:15 [0.19ms] */
insert into `activity_log` (`log_name`, `properties`, `causer_id`, `causer_type`, `subject_id`, `subject_type`, `description`, `updated_at`, `created_at`) values ('invoice', '{"attributes":{"outstanding_balance":"0.00","status":"PAID"},"old":{"outstanding_balance":"64.00","status":"OPEN"}}', 153, 'App\Models\User', 486612, 'Modules\Transaction\Entities\Invoice', 'updated', '2025-03-18 07:43:15', '2025-03-18 07:43:15');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 32 - 2025-03-18 07:43:15 [0.24ms] */
select * from `transaction` where `transaction`.`id` = 510937 and `transaction`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 33 - 2025-03-18 07:43:15 [0.15ms] */
select * from `transaction` where `transaction`.`id` = 510937 and `transaction`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 34 - 2025-03-18 07:43:15 [0.13ms] */
select * from `service_workflow` where `service_workflow`.`id` = 2 and `service_workflow`.`id` is not null and `service_workflow`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 35 - 2025-03-18 07:43:15 [0.13ms] */
select * from `service` where `service`.`id` = 2 and `service`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 36 - 2025-03-18 07:43:15 [0.24ms] */
select * from `workflow_definition` where `workflow_definition`.`id` = 7 and `workflow_definition`.`id` is not null and `workflow_definition`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 37 - 2025-03-18 07:43:15 [0.33ms] */
insert into `transaction_workflow` (`transaction_id`, `action`, `action_date`, `role_id`, `user_id`, `comments`, `updated_by`, `created_by`, `created_at`, `updated_at`) values (510937, 'PAID', '2025-03-18 07:43:15', 7, 153, null, 153, 153, '2025-03-18 07:43:15', '2025-03-18 07:43:15');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 38 - 2025-03-18 07:43:15 [0.23ms] */
select * from `workflow_definition` where `workflow_id` = 2 and `step_number` = 3 and `workflow_definition`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 39 - 2025-03-18 07:43:15 [0.27ms] */
update `transaction` set `current_workflow_state_id` = 8, `transaction`.`updated_at` = '2025-03-18 07:43:15' where `id` = 510937;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 40 - 2025-03-18 07:43:15 [0.19ms] */
select * from `service` where `service`.`id` = 2 and `service`.`id` is not null and `service`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 41 - 2025-03-18 07:43:15 [0.26ms] */
select * from `invoice` where `invoice`.`id` = 486612 and `invoice`.`id` is not null and `invoice`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 42 - 2025-03-18 07:43:15 [0.26ms] */
select * from `vehicle_tax` where `transaction_id` = 510937 and `vehicle_tax`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 43 - 2025-03-18 07:43:15 [0.19ms] */
update `vehicle_tax` set `status` = 'PAID', `vehicle_tax`.`updated_at` = '2025-03-18 07:43:15' where `id` = 401155;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 44 - 2025-03-18 07:43:15 [0.18ms] */
select * from `vehicle_tax` where `id` = 401155 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 45 - 2025-03-18 07:43:15 [0.2ms] */
insert into `activity_log` (`log_name`, `properties`, `causer_id`, `causer_type`, `subject_id`, `subject_type`, `description`, `updated_at`, `created_at`) values ('vehicle_tax', '{"attributes":{"status":"PAID"},"old":{"status":"INPROGRESS"}}', 153, 'App\Models\User', 401155, 'Modules\Vehicle\Entities\VehicleTax', 'updated', '2025-03-18 07:43:15', '2025-03-18 07:43:15');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 46 - 2025-03-18 07:43:15 [0.23ms] */
select * from `invoice` where `invoice`.`id` = 486716 and `invoice`.`id` is not null and `invoice`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 47 - 2025-03-18 07:43:15 [0.19ms] */
select * from `invoice` where `invoice`.`id` = 486716 and `invoice`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 48 - 2025-03-18 07:43:15 [0.17ms] */
insert into `invoice_payment` (`created_at`, `invoice_id`, `payment_id`, `updated_at`) values ('2025-03-18 07:43:15', 486716, 177677, '2025-03-18 07:43:15');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 49 - 2025-03-18 07:43:15 [0.2ms] */
select * from `invoice` where `invoice`.`id` = 486716 and `invoice`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 50 - 2025-03-18 07:43:15 [0.27ms] */
select `Payment`.*, `invoice_payment`.`invoice_id` as `pivot_invoice_id`, `invoice_payment`.`payment_id` as `pivot_payment_id`, `invoice_payment`.`created_at` as `pivot_created_at`, `invoice_payment`.`updated_at` as `pivot_updated_at` from `Payment` inner join `invoice_payment` on `Payment`.`id` = `invoice_payment`.`payment_id` where `invoice_payment`.`invoice_id` = 486716 and `Payment`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 51 - 2025-03-18 07:43:15 [0.16ms] */
update `invoice` set `outstanding_balance` = 0, `status` = 'PAID', `invoice`.`updated_at` = '2025-03-18 07:43:15' where `id` = 486716;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 52 - 2025-03-18 07:43:15 [0.18ms] */
select * from `invoice` where `id` = 486716 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 53 - 2025-03-18 07:43:15 [0.17ms] */
insert into `activity_log` (`log_name`, `properties`, `causer_id`, `causer_type`, `subject_id`, `subject_type`, `description`, `updated_at`, `created_at`) values ('invoice', '{"attributes":{"outstanding_balance":"0.00","status":"PAID"},"old":{"outstanding_balance":"64.00","status":"OPEN"}}', 153, 'App\Models\User', 486716, 'Modules\Transaction\Entities\Invoice', 'updated', '2025-03-18 07:43:15', '2025-03-18 07:43:15');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 54 - 2025-03-18 07:43:15 [0.22ms] */
select * from `transaction` where `transaction`.`id` = 511044 and `transaction`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 55 - 2025-03-18 07:43:15 [0.21ms] */
select * from `transaction` where `transaction`.`id` = 511044 and `transaction`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 56 - 2025-03-18 07:43:15 [0.14ms] */
select * from `service_workflow` where `service_workflow`.`id` = 2 and `service_workflow`.`id` is not null and `service_workflow`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 57 - 2025-03-18 07:43:15 [0.13ms] */
select * from `service` where `service`.`id` = 2 and `service`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 58 - 2025-03-18 07:43:15 [0.18ms] */
select * from `workflow_definition` where `workflow_definition`.`id` = 7 and `workflow_definition`.`id` is not null and `workflow_definition`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 59 - 2025-03-18 07:43:15 [0.18ms] */
insert into `transaction_workflow` (`transaction_id`, `action`, `action_date`, `role_id`, `user_id`, `comments`, `updated_by`, `created_by`, `created_at`, `updated_at`) values (511044, 'PAID', '2025-03-18 07:43:15', 7, 153, null, 153, 153, '2025-03-18 07:43:15', '2025-03-18 07:43:15');
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 60 - 2025-03-18 07:43:15 [0.2ms] */
select * from `workflow_definition` where `workflow_id` = 2 and `step_number` = 3 and `workflow_definition`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 61 - 2025-03-18 07:43:15 [0.19ms] */
update `transaction` set `current_workflow_state_id` = 8, `transaction`.`updated_at` = '2025-03-18 07:43:15' where `id` = 511044;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 62 - 2025-03-18 07:43:15 [0.13ms] */
select * from `service` where `service`.`id` = 2 and `service`.`id` is not null and `service`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/confirm_payment
   Query 63 - 2025-03-18 07:43:15 [0.19ms] */
select * from `invoice` where `invoice`.`id` = 486716 and `invoice`.`id` is not null and `invoice`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payment_confirm_image
   Query 1 - 2025-03-18 07:43:19 [1.99ms] */
select * from `oauth_access_tokens` where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payment_confirm_image
   Query 2 - 2025-03-18 07:43:19 [0.28ms] */
select * from `oauth_access_tokens` where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payment_confirm_image
   Query 3 - 2025-03-18 07:43:19 [0.28ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payment_confirm_image
   Query 4 - 2025-03-18 07:43:19 [0.36ms] */
select * from `users` where `id` = 153 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payment_confirm_image
   Query 5 - 2025-03-18 07:43:19 [0.31ms] */
select * from `oauth_access_tokens` where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payment_confirm_image
   Query 6 - 2025-03-18 07:43:19 [0.29ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payment_confirm_image
   Query 7 - 2025-03-18 07:43:19 [6.25ms] */
delete from `payment_documents` where `transaction_id` = 510937 and `type` = 'SERVICE_RECEIPT_IMAGE';
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/payment_confirm_image
   Query 8 - 2025-03-18 07:43:19 [3.31ms] */
select * from `payment_documents` where `type` = 'SERVICE_RECEIPT_IMAGE' and `receipt_number` = 1110011;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/get_sticker_code
   Query 1 - 2025-03-18 07:44:04 [2.41ms] */
select * from `oauth_access_tokens` where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/get_sticker_code
   Query 2 - 2025-03-18 07:44:04 [0.28ms] */
select * from `oauth_access_tokens` where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/get_sticker_code
   Query 3 - 2025-03-18 07:44:04 [0.27ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/get_sticker_code
   Query 4 - 2025-03-18 07:44:04 [0.32ms] */
select * from `users` where `id` = 153 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/get_sticker_code
   Query 5 - 2025-03-18 07:44:04 [0.27ms] */
select * from `oauth_access_tokens` where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/get_sticker_code
   Query 6 - 2025-03-18 07:44:04 [0.26ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/get_sticker_code
   Query 7 - 2025-03-18 07:44:04 [0.38ms] */
select * from `vehicle_tax` where `id` = 401155 and `vehicle_tax`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/get_sticker_code
   Query 8 - 2025-03-18 07:44:04 [31.66ms] */
select `id`, `name` from `tax_sticker` where `term_id` = 103 and `name` like '%2025-Q1%' and `assigned` = 'NO' and `tax_sticker`.`deleted_at` is null;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/assign_sticker_code
   Query 1 - 2025-03-18 07:44:38 [1.39ms] */
select * from `oauth_access_tokens` where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/assign_sticker_code
   Query 2 - 2025-03-18 07:44:38 [0.14ms] */
select * from `oauth_access_tokens` where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/assign_sticker_code
   Query 3 - 2025-03-18 07:44:38 [0.14ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/assign_sticker_code
   Query 4 - 2025-03-18 07:44:38 [0.17ms] */
select * from `users` where `id` = 153 and `users`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/assign_sticker_code
   Query 5 - 2025-03-18 07:44:38 [0.14ms] */
select * from `oauth_access_tokens` where `id` = 'be95c16fbad4c214d1da628caab9beee6f6cfb675f84418420bf20590cd87ac594989bf64b80a32d' limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/assign_sticker_code
   Query 6 - 2025-03-18 07:44:38 [0.13ms] */
select * from `oauth_clients` where `id` = 5 limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/assign_sticker_code
   Query 7 - 2025-03-18 07:44:38 [0.32ms] */
select * from `tax_sticker` where `tax_sticker`.`id` = 636305 and `tax_sticker`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/assign_sticker_code
   Query 8 - 2025-03-18 07:44:38 [0.16ms] */
select * from `vehicle_tax` where `id` = 401155 and `vehicle_tax`.`deleted_at` is null limit 1;
/*==================================================*/
/* Origin (request): POST https://testtra.puntlandgov.org/api/assign_sticker_code
   Query 9 - 2025-03-18 07:44:38 [7.29ms] */
