Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pengguna Aplikasi PBB (poin 9) - Halaman OpenSID #369

Merged
merged 9 commits into from
Aug 8, 2024
Merged

Conversation

pandigresik
Copy link
Contributor

@pandigresik pandigresik commented Jul 31, 2024

Perbaikan issue :

  1. Pengguna Aplikasi PBB (poin 9) - Halaman OpenSID #340
  2. Pengguna Anjungan Mandiri (poin 10) - Halaman OpenSID #341

Perbaikan pada OpenSID https://github.com/OpenSID/premium/pull/3973
Perbaikan pada PBB https://github.com/OpenSID/pbb_desa/pull/228

Perlu penyesuaian pada aplikasi PBB, agar aplikasi PBB kirim data ke pantau
Ada penambahan tabel, lakukan php artisan migrate terlebih dahulu

trackpbb.php
`<?php

$curl = curl_init();
$serverPantau = 'http://localhost:8000';
curl_setopt_array($curl, array(
CURLOPT_URL => $serverPantau.'/api/track/pbb?token=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpZCI6bnVsbCwidGltZXN0YW1wIjoxNjAzNDY2MjM5fQ.HVCNnMLokF2tgHwjQhSIYo6-2GNXB4-Kf28FSIeXnZw',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => '',
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 0,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => 'POST',
CURLOPT_POSTFIELDS =>'{
"nama_desa": "Damarwulan",
"kode_desa": "35.06.18.2010",
"kode_pos": "83355",
"nama_kecamatan": "Kepung",
"kode_kecamatan": "35.06.18",
"nama_kabupaten": "Kediri",
"kode_kabupaten": "35.06",
"nama_provinsi": "Jawa Timur",
"kode_provinsi": "35",
"url": "https://pbb.damarwulan.com/",
"versi": "2405.0.0"
}',
CURLOPT_HTTPHEADER => array(
'Accept: application/json',
'Authorization: Bearer {{token}}',
'Content-Type: application/json'
),
));

$response = curl_exec($curl);

curl_close($curl);
echo $response;`

Screencast.from.31-07-24.15.47.18.webm
Screencast.from.01-08-24.07.24.18.webm

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants