feat: airing proof theme statistic
feat: content recap statistic feat: cooperation completion feat: user statistic feat: website visitor statistic
This commit is contained in:
parent
dfa787853e
commit
ae9d8cd908
@ -3,10 +3,15 @@
|
||||
namespace App\Http\Controllers\Dashboard;
|
||||
|
||||
use App\Http\Controllers\Controller;
|
||||
use App\Models\ContentRecap;
|
||||
use App\Models\CooperationCompletion;
|
||||
use App\Models\IssueManagement;
|
||||
use App\Models\LoginHistory;
|
||||
use App\Models\MediaCooperation;
|
||||
use App\Models\MediaMonitoring;
|
||||
use App\Models\Report;
|
||||
use App\Models\User;
|
||||
use App\Models\Visitor;
|
||||
use Carbon\Carbon;
|
||||
use Illuminate\Http\Request;
|
||||
use Illuminate\Support\Facades\DB;
|
||||
@ -21,26 +26,26 @@ public function index(Request $request){
|
||||
'category' => 'login-activities',
|
||||
'is_available' => true
|
||||
],
|
||||
[
|
||||
'name' => 'Jurnalis',
|
||||
'category' => 'journalists',
|
||||
'is_available' => false
|
||||
],
|
||||
// [
|
||||
// 'name' => 'Jurnalis',
|
||||
// 'category' => 'journalists',
|
||||
// 'is_available' => false
|
||||
// ],
|
||||
[
|
||||
'name' => 'Kerja Sama Media',
|
||||
'category' => 'media-cooperations',
|
||||
'is_available' => false
|
||||
'is_available' => true
|
||||
],
|
||||
[
|
||||
'name' => 'Laporan Bukti Tayang',
|
||||
'category' => 'airing-proof-reports',
|
||||
'is_available' => true
|
||||
],
|
||||
[
|
||||
'name' => 'Media',
|
||||
'category' => 'media',
|
||||
'is_available' => false
|
||||
],
|
||||
// [
|
||||
// 'name' => 'Media',
|
||||
// 'category' => 'media',
|
||||
// 'is_available' => false
|
||||
// ],
|
||||
[
|
||||
'name' => 'Monitoring Media & Manajemen Isu',
|
||||
'category' => 'media-monitorings-issue-management',
|
||||
@ -49,27 +54,27 @@ public function index(Request $request){
|
||||
[
|
||||
'name' => 'Penyelesaian Kerja Sama',
|
||||
'category' => 'cooperation-completions',
|
||||
'is_available' => false
|
||||
'is_available' => true
|
||||
],
|
||||
[
|
||||
'name' => 'Pengguna',
|
||||
'category' => 'users',
|
||||
'is_available' => false
|
||||
],
|
||||
[
|
||||
'name' => 'Perusahaan',
|
||||
'category' => 'companies',
|
||||
'is_available' => false
|
||||
'is_available' => true
|
||||
],
|
||||
// [
|
||||
// 'name' => 'Perusahaan',
|
||||
// 'category' => 'companies',
|
||||
// 'is_available' => false
|
||||
// ],
|
||||
[
|
||||
'name' => 'Rekap Konten',
|
||||
'category' => 'content-recaps',
|
||||
'is_available' => false
|
||||
'is_available' => true
|
||||
],
|
||||
[
|
||||
'name' => 'Pengunjung Website',
|
||||
'category' => 'website-visitors',
|
||||
'is_available' => false
|
||||
'is_available' => true
|
||||
],
|
||||
];
|
||||
|
||||
@ -91,13 +96,8 @@ public function show(Request $request, $category){
|
||||
|
||||
$upComings = [
|
||||
'journalists',
|
||||
'media-cooperations',
|
||||
'media',
|
||||
'cooperation-completions',
|
||||
'users',
|
||||
'companies',
|
||||
'content-recaps',
|
||||
'website-visitors',
|
||||
];
|
||||
|
||||
if(in_array($category, $upComings)){
|
||||
@ -109,6 +109,22 @@ public function show(Request $request, $category){
|
||||
$to_month = $request->input('to_month', null);
|
||||
|
||||
switch($category){
|
||||
case 'login-activities':
|
||||
$data['title'] = 'Statistik Aktivitas Login';
|
||||
|
||||
$monthlyCount = array_fill(0, 12, 0);
|
||||
|
||||
$loginActivities = LoginHistory::with(['user'])->get();
|
||||
$loginActivities->groupBy(function ($item) {
|
||||
return (int) \Carbon\Carbon::parse($item->created_at)->format('m');
|
||||
})->each(function ($items, $month) use (&$monthlyCount) {
|
||||
// Simpan jumlah item tiap bulan ke index bulan - 1 (0-based)
|
||||
$monthlyCount[$month - 1] = $items->count();
|
||||
});
|
||||
|
||||
$data['loginActivities'] = $monthlyCount;
|
||||
|
||||
return view('dashboard.statistics.show.login-activity', $data);
|
||||
case 'media-monitorings-issue-management':
|
||||
$data['title'] = 'Statistik Monitoring Media & Manajemen Isu';
|
||||
|
||||
@ -207,7 +223,7 @@ public function show(Request $request, $category){
|
||||
$data['title'] = 'Statistik Laporan Bukti Tayang';
|
||||
|
||||
$airingProofReport = Report::with(['order', 'media'])->get();
|
||||
$airingProofThemeCount = $airingProofReport->groupBy('status')->map(function ($group) {
|
||||
$airingProofReportCount = $airingProofReport->groupBy('status')->map(function ($group) {
|
||||
return $group->count();
|
||||
});
|
||||
|
||||
@ -249,28 +265,179 @@ public function show(Request $request, $category){
|
||||
$data['airingProofReportStatusMonthly'] = $monthlyStatus;
|
||||
$data['airingProofReportPublicationMonthly'] = $monthlyCount;
|
||||
|
||||
$data['proofAiringThemeWaiting'] = $airingProofThemeCount->get('0', 0);
|
||||
$data['proofAiringThemeAccepted'] = $airingProofThemeCount->get('1', 0);
|
||||
$data['proofAiringThemeRejected'] = $airingProofThemeCount->get('2', 0);
|
||||
$data['airingProofReportWaiting'] = $airingProofReportCount->get('0', 0);
|
||||
$data['airingProofReportAccepted'] = $airingProofReportCount->get('1', 0);
|
||||
$data['airingProofReportRejected'] = $airingProofReportCount->get('2', 0);
|
||||
|
||||
return view('dashboard.statistics.show.airing-proof-report', $data);
|
||||
case 'login-activities':
|
||||
$data['title'] = 'Statistik Aktivitas Login';
|
||||
case 'users':
|
||||
$data['title'] = 'Statistik Pengguna';
|
||||
|
||||
$monthlyCount = array_fill(0, 12, 0);
|
||||
|
||||
$loginActivities = LoginHistory::with(['user'])->get();
|
||||
$loginActivities->groupBy(function ($item) {
|
||||
$registerUsers = User::all();
|
||||
$registerUsers->groupBy(function ($item) {
|
||||
return (int) \Carbon\Carbon::parse($item->created_at)->format('m');
|
||||
})->each(function ($items, $month) use (&$monthlyCount) {
|
||||
$monthlyCount[$month - 1] = $items->count();
|
||||
});
|
||||
|
||||
$data['registerUserMonth'] = $monthlyCount;
|
||||
|
||||
return view('dashboard.statistics.show.user', $data);
|
||||
case 'website-visitors':
|
||||
$data['title'] = 'Statistik Pengunjung Website';
|
||||
|
||||
$monthlyCount = array_fill(0, 12, 0);
|
||||
|
||||
$websiteVisitors = Visitor::all();
|
||||
$websiteVisitors->groupBy(function ($item) {
|
||||
return (int) \Carbon\Carbon::parse($item->created_at)->format('m');
|
||||
})->each(function ($items, $month) use (&$monthlyCount) {
|
||||
$monthlyCount[$month - 1] = $items->count();
|
||||
});
|
||||
|
||||
$data['websiteVisitorMonth'] = $monthlyCount;
|
||||
|
||||
return view('dashboard.statistics.show.website-visitor', $data);
|
||||
case 'cooperation-completions':
|
||||
$data['title'] = 'Statistik Laporan Bukti Tayang';
|
||||
|
||||
$cooperationCompletion = CooperationCompletion::with(['order', 'media'])->get();
|
||||
$cooperationCompletionCount = $cooperationCompletion->groupBy('status')->map(function ($group) {
|
||||
return $group->count();
|
||||
});
|
||||
|
||||
// Inisialisasi array 12 bulan untuk masing-masing status
|
||||
$monthlyStatus = [
|
||||
'waiting' => array_fill(0, 12, 0),
|
||||
'accepted' => array_fill(0, 12, 0),
|
||||
'rejected' => array_fill(0, 12, 0),
|
||||
];
|
||||
|
||||
// Kelompokkan data berdasarkan status lalu bulan
|
||||
$cooperationCompletion->groupBy('status')->each(function ($groupedByStatus, $status) use (&$monthlyStatus) {
|
||||
$label = match ((int)$status) {
|
||||
0 => 'waiting',
|
||||
1 => 'accepted',
|
||||
2 => 'rejected',
|
||||
default => null,
|
||||
};
|
||||
|
||||
if ($label) {
|
||||
$groupedByStatus->groupBy(function ($item) {
|
||||
return (int)$item->created_at->format('m'); // bulan sebagai angka 1–12
|
||||
})->each(function ($items, $month) use (&$monthlyStatus, $label) {
|
||||
$monthlyStatus[$label][$month - 1] = $items->count();
|
||||
});
|
||||
}
|
||||
});
|
||||
|
||||
$monthlyCount = array_fill(0, 12, 0);
|
||||
|
||||
$cooperationCompletion->groupBy(function ($item) {
|
||||
return (int) \Carbon\Carbon::parse($item->created_at)->format('m');
|
||||
})->each(function ($items, $month) use (&$monthlyCount) {
|
||||
// Simpan jumlah item tiap bulan ke index bulan - 1 (0-based)
|
||||
$monthlyCount[$month - 1] = $items->count();
|
||||
});
|
||||
|
||||
$data['loginActivities'] = $monthlyCount;
|
||||
// Simpan ke variabel `$data`
|
||||
$data['cooperationCompletionStatusMonthly'] = $monthlyStatus;
|
||||
$data['cooperationCompletionMonthly'] = $monthlyCount;
|
||||
|
||||
return view('dashboard.statistics.show.login-activity', $data);
|
||||
$data['cooperationCompletionWaiting'] = $cooperationCompletionCount->get('0', 0);
|
||||
$data['cooperationCompletionAccepted'] = $cooperationCompletionCount->get('1', 0);
|
||||
$data['cooperationCompletionRejected'] = $cooperationCompletionCount->get('2', 0);
|
||||
|
||||
return view('dashboard.statistics.show.cooperation-completion', $data);
|
||||
case 'media-cooperations':
|
||||
$data['title'] = 'Statistik Laporan Bukti Tayang';
|
||||
|
||||
$mediaCooperation = MediaCooperation::with(['cooperation', 'media'])->get();
|
||||
$mediaCooperationCount = $mediaCooperation->groupBy('status')->map(function ($group) {
|
||||
return $group->count();
|
||||
});
|
||||
|
||||
// Inisialisasi array 12 bulan untuk masing-masing status
|
||||
$monthlyStatus = [
|
||||
'waiting' => array_fill(0, 12, 0),
|
||||
'accepted' => array_fill(0, 12, 0),
|
||||
'rejected' => array_fill(0, 12, 0),
|
||||
];
|
||||
|
||||
// Kelompokkan data berdasarkan status lalu bulan
|
||||
$mediaCooperation->groupBy('status')->each(function ($groupedByStatus, $status) use (&$monthlyStatus) {
|
||||
$label = match ((int)$status) {
|
||||
0 => 'waiting',
|
||||
1 => 'accepted',
|
||||
2 => 'rejected',
|
||||
default => null,
|
||||
};
|
||||
|
||||
if ($label) {
|
||||
$groupedByStatus->groupBy(function ($item) {
|
||||
return (int)$item->created_at->format('m'); // bulan sebagai angka 1–12
|
||||
})->each(function ($items, $month) use (&$monthlyStatus, $label) {
|
||||
$monthlyStatus[$label][$month - 1] = $items->count();
|
||||
});
|
||||
}
|
||||
});
|
||||
|
||||
$monthlyCount = array_fill(0, 12, 0);
|
||||
|
||||
$mediaCooperation->groupBy(function ($item) {
|
||||
return (int) \Carbon\Carbon::parse($item->created_at)->format('m');
|
||||
})->each(function ($items, $month) use (&$monthlyCount) {
|
||||
// Simpan jumlah item tiap bulan ke index bulan - 1 (0-based)
|
||||
$monthlyCount[$month - 1] = $items->count();
|
||||
});
|
||||
|
||||
// Simpan ke variabel `$data`
|
||||
$data['mediaCooperationStatusMonthly'] = $monthlyStatus;
|
||||
$data['mediaCooperationMonthly'] = $monthlyCount;
|
||||
|
||||
$data['mediaCooperationWaiting'] = $mediaCooperationCount->get('0', 0);
|
||||
$data['mediaCooperationAccepted'] = $mediaCooperationCount->get('1', 0);
|
||||
$data['mediaCooperationRejected'] = $mediaCooperationCount->get('2', 0);
|
||||
|
||||
return view('dashboard.statistics.show.media-cooperation', $data);
|
||||
case 'content-recaps':
|
||||
$data['title'] = 'Statistik Rekap Konten';
|
||||
|
||||
$contenteRecap = ContentRecap::with(['enhancer', 'classification'])->get();
|
||||
$contentRecapChannelCount = $contenteRecap->groupBy('channel')->map(function ($group) {
|
||||
return $group->count();
|
||||
});
|
||||
|
||||
$contentRecapSocialMediaCount = $contenteRecap->groupBy('social_media')->map(function ($group) {
|
||||
return $group->count();
|
||||
});
|
||||
|
||||
$monthlyCount = array_fill(0, 12, 0);
|
||||
|
||||
$contenteRecap->groupBy(function ($item) {
|
||||
return (int) \Carbon\Carbon::parse($item->created_at)->format('m');
|
||||
})->each(function ($items, $month) use (&$monthlyCount) {
|
||||
// Simpan jumlah item tiap bulan ke index bulan - 1 (0-based)
|
||||
$monthlyCount[$month - 1] = $items->count();
|
||||
});
|
||||
|
||||
$data['contentRecapMonthly'] = $monthlyCount;
|
||||
|
||||
$data['facebookContentRecap'] = $contentRecapChannelCount->get('facebook', 0);
|
||||
$data['twitterContentRecap'] = $contentRecapChannelCount->get('twitter', 0);
|
||||
$data['websiteContentRecap'] = $contentRecapChannelCount->get('website', 0);
|
||||
$data['youtubeContentRecap'] = $contentRecapChannelCount->get('youtube', 0);
|
||||
$data['instagramContentRecap'] = $contentRecapChannelCount->get('instagram', 0);
|
||||
$data['tiktokContentRecap'] = $contentRecapChannelCount->get('tiktok', 0);
|
||||
$data['cetakContentRecap'] = $contentRecapChannelCount->get('cetak', 0);
|
||||
|
||||
$data['socialMedia1ContentRecap'] = $contentRecapSocialMediaCount->get('Diskominfo Purwakarta', 0);
|
||||
$data['socialMedia2ContentRecap'] = $contentRecapSocialMediaCount->get('PPID Diskominfo Purwakarta', 0);
|
||||
$data['socialMedia3ContentRecap'] = $contentRecapSocialMediaCount->get('Purwakarta Saber Hoaks', 0);
|
||||
|
||||
return view('dashboard.statistics.show.content-recap', $data);
|
||||
default:
|
||||
abort(404);
|
||||
}
|
||||
|
||||
@ -5,14 +5,14 @@
|
||||
"use strict";
|
||||
|
||||
@if(is_role(['1']))
|
||||
var proofAiringThemeStatus = {
|
||||
var airingProofReportStatus = {
|
||||
labels: ["Menunggu", "Diterima", "Ditolak"],
|
||||
dataUnit: 'Data',
|
||||
legend: false,
|
||||
datasets: [{
|
||||
borderColor: "#fff",
|
||||
background: ["#FFCC00", "#0065F8", "#CB0404"],
|
||||
data: ["{{$proofAiringThemeWaiting}}", "{{$proofAiringThemeAccepted}}", "{{$proofAiringThemeRejected}}"]
|
||||
data: ["{{$airingProofReportWaiting}}", "{{$airingProofReportAccepted}}", "{{$airingProofReportRejected}}"]
|
||||
}]
|
||||
};
|
||||
|
||||
@ -169,7 +169,7 @@ function ecommerceDoughnutS1(selector, set_data) {
|
||||
}
|
||||
};
|
||||
|
||||
const statusChart = new ApexCharts(document.querySelector("#airingProofThemeColumn"), statusOptions);
|
||||
const statusChart = new ApexCharts(document.querySelector("#airingProofReportColumn"), statusOptions);
|
||||
statusChart.render();
|
||||
</script>
|
||||
<script>
|
||||
@ -254,6 +254,6 @@ function ecommerceDoughnutS1(selector, set_data) {
|
||||
}
|
||||
};
|
||||
|
||||
var publicationChart = new ApexCharts(document.querySelector("#airingProofThemePublicationColumn"), publicationOptions);
|
||||
var publicationChart = new ApexCharts(document.querySelector("#airingProofReportPublicationColumn"), publicationOptions);
|
||||
publicationChart.render();
|
||||
</script>
|
||||
|
||||
@ -0,0 +1,200 @@
|
||||
<script>
|
||||
"use strict";
|
||||
|
||||
!function (NioApp, $) {
|
||||
"use strict";
|
||||
|
||||
@if(is_role(['1']))
|
||||
var contentRecapChannel = {
|
||||
labels: ["Facebook", "Twitter", "Website", "YouTube", "Intagram", "TikTok", "Cetak"],
|
||||
dataUnit: 'Data',
|
||||
legend: false,
|
||||
datasets: [{
|
||||
borderColor: "#fff",
|
||||
background: ["#1877F2", "#1DA1F2", "#28A745", "#FF0000", "#E4405F", "#00F2EA", "#333333"],
|
||||
data: ["{{ $facebookContentRecap }}", "{{ $twitterContentRecap }}", "{{ $websiteContentRecap }}", "{{ $youtubeContentRecap }}", "{{ $instagramContentRecap }}", "{{ $tiktokContentRecap }}", "{{ $cetakContentRecap }}"]
|
||||
}]
|
||||
};
|
||||
|
||||
var contentRecapSocialMedia = {
|
||||
labels: ["Diskominfo Purwakarta", "PPID Diskominfo Purwakarta", "Purwakarta Saber Hoaks"],
|
||||
dataUnit: 'Data',
|
||||
legend: false,
|
||||
datasets: [{
|
||||
borderColor: "#fff",
|
||||
background: ["#00ADB5", "#EAA64D", "#578FCA"],
|
||||
data: ["{{ $socialMedia1ContentRecap }}", "{{ $socialMedia2ContentRecap }}", "{{ $socialMedia3ContentRecap }}"]
|
||||
}]
|
||||
};
|
||||
|
||||
@elseif(is_role(['5']))
|
||||
var mediaCooperationsStatistics = {
|
||||
labels: ["Menunggu", "Diterima", "Ditolak"],
|
||||
dataUnit: 'Data',
|
||||
legend: false,
|
||||
datasets: [{
|
||||
borderColor: "#fff",
|
||||
background: ["#FFB200", "#5CB338", "#E50046"],
|
||||
data: ["{{$mediaCooperationWaiting}}", "{{$mediaCooperationAccepted}}", "{{$mediaCooperationRejected}}"]
|
||||
}]
|
||||
};
|
||||
@endif
|
||||
|
||||
function ecommerceDoughnutS1(selector, set_data) {
|
||||
var $selector = selector ? $(selector) : $('.ecommerce-doughnut-s1');
|
||||
$selector.each(function () {
|
||||
var $self = $(this),
|
||||
_self_id = $self.attr('id'),
|
||||
_get_data = typeof set_data === 'undefined' ? eval(_self_id) : set_data;
|
||||
|
||||
var selectCanvas = document.getElementById(_self_id).getContext("2d");
|
||||
var chart_data = [];
|
||||
|
||||
for (var i = 0; i < _get_data.datasets.length; i++) {
|
||||
chart_data.push({
|
||||
backgroundColor: _get_data.datasets[i].background,
|
||||
borderWidth: 2,
|
||||
borderColor: _get_data.datasets[i].borderColor,
|
||||
hoverBorderColor: _get_data.datasets[i].borderColor,
|
||||
data: _get_data.datasets[i].data
|
||||
});
|
||||
}
|
||||
|
||||
var chart = new Chart(selectCanvas, {
|
||||
type: 'doughnut',
|
||||
data: {
|
||||
labels: _get_data.labels,
|
||||
datasets: chart_data
|
||||
},
|
||||
options: {
|
||||
legend: {
|
||||
display: _get_data.legend ? _get_data.legend : false,
|
||||
rtl: NioApp.State.isRTL,
|
||||
labels: {
|
||||
boxWidth: 12,
|
||||
padding: 20,
|
||||
fontColor: '#6783b8'
|
||||
}
|
||||
},
|
||||
rotation: -1.5,
|
||||
cutoutPercentage: 70,
|
||||
maintainAspectRatio: false,
|
||||
tooltips: {
|
||||
enabled: true,
|
||||
rtl: NioApp.State.isRTL,
|
||||
callbacks: {
|
||||
title: function title(tooltipItem, data) {
|
||||
return data['labels'][tooltipItem[0]['index']];
|
||||
},
|
||||
label: function label(tooltipItem, data) {
|
||||
return data.datasets[tooltipItem.datasetIndex]['data'][tooltipItem['index']] + ' ' + _get_data.dataUnit;
|
||||
}
|
||||
},
|
||||
backgroundColor: '#1c2b46',
|
||||
titleFontSize: 13,
|
||||
titleFontColor: '#fff',
|
||||
titleMarginBottom: 6,
|
||||
bodyFontColor: '#fff',
|
||||
bodyFontSize: 12,
|
||||
bodySpacing: 4,
|
||||
yPadding: 10,
|
||||
xPadding: 10,
|
||||
footerMarginTop: 0,
|
||||
displayColors: false
|
||||
}
|
||||
}
|
||||
});
|
||||
});
|
||||
} // init chart
|
||||
|
||||
|
||||
NioApp.coms.docReady.push(function () {
|
||||
ecommerceDoughnutS1();
|
||||
});
|
||||
}(NioApp, jQuery);
|
||||
</script>
|
||||
<script>
|
||||
const monthlyTotalData = @json($contentRecapMonthly);
|
||||
var createdOptions = {
|
||||
series: [{
|
||||
name: 'Penyelesaian Kerja Sama',
|
||||
data: monthlyTotalData
|
||||
}],
|
||||
chart: {
|
||||
height: 350,
|
||||
type: 'bar',
|
||||
},
|
||||
plotOptions: {
|
||||
bar: {
|
||||
borderRadius: 3,
|
||||
dataLabels: {
|
||||
position: 'center', // top, center, bottom
|
||||
},
|
||||
}
|
||||
},
|
||||
dataLabels: {
|
||||
enabled: true,
|
||||
formatter: function (val) {
|
||||
return val + " data";
|
||||
},
|
||||
offsetY: -20,
|
||||
style: {
|
||||
fontSize: '12px',
|
||||
colors: ["#304758"]
|
||||
}
|
||||
},
|
||||
|
||||
xaxis: {
|
||||
categories: ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"],
|
||||
position: 'top',
|
||||
axisBorder: {
|
||||
show: false
|
||||
},
|
||||
axisTicks: {
|
||||
show: false
|
||||
},
|
||||
crosshairs: {
|
||||
fill: {
|
||||
type: 'gradient',
|
||||
gradient: {
|
||||
colorFrom: '#3572EF',
|
||||
colorTo: '#3ABEF9',
|
||||
stops: [0, 100],
|
||||
opacityFrom: 0.4,
|
||||
opacityTo: 0.5,
|
||||
}
|
||||
}
|
||||
},
|
||||
tooltip: {
|
||||
enabled: true,
|
||||
}
|
||||
},
|
||||
yaxis: {
|
||||
axisBorder: {
|
||||
show: false
|
||||
},
|
||||
axisTicks: {
|
||||
show: false,
|
||||
},
|
||||
labels: {
|
||||
show: false,
|
||||
formatter: function (val) {
|
||||
return val + " data";
|
||||
}
|
||||
}
|
||||
|
||||
},
|
||||
title: {
|
||||
text: 'Total Penyelesaian Kerja Sama',
|
||||
floating: true,
|
||||
offsetY: 330,
|
||||
align: 'center',
|
||||
style: {
|
||||
color: '#444'
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
var publicationChart = new ApexCharts(document.querySelector("#contentRecapMonthly"), createdOptions);
|
||||
publicationChart.render();
|
||||
</script>
|
||||
@ -0,0 +1,259 @@
|
||||
<script>
|
||||
"use strict";
|
||||
|
||||
!function (NioApp, $) {
|
||||
"use strict";
|
||||
|
||||
@if(is_role(['1']))
|
||||
var cooperationCompletionStatus = {
|
||||
labels: ["Menunggu", "Diterima", "Ditolak"],
|
||||
dataUnit: 'Data',
|
||||
legend: false,
|
||||
datasets: [{
|
||||
borderColor: "#fff",
|
||||
background: ["#FFCC00", "#0065F8", "#CB0404"],
|
||||
data: ["{{$cooperationCompletionWaiting}}", "{{$cooperationCompletionAccepted}}", "{{$cooperationCompletionRejected}}"]
|
||||
}]
|
||||
};
|
||||
|
||||
@elseif(is_role(['5']))
|
||||
var cooperationCompletionsStatistics = {
|
||||
labels: ["Menunggu", "Diterima", "Ditolak"],
|
||||
dataUnit: 'Data',
|
||||
legend: false,
|
||||
datasets: [{
|
||||
borderColor: "#fff",
|
||||
background: ["#FFB200", "#5CB338", "#E50046"],
|
||||
data: ["{{$cooperationCompletionWaiting}}", "{{$cooperationCompletionAccepted}}", "{{$cooperationCompletionRejected}}"]
|
||||
}]
|
||||
};
|
||||
@endif
|
||||
|
||||
function ecommerceDoughnutS1(selector, set_data) {
|
||||
var $selector = selector ? $(selector) : $('.ecommerce-doughnut-s1');
|
||||
$selector.each(function () {
|
||||
var $self = $(this),
|
||||
_self_id = $self.attr('id'),
|
||||
_get_data = typeof set_data === 'undefined' ? eval(_self_id) : set_data;
|
||||
|
||||
var selectCanvas = document.getElementById(_self_id).getContext("2d");
|
||||
var chart_data = [];
|
||||
|
||||
for (var i = 0; i < _get_data.datasets.length; i++) {
|
||||
chart_data.push({
|
||||
backgroundColor: _get_data.datasets[i].background,
|
||||
borderWidth: 2,
|
||||
borderColor: _get_data.datasets[i].borderColor,
|
||||
hoverBorderColor: _get_data.datasets[i].borderColor,
|
||||
data: _get_data.datasets[i].data
|
||||
});
|
||||
}
|
||||
|
||||
var chart = new Chart(selectCanvas, {
|
||||
type: 'doughnut',
|
||||
data: {
|
||||
labels: _get_data.labels,
|
||||
datasets: chart_data
|
||||
},
|
||||
options: {
|
||||
legend: {
|
||||
display: _get_data.legend ? _get_data.legend : false,
|
||||
rtl: NioApp.State.isRTL,
|
||||
labels: {
|
||||
boxWidth: 12,
|
||||
padding: 20,
|
||||
fontColor: '#6783b8'
|
||||
}
|
||||
},
|
||||
rotation: -1.5,
|
||||
cutoutPercentage: 70,
|
||||
maintainAspectRatio: false,
|
||||
tooltips: {
|
||||
enabled: true,
|
||||
rtl: NioApp.State.isRTL,
|
||||
callbacks: {
|
||||
title: function title(tooltipItem, data) {
|
||||
return data['labels'][tooltipItem[0]['index']];
|
||||
},
|
||||
label: function label(tooltipItem, data) {
|
||||
return data.datasets[tooltipItem.datasetIndex]['data'][tooltipItem['index']] + ' ' + _get_data.dataUnit;
|
||||
}
|
||||
},
|
||||
backgroundColor: '#1c2b46',
|
||||
titleFontSize: 13,
|
||||
titleFontColor: '#fff',
|
||||
titleMarginBottom: 6,
|
||||
bodyFontColor: '#fff',
|
||||
bodyFontSize: 12,
|
||||
bodySpacing: 4,
|
||||
yPadding: 10,
|
||||
xPadding: 10,
|
||||
footerMarginTop: 0,
|
||||
displayColors: false
|
||||
}
|
||||
}
|
||||
});
|
||||
});
|
||||
} // init chart
|
||||
|
||||
|
||||
NioApp.coms.docReady.push(function () {
|
||||
ecommerceDoughnutS1();
|
||||
});
|
||||
}(NioApp, jQuery);
|
||||
</script>
|
||||
<script>
|
||||
const monthlyStatusData = @json($cooperationCompletionStatusMonthly);
|
||||
|
||||
const statusOptions = {
|
||||
series: [
|
||||
{
|
||||
name: 'Menunggu',
|
||||
data: monthlyStatusData.waiting
|
||||
},
|
||||
{
|
||||
name: 'Diterima',
|
||||
data: monthlyStatusData.accepted
|
||||
},
|
||||
{
|
||||
name: 'Ditolak',
|
||||
data: monthlyStatusData.rejected
|
||||
}
|
||||
],
|
||||
colors: ['#FFA500', '#28a745', '#dc3545'],
|
||||
chart: {
|
||||
type: 'bar',
|
||||
height: 350
|
||||
},
|
||||
plotOptions: {
|
||||
bar: {
|
||||
horizontal: false,
|
||||
columnWidth: '55%',
|
||||
borderRadius: 1,
|
||||
borderRadiusApplication: 'end'
|
||||
},
|
||||
},
|
||||
dataLabels: {
|
||||
enabled: false
|
||||
},
|
||||
stroke: {
|
||||
show: true,
|
||||
width: 1,
|
||||
colors: ['transparent']
|
||||
},
|
||||
xaxis: {
|
||||
categories: ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec'],
|
||||
labels: {
|
||||
show: true,
|
||||
rotate: -45,
|
||||
style: {
|
||||
fontSize: '12px',
|
||||
fontFamily: 'Helvetica, Arial, sans-serif',
|
||||
}
|
||||
}
|
||||
},
|
||||
yaxis: {
|
||||
title: {
|
||||
text: 'Status Laporan Bukti Tayang'
|
||||
}
|
||||
},
|
||||
fill: {
|
||||
opacity: 1
|
||||
},
|
||||
tooltip: {
|
||||
y: {
|
||||
formatter: function (val) {
|
||||
return val + " laporan bukti tayang"
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
const statusChart = new ApexCharts(document.querySelector("#cooperationCompletionStatusColumn"), statusOptions);
|
||||
statusChart.render();
|
||||
</script>
|
||||
<script>
|
||||
const monthlyTotalData = @json($cooperationCompletionMonthly);
|
||||
var createdOptions = {
|
||||
series: [{
|
||||
name: 'Penyelesaian Kerja Sama',
|
||||
data: monthlyTotalData
|
||||
}],
|
||||
chart: {
|
||||
height: 350,
|
||||
type: 'bar',
|
||||
},
|
||||
plotOptions: {
|
||||
bar: {
|
||||
borderRadius: 3,
|
||||
dataLabels: {
|
||||
position: 'center', // top, center, bottom
|
||||
},
|
||||
}
|
||||
},
|
||||
dataLabels: {
|
||||
enabled: true,
|
||||
formatter: function (val) {
|
||||
return val + " data";
|
||||
},
|
||||
offsetY: -20,
|
||||
style: {
|
||||
fontSize: '12px',
|
||||
colors: ["#304758"]
|
||||
}
|
||||
},
|
||||
|
||||
xaxis: {
|
||||
categories: ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"],
|
||||
position: 'top',
|
||||
axisBorder: {
|
||||
show: false
|
||||
},
|
||||
axisTicks: {
|
||||
show: false
|
||||
},
|
||||
crosshairs: {
|
||||
fill: {
|
||||
type: 'gradient',
|
||||
gradient: {
|
||||
colorFrom: '#3572EF',
|
||||
colorTo: '#3ABEF9',
|
||||
stops: [0, 100],
|
||||
opacityFrom: 0.4,
|
||||
opacityTo: 0.5,
|
||||
}
|
||||
}
|
||||
},
|
||||
tooltip: {
|
||||
enabled: true,
|
||||
}
|
||||
},
|
||||
yaxis: {
|
||||
axisBorder: {
|
||||
show: false
|
||||
},
|
||||
axisTicks: {
|
||||
show: false,
|
||||
},
|
||||
labels: {
|
||||
show: false,
|
||||
formatter: function (val) {
|
||||
return val + " data";
|
||||
}
|
||||
}
|
||||
|
||||
},
|
||||
title: {
|
||||
text: 'Total Penyelesaian Kerja Sama',
|
||||
floating: true,
|
||||
offsetY: 330,
|
||||
align: 'center',
|
||||
style: {
|
||||
color: '#444'
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
var publicationChart = new ApexCharts(document.querySelector("#cooperationCompletionCreatedMonthlyColumn"), createdOptions);
|
||||
publicationChart.render();
|
||||
</script>
|
||||
@ -0,0 +1,259 @@
|
||||
<script>
|
||||
"use strict";
|
||||
|
||||
!function (NioApp, $) {
|
||||
"use strict";
|
||||
|
||||
@if(is_role(['1']))
|
||||
var mediaCooperationStatus = {
|
||||
labels: ["Menunggu", "Diterima", "Ditolak"],
|
||||
dataUnit: 'Data',
|
||||
legend: false,
|
||||
datasets: [{
|
||||
borderColor: "#fff",
|
||||
background: ["#FFCC00", "#0065F8", "#CB0404"],
|
||||
data: ["{{$mediaCooperationWaiting}}", "{{$mediaCooperationAccepted}}", "{{$mediaCooperationRejected}}"]
|
||||
}]
|
||||
};
|
||||
|
||||
@elseif(is_role(['5']))
|
||||
var mediaCooperationsStatistics = {
|
||||
labels: ["Menunggu", "Diterima", "Ditolak"],
|
||||
dataUnit: 'Data',
|
||||
legend: false,
|
||||
datasets: [{
|
||||
borderColor: "#fff",
|
||||
background: ["#FFB200", "#5CB338", "#E50046"],
|
||||
data: ["{{$mediaCooperationWaiting}}", "{{$mediaCooperationAccepted}}", "{{$mediaCooperationRejected}}"]
|
||||
}]
|
||||
};
|
||||
@endif
|
||||
|
||||
function ecommerceDoughnutS1(selector, set_data) {
|
||||
var $selector = selector ? $(selector) : $('.ecommerce-doughnut-s1');
|
||||
$selector.each(function () {
|
||||
var $self = $(this),
|
||||
_self_id = $self.attr('id'),
|
||||
_get_data = typeof set_data === 'undefined' ? eval(_self_id) : set_data;
|
||||
|
||||
var selectCanvas = document.getElementById(_self_id).getContext("2d");
|
||||
var chart_data = [];
|
||||
|
||||
for (var i = 0; i < _get_data.datasets.length; i++) {
|
||||
chart_data.push({
|
||||
backgroundColor: _get_data.datasets[i].background,
|
||||
borderWidth: 2,
|
||||
borderColor: _get_data.datasets[i].borderColor,
|
||||
hoverBorderColor: _get_data.datasets[i].borderColor,
|
||||
data: _get_data.datasets[i].data
|
||||
});
|
||||
}
|
||||
|
||||
var chart = new Chart(selectCanvas, {
|
||||
type: 'doughnut',
|
||||
data: {
|
||||
labels: _get_data.labels,
|
||||
datasets: chart_data
|
||||
},
|
||||
options: {
|
||||
legend: {
|
||||
display: _get_data.legend ? _get_data.legend : false,
|
||||
rtl: NioApp.State.isRTL,
|
||||
labels: {
|
||||
boxWidth: 12,
|
||||
padding: 20,
|
||||
fontColor: '#6783b8'
|
||||
}
|
||||
},
|
||||
rotation: -1.5,
|
||||
cutoutPercentage: 70,
|
||||
maintainAspectRatio: false,
|
||||
tooltips: {
|
||||
enabled: true,
|
||||
rtl: NioApp.State.isRTL,
|
||||
callbacks: {
|
||||
title: function title(tooltipItem, data) {
|
||||
return data['labels'][tooltipItem[0]['index']];
|
||||
},
|
||||
label: function label(tooltipItem, data) {
|
||||
return data.datasets[tooltipItem.datasetIndex]['data'][tooltipItem['index']] + ' ' + _get_data.dataUnit;
|
||||
}
|
||||
},
|
||||
backgroundColor: '#1c2b46',
|
||||
titleFontSize: 13,
|
||||
titleFontColor: '#fff',
|
||||
titleMarginBottom: 6,
|
||||
bodyFontColor: '#fff',
|
||||
bodyFontSize: 12,
|
||||
bodySpacing: 4,
|
||||
yPadding: 10,
|
||||
xPadding: 10,
|
||||
footerMarginTop: 0,
|
||||
displayColors: false
|
||||
}
|
||||
}
|
||||
});
|
||||
});
|
||||
} // init chart
|
||||
|
||||
|
||||
NioApp.coms.docReady.push(function () {
|
||||
ecommerceDoughnutS1();
|
||||
});
|
||||
}(NioApp, jQuery);
|
||||
</script>
|
||||
<script>
|
||||
const monthlyStatusData = @json($mediaCooperationStatusMonthly);
|
||||
|
||||
const statusOptions = {
|
||||
series: [
|
||||
{
|
||||
name: 'Menunggu',
|
||||
data: monthlyStatusData.waiting
|
||||
},
|
||||
{
|
||||
name: 'Diterima',
|
||||
data: monthlyStatusData.accepted
|
||||
},
|
||||
{
|
||||
name: 'Ditolak',
|
||||
data: monthlyStatusData.rejected
|
||||
}
|
||||
],
|
||||
colors: ['#FFA500', '#28a745', '#dc3545'],
|
||||
chart: {
|
||||
type: 'bar',
|
||||
height: 350
|
||||
},
|
||||
plotOptions: {
|
||||
bar: {
|
||||
horizontal: false,
|
||||
columnWidth: '55%',
|
||||
borderRadius: 1,
|
||||
borderRadiusApplication: 'end'
|
||||
},
|
||||
},
|
||||
dataLabels: {
|
||||
enabled: false
|
||||
},
|
||||
stroke: {
|
||||
show: true,
|
||||
width: 1,
|
||||
colors: ['transparent']
|
||||
},
|
||||
xaxis: {
|
||||
categories: ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec'],
|
||||
labels: {
|
||||
show: true,
|
||||
rotate: -45,
|
||||
style: {
|
||||
fontSize: '12px',
|
||||
fontFamily: 'Helvetica, Arial, sans-serif',
|
||||
}
|
||||
}
|
||||
},
|
||||
yaxis: {
|
||||
title: {
|
||||
text: 'Status Laporan Bukti Tayang'
|
||||
}
|
||||
},
|
||||
fill: {
|
||||
opacity: 1
|
||||
},
|
||||
tooltip: {
|
||||
y: {
|
||||
formatter: function (val) {
|
||||
return val + " laporan bukti tayang"
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
const statusChart = new ApexCharts(document.querySelector("#mediaCooperationStatusColumn"), statusOptions);
|
||||
statusChart.render();
|
||||
</script>
|
||||
<script>
|
||||
const monthlyTotalData = @json($mediaCooperationMonthly);
|
||||
var createdOptions = {
|
||||
series: [{
|
||||
name: 'Penyelesaian Kerja Sama',
|
||||
data: monthlyTotalData
|
||||
}],
|
||||
chart: {
|
||||
height: 350,
|
||||
type: 'bar',
|
||||
},
|
||||
plotOptions: {
|
||||
bar: {
|
||||
borderRadius: 3,
|
||||
dataLabels: {
|
||||
position: 'center', // top, center, bottom
|
||||
},
|
||||
}
|
||||
},
|
||||
dataLabels: {
|
||||
enabled: true,
|
||||
formatter: function (val) {
|
||||
return val + " data";
|
||||
},
|
||||
offsetY: -20,
|
||||
style: {
|
||||
fontSize: '12px',
|
||||
colors: ["#304758"]
|
||||
}
|
||||
},
|
||||
|
||||
xaxis: {
|
||||
categories: ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"],
|
||||
position: 'top',
|
||||
axisBorder: {
|
||||
show: false
|
||||
},
|
||||
axisTicks: {
|
||||
show: false
|
||||
},
|
||||
crosshairs: {
|
||||
fill: {
|
||||
type: 'gradient',
|
||||
gradient: {
|
||||
colorFrom: '#3572EF',
|
||||
colorTo: '#3ABEF9',
|
||||
stops: [0, 100],
|
||||
opacityFrom: 0.4,
|
||||
opacityTo: 0.5,
|
||||
}
|
||||
}
|
||||
},
|
||||
tooltip: {
|
||||
enabled: true,
|
||||
}
|
||||
},
|
||||
yaxis: {
|
||||
axisBorder: {
|
||||
show: false
|
||||
},
|
||||
axisTicks: {
|
||||
show: false,
|
||||
},
|
||||
labels: {
|
||||
show: false,
|
||||
formatter: function (val) {
|
||||
return val + " data";
|
||||
}
|
||||
}
|
||||
|
||||
},
|
||||
title: {
|
||||
text: 'Total Penyelesaian Kerja Sama',
|
||||
floating: true,
|
||||
offsetY: 330,
|
||||
align: 'center',
|
||||
style: {
|
||||
color: '#444'
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
var publicationChart = new ApexCharts(document.querySelector("#mediaCooperationCreatedMonthlyColumn"), createdOptions);
|
||||
publicationChart.render();
|
||||
</script>
|
||||
85
resources/views/dashboard/statistics/chart/user.blade.php
Normal file
85
resources/views/dashboard/statistics/chart/user.blade.php
Normal file
@ -0,0 +1,85 @@
|
||||
<script>
|
||||
const monthlyTotalData = @json($registerUserMonth);
|
||||
var registerUser = {
|
||||
series: [{
|
||||
name: 'Pendaftaran Akun',
|
||||
data: monthlyTotalData
|
||||
}],
|
||||
chart: {
|
||||
height: 350,
|
||||
type: 'bar',
|
||||
},
|
||||
plotOptions: {
|
||||
bar: {
|
||||
borderRadius: 3,
|
||||
dataLabels: {
|
||||
position: 'center', // top, center, bottom
|
||||
},
|
||||
}
|
||||
},
|
||||
dataLabels: {
|
||||
enabled: true,
|
||||
formatter: function (val) {
|
||||
return val + " Akun";
|
||||
},
|
||||
offsetY: -20,
|
||||
style: {
|
||||
fontSize: '12px',
|
||||
colors: ["#304758"]
|
||||
}
|
||||
},
|
||||
|
||||
xaxis: {
|
||||
categories: ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"],
|
||||
position: 'top',
|
||||
axisBorder: {
|
||||
show: false
|
||||
},
|
||||
axisTicks: {
|
||||
show: false
|
||||
},
|
||||
crosshairs: {
|
||||
fill: {
|
||||
type: 'gradient',
|
||||
gradient: {
|
||||
colorFrom: '#3572EF',
|
||||
colorTo: '#3ABEF9',
|
||||
stops: [0, 100],
|
||||
opacityFrom: 0.4,
|
||||
opacityTo: 0.5,
|
||||
}
|
||||
}
|
||||
},
|
||||
tooltip: {
|
||||
enabled: true,
|
||||
}
|
||||
},
|
||||
yaxis: {
|
||||
axisBorder: {
|
||||
show: false
|
||||
},
|
||||
axisTicks: {
|
||||
show: false,
|
||||
},
|
||||
labels: {
|
||||
show: false,
|
||||
formatter: function (val) {
|
||||
return val + " Akun";
|
||||
}
|
||||
}
|
||||
|
||||
},
|
||||
title: {
|
||||
text: 'Pendaftaran Akun Simedkom',
|
||||
floating: true,
|
||||
offsetY: 330,
|
||||
align: 'center',
|
||||
style: {
|
||||
color: '#444'
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
var publicationChart = new ApexCharts(document.querySelector("#registerUserMonth"), registerUser);
|
||||
publicationChart.render();
|
||||
</script>
|
||||
@ -0,0 +1,85 @@
|
||||
<script>
|
||||
const monthlyTotalData = @json($websiteVisitorMonth);
|
||||
var registerUser = {
|
||||
series: [{
|
||||
name: 'Total Pengunjung',
|
||||
data: monthlyTotalData
|
||||
}],
|
||||
chart: {
|
||||
height: 350,
|
||||
type: 'bar',
|
||||
},
|
||||
plotOptions: {
|
||||
bar: {
|
||||
borderRadius: 3,
|
||||
dataLabels: {
|
||||
position: 'center', // top, center, bottom
|
||||
},
|
||||
}
|
||||
},
|
||||
dataLabels: {
|
||||
enabled: true,
|
||||
formatter: function (val) {
|
||||
return val + " Pengunjung";
|
||||
},
|
||||
offsetY: -20,
|
||||
style: {
|
||||
fontSize: '12px',
|
||||
colors: ["#304758"]
|
||||
}
|
||||
},
|
||||
|
||||
xaxis: {
|
||||
categories: ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"],
|
||||
position: 'top',
|
||||
axisBorder: {
|
||||
show: false
|
||||
},
|
||||
axisTicks: {
|
||||
show: false
|
||||
},
|
||||
crosshairs: {
|
||||
fill: {
|
||||
type: 'gradient',
|
||||
gradient: {
|
||||
colorFrom: '#3572EF',
|
||||
colorTo: '#3ABEF9',
|
||||
stops: [0, 100],
|
||||
opacityFrom: 0.4,
|
||||
opacityTo: 0.5,
|
||||
}
|
||||
}
|
||||
},
|
||||
tooltip: {
|
||||
enabled: true,
|
||||
}
|
||||
},
|
||||
yaxis: {
|
||||
axisBorder: {
|
||||
show: false
|
||||
},
|
||||
axisTicks: {
|
||||
show: false,
|
||||
},
|
||||
labels: {
|
||||
show: false,
|
||||
formatter: function (val) {
|
||||
return val + " Akun";
|
||||
}
|
||||
}
|
||||
|
||||
},
|
||||
title: {
|
||||
text: 'Pengunjung Website Simedkom',
|
||||
floating: true,
|
||||
offsetY: 330,
|
||||
align: 'center',
|
||||
style: {
|
||||
color: '#444'
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
var publicationChart = new ApexCharts(document.querySelector("#websiteVisitorMonth"), registerUser);
|
||||
publicationChart.render();
|
||||
</script>
|
||||
@ -56,25 +56,25 @@
|
||||
</div>
|
||||
</div>
|
||||
<div class="nk-ecwg7-ck">
|
||||
<canvas class="ecommerce-doughnut-s1" id="proofAiringThemeStatus"></canvas>
|
||||
<canvas class="ecommerce-doughnut-s1" id="airingProofReportStatus"></canvas>
|
||||
</div>
|
||||
<ul class="nk-ecwg7-legends">
|
||||
<li>
|
||||
<div class="title">
|
||||
<span class="dot dot-lg sq" data-bg="#FFCC00"></span>
|
||||
<span>Menunggu {{ '('.$proofAiringThemeWaiting.')' }}</span>
|
||||
<span>Menunggu {{ '('.$airingProofReportWaiting.')' }}</span>
|
||||
</div>
|
||||
</li>
|
||||
<li>
|
||||
<div class="title">
|
||||
<span class="dot dot-lg sq" data-bg="#0065F8"></span>
|
||||
<span>Diterima {{ '('.$proofAiringThemeAccepted.')' }}</span>
|
||||
<span>Diterima {{ '('.$airingProofReportAccepted.')' }}</span>
|
||||
</div>
|
||||
</li>
|
||||
<li>
|
||||
<div class="title">
|
||||
<span class="dot dot-lg sq" data-bg="#CB0404"></span>
|
||||
<span>Ditolak {{ '('.$proofAiringThemeRejected.')' }}</span>
|
||||
<span>Ditolak {{ '('.$airingProofReportRejected.')' }}</span>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
@ -92,7 +92,7 @@
|
||||
<h6 class="title">Status Laporan Bukti Tayang</h6>
|
||||
</div>
|
||||
</div>
|
||||
<div id="airingProofThemeColumn" style="width: 100%; height: 350px !important;"></div>
|
||||
<div id="airingProofReportColumn" style="width: 100%; height: 350px !important;"></div>
|
||||
</div><!-- .card-inner -->
|
||||
</div>
|
||||
</div><!-- .card -->
|
||||
@ -106,7 +106,7 @@
|
||||
<h6 class="title">Publikasi Laporan Bukti Tayang</h6>
|
||||
</div>
|
||||
</div>
|
||||
<div id="airingProofThemePublicationColumn" style="width: 100%; height: 350px !important;"></div>
|
||||
<div id="airingProofReportPublicationColumn" style="width: 100%; height: 350px !important;"></div>
|
||||
</div><!-- .card-inner -->
|
||||
</div>
|
||||
</div><!-- .card -->
|
||||
|
||||
@ -0,0 +1,215 @@
|
||||
@include('partials.dashboard.head')
|
||||
@include('partials.dashboard.sidebar', ['page' => 'statistics'])
|
||||
@include('partials.dashboard.header')
|
||||
<!-- content @s -->
|
||||
<div class="nk-content ">
|
||||
<div class="container-fluid">
|
||||
<div class="nk-content-inner">
|
||||
<div class="nk-content-body">
|
||||
<div class="nk-block-head nk-block-head-sm">
|
||||
<div class="nk-block-between">
|
||||
<div class="nk-block-head-content">
|
||||
<h3 class="nk-block-title page-title">{{$title}}</h3>
|
||||
{{-- <div class="nk-block-des text-soft">
|
||||
<p>Data: Tahun {{$data_year}}</p>
|
||||
</div> --}}
|
||||
</div><!-- .nk-block-head-content -->
|
||||
{{-- {{dd($cooperationRequests)}} --}}
|
||||
<div class="nk-block-head-content">
|
||||
<div class="toggle-wrap nk-block-tools-toggle">
|
||||
<a href="#" class="btn btn-icon btn-trigger toggle-expand me-n1" data-target="pageMenu"><em class="icon ni ni-more-v"></em></a>
|
||||
<div class="toggle-expand-content" data-content="pageMenu">
|
||||
<ul class="nk-block-tools g-3">
|
||||
<li>
|
||||
<div>
|
||||
<a href="{{route('dashboard.statistics.index')}}" class="btn btn-white btn-dim btn-outline-light"><em class="icon ni ni-arrow-left"></em><span class="d-none d-md-inline">Kembali</a>
|
||||
</div>
|
||||
</li>
|
||||
<li>
|
||||
@if (filled($year) || filled($from_month) || filled($to_month))
|
||||
<span class="mx-1">
|
||||
<a href="{{route('dashboard.statistics.show', ['category' => $category])}}" class="text-secondary">
|
||||
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="currentColor" class="icon icon-tabler icons-tabler-filled icon-tabler-xbox-x"><path stroke="none" d="M0 0h24v24H0z" fill="none"/><path d="M12 2c5.523 0 10 4.477 10 10s-4.477 10 -10 10s-10 -4.477 -10 -10s4.477 -10 10 -10m3.6 5.2a1 1 0 0 0 -1.4 .2l-2.2 2.933l-2.2 -2.933a1 1 0 1 0 -1.6 1.2l2.55 3.4l-2.55 3.4a1 1 0 1 0 1.6 1.2l2.2 -2.933l2.2 2.933a1 1 0 0 0 1.6 -1.2l-2.55 -3.4l2.55 -3.4a1 1 0 0 0 -.2 -1.4" /></svg>
|
||||
</a>
|
||||
</span>
|
||||
@endif
|
||||
<div>
|
||||
<a href="javascript: void(0);" class="btn btn-primary" data-bs-toggle="modal" data-bs-target="#modalFilter"><em class="d-none d-sm-inline icon ni ni-filter"></em><span><span class="d-none d-md-inline">Filter</a>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</div><!-- .nk-block-head-content -->
|
||||
</div><!-- .nk-block-between -->
|
||||
</div><!-- .nk-block-head -->
|
||||
<div class="nk-block">
|
||||
<div class="row g-gs">
|
||||
<div class="col-xxl-3 col-md-6">
|
||||
<div class="card card-full overflow-hidden">
|
||||
<div class="nk-ecwg nk-ecwg7 h-100">
|
||||
<div class="card-inner flex-grow-1">
|
||||
<div class="card-title-group mb-4">
|
||||
<div class="card-title">
|
||||
<h6 class="title">Kanal Rekap Konten</h6>
|
||||
</div>
|
||||
</div>
|
||||
<div class="nk-ecwg7-ck">
|
||||
<canvas class="ecommerce-doughnut-s1" id="contentRecapChannel"></canvas>
|
||||
</div>
|
||||
<ul class="nk-ecwg7-legends">
|
||||
<li>
|
||||
<div class="title">
|
||||
<span class="dot dot-lg sq" data-bg="#1877F2"></span>
|
||||
<span>Facebook {{'('.$facebookContentRecap. ')'}}</span>
|
||||
</div>
|
||||
</li>
|
||||
<li>
|
||||
<div class="title">
|
||||
<span class="dot dot-lg sq" data-bg="#1DA1F2"></span>
|
||||
<span>Twitter {{'('.$twitterContentRecap. ')'}}</span>
|
||||
</div>
|
||||
</li>
|
||||
<li>
|
||||
<div class="title">
|
||||
<span class="dot dot-lg sq" data-bg="#28A745"></span>
|
||||
<span>Website {{'('.$websiteContentRecap. ')'}}</span>
|
||||
</div>
|
||||
</li>
|
||||
<li>
|
||||
<div class="title">
|
||||
<span class="dot dot-lg sq" data-bg="#FF0000"></span>
|
||||
<span>YouTube {{'('.$youtubeContentRecap. ')'}}</span>
|
||||
</div>
|
||||
</li>
|
||||
<li>
|
||||
<div class="title">
|
||||
<span class="dot dot-lg sq" data-bg="#E4405F"></span>
|
||||
<span>Instagram {{'('.$instagramContentRecap. ')'}}</span>
|
||||
</div>
|
||||
</li>
|
||||
<li>
|
||||
<div class="title">
|
||||
<span class="dot dot-lg sq" data-bg="#00F2EA"></span>
|
||||
<span>TikTok {{'('.$tiktokContentRecap. ')'}}</span>
|
||||
</div>
|
||||
</li>
|
||||
<li>
|
||||
<div class="title">
|
||||
<span class="dot dot-lg sq" data-bg="#333333"></span>
|
||||
<span>Cetak {{'('.$cetakContentRecap. ')'}}</span>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
</div><!-- .card-inner -->
|
||||
</div>
|
||||
</div><!-- .card -->
|
||||
</div><!-- .col -->
|
||||
<div class="col-xxl-3 col-md-6">
|
||||
<div class="card card-full overflow-hidden">
|
||||
<div class="nk-ecwg nk-ecwg7 h-100">
|
||||
<div class="card-inner flex-grow-1">
|
||||
<div class="card-title-group mb-4">
|
||||
<div class="card-title">
|
||||
<h6 class="title">Sosial Media Rekap Konten</h6>
|
||||
</div>
|
||||
</div>
|
||||
<div class="nk-ecwg7-ck">
|
||||
<canvas class="ecommerce-doughnut-s1" id="contentRecapSocialMedia"></canvas>
|
||||
</div>
|
||||
<ul class="nk-ecwg7-legends">
|
||||
<li>
|
||||
<div class="title">
|
||||
<span class="dot dot-lg sq" data-bg="#00ADB5"></span>
|
||||
<span>Diskominfo Purwakarta {{'('.$socialMedia1ContentRecap. ')'}}</span>
|
||||
</div>
|
||||
</li>
|
||||
<li>
|
||||
<div class="title">
|
||||
<span class="dot dot-lg sq" data-bg="#EAA64D"></span>
|
||||
<span>PPID Diskominfo Purwakarta {{'('.$socialMedia2ContentRecap. ')'}}</span>
|
||||
</div>
|
||||
</li>
|
||||
<li>
|
||||
<div class="title">
|
||||
<span class="dot dot-lg sq" data-bg="#578FCA"></span>
|
||||
<span>Purwakarta Saber Hoaks {{'('.$socialMedia3ContentRecap. ')'}}</span>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
</div><!-- .card-inner -->
|
||||
</div>
|
||||
</div><!-- .card -->
|
||||
</div><!-- .col -->
|
||||
<div class="col-xxl-3 col-md-12">
|
||||
<div class="card card-full overflow-hidden">
|
||||
<div class="nk-ecwg nk-ecwg7 h-100">
|
||||
<div class="card-inner flex-grow-1">
|
||||
<div class="card-title-group mb-4">
|
||||
<div class="card-title">
|
||||
<h6 class="title">Pembuatan Rekap Konten</h6>
|
||||
</div>
|
||||
</div>
|
||||
<div id="contentRecapMonthly" style="width: 100%; height: 350px !important;"></div>
|
||||
</div><!-- .card-inner -->
|
||||
</div>
|
||||
</div><!-- .card -->
|
||||
</div><!-- .col -->
|
||||
<div class="modal fade" id="modalFilter">
|
||||
<div class="modal-dialog" role="document">
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<h5 class="modal-title">Filter</h5>
|
||||
<a href="javascript:void(0);" class="close" data-bs-dismiss="modal" aria-label="Close">
|
||||
<em class="icon ni ni-cross"></em>
|
||||
</a>
|
||||
</div>
|
||||
<form action="{{route('dashboard.statistics.show', ['category' => $category])}}" class="form-validate is-alter" method="get">
|
||||
<div class="modal-body">
|
||||
<div class="form-group">
|
||||
<label class="form-label" for="year">Tahun</label>
|
||||
<div class="form-control-wrap">
|
||||
<input type="number" class="form-control" id="year" placeholder="Contoh: 2025" name="year" value="{{ old('year', $year ?? '') }}">
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="form-group col-md-6">
|
||||
<label class="form-label" for="from_month">Dari Bulan</label>
|
||||
<div class="form-control-wrap">
|
||||
<input type="month" class="form-control" id="from_month" placeholder="Data berita pada bulan dan tahun" name="from_month" value="{{ old('from_month', $from_month ?? '') }}">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group col-md-6">
|
||||
<label class="form-label" for="to_month">Sampai Bulan</label>
|
||||
<div class="form-control-wrap">
|
||||
<input type="month" class="form-control" id="to_month" placeholder="Data berita pada bulan dan tahun" name="to_month" value="{{ old('to_month', $to_month ?? '') }}">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="modal-footer bg-light">
|
||||
<span class="sub-text">
|
||||
<button type="submit" class="btn btn-sm btn-primary">Filter</button>
|
||||
</span>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{{-- <div class="col-xxl-3 col-md-12">
|
||||
<div class="card card-bordered card-preview">
|
||||
<div class="card-inner">
|
||||
<div class="nk-ck">
|
||||
<canvas class="bar-chart" id="barChartMultiple"></canvas>
|
||||
</div>
|
||||
</div>
|
||||
</div><!-- .card-preview -->
|
||||
</div><!-- .col --> --}}
|
||||
</div><!-- .row -->
|
||||
</div><!-- .nk-block -->
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- content @e -->
|
||||
@include('partials.dashboard.footer', ['statistic_chart' => 'content-recap'])
|
||||
@ -0,0 +1,171 @@
|
||||
@include('partials.dashboard.head')
|
||||
@include('partials.dashboard.sidebar', ['page' => 'statistics'])
|
||||
@include('partials.dashboard.header')
|
||||
<!-- content @s -->
|
||||
<div class="nk-content ">
|
||||
<div class="container-fluid">
|
||||
<div class="nk-content-inner">
|
||||
<div class="nk-content-body">
|
||||
<div class="nk-block-head nk-block-head-sm">
|
||||
<div class="nk-block-between">
|
||||
<div class="nk-block-head-content">
|
||||
<h3 class="nk-block-title page-title">{{$title}}</h3>
|
||||
{{-- <div class="nk-block-des text-soft">
|
||||
<p>Data: Tahun {{$data_year}}</p>
|
||||
</div> --}}
|
||||
</div><!-- .nk-block-head-content -->
|
||||
{{-- {{dd($cooperationRequests)}} --}}
|
||||
<div class="nk-block-head-content">
|
||||
<div class="toggle-wrap nk-block-tools-toggle">
|
||||
<a href="#" class="btn btn-icon btn-trigger toggle-expand me-n1" data-target="pageMenu"><em class="icon ni ni-more-v"></em></a>
|
||||
<div class="toggle-expand-content" data-content="pageMenu">
|
||||
<ul class="nk-block-tools g-3">
|
||||
<li>
|
||||
<div>
|
||||
<a href="{{route('dashboard.statistics.index')}}" class="btn btn-white btn-dim btn-outline-light"><em class="icon ni ni-arrow-left"></em><span class="d-none d-md-inline">Kembali</a>
|
||||
</div>
|
||||
</li>
|
||||
<li>
|
||||
@if (filled($year) || filled($from_month) || filled($to_month))
|
||||
<span class="mx-1">
|
||||
<a href="{{route('dashboard.statistics.show', ['category' => $category])}}" class="text-secondary">
|
||||
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="currentColor" class="icon icon-tabler icons-tabler-filled icon-tabler-xbox-x"><path stroke="none" d="M0 0h24v24H0z" fill="none"/><path d="M12 2c5.523 0 10 4.477 10 10s-4.477 10 -10 10s-10 -4.477 -10 -10s4.477 -10 10 -10m3.6 5.2a1 1 0 0 0 -1.4 .2l-2.2 2.933l-2.2 -2.933a1 1 0 1 0 -1.6 1.2l2.55 3.4l-2.55 3.4a1 1 0 1 0 1.6 1.2l2.2 -2.933l2.2 2.933a1 1 0 0 0 1.6 -1.2l-2.55 -3.4l2.55 -3.4a1 1 0 0 0 -.2 -1.4" /></svg>
|
||||
</a>
|
||||
</span>
|
||||
@endif
|
||||
<div>
|
||||
<a href="javascript: void(0);" class="btn btn-primary" data-bs-toggle="modal" data-bs-target="#modalFilter"><em class="d-none d-sm-inline icon ni ni-filter"></em><span><span class="d-none d-md-inline">Filter</a>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</div><!-- .nk-block-head-content -->
|
||||
</div><!-- .nk-block-between -->
|
||||
</div><!-- .nk-block-head -->
|
||||
<div class="nk-block">
|
||||
<div class="row g-gs">
|
||||
@if (is_role(['1']))
|
||||
<div class="col-xxl-3 col-md-6">
|
||||
<div class="card card-full overflow-hidden">
|
||||
<div class="nk-ecwg nk-ecwg7 h-100">
|
||||
<div class="card-inner flex-grow-1">
|
||||
<div class="card-title-group mb-4">
|
||||
<div class="card-title">
|
||||
<h6 class="title">Status Penyelesaian Kerjasama</h6>
|
||||
</div>
|
||||
</div>
|
||||
<div class="nk-ecwg7-ck">
|
||||
<canvas class="ecommerce-doughnut-s1" id="cooperationCompletionStatus"></canvas>
|
||||
</div>
|
||||
<ul class="nk-ecwg7-legends">
|
||||
<li>
|
||||
<div class="title">
|
||||
<span class="dot dot-lg sq" data-bg="#FFCC00"></span>
|
||||
<span>Menunggu {{ '('.$cooperationCompletionWaiting.')' }}</span>
|
||||
</div>
|
||||
</li>
|
||||
<li>
|
||||
<div class="title">
|
||||
<span class="dot dot-lg sq" data-bg="#0065F8"></span>
|
||||
<span>Diterima {{ '('.$cooperationCompletionAccepted.')' }}</span>
|
||||
</div>
|
||||
</li>
|
||||
<li>
|
||||
<div class="title">
|
||||
<span class="dot dot-lg sq" data-bg="#CB0404"></span>
|
||||
<span>Ditolak {{ '('.$cooperationCompletionRejected.')' }}</span>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
</div><!-- .card-inner -->
|
||||
</div>
|
||||
</div><!-- .card -->
|
||||
</div><!-- .col -->
|
||||
@endif
|
||||
<div class="col-xxl-3 col-md-12">
|
||||
<div class="card card-full overflow-hidden">
|
||||
<div class="nk-ecwg nk-ecwg7 h-100">
|
||||
<div class="card-inner flex-grow-1">
|
||||
<div class="card-title-group mb-4">
|
||||
<div class="card-title">
|
||||
<h6 class="title">Status Penyelesaian Kerjasama</h6>
|
||||
</div>
|
||||
</div>
|
||||
<div id="cooperationCompletionStatusColumn" style="width: 100%; height: 350px !important;"></div>
|
||||
</div><!-- .card-inner -->
|
||||
</div>
|
||||
</div><!-- .card -->
|
||||
</div><!-- .col -->
|
||||
<div class="col-xxl-3 col-md-12">
|
||||
<div class="card card-full overflow-hidden">
|
||||
<div class="nk-ecwg nk-ecwg7 h-100">
|
||||
<div class="card-inner flex-grow-1">
|
||||
<div class="card-title-group mb-4">
|
||||
<div class="card-title">
|
||||
<h6 class="title">Data Penyelesaian Kerjasama</h6>
|
||||
</div>
|
||||
</div>
|
||||
<div id="cooperationCompletionCreatedMonthlyColumn" style="width: 100%; height: 350px !important;"></div>
|
||||
</div><!-- .card-inner -->
|
||||
</div>
|
||||
</div><!-- .card -->
|
||||
</div><!-- .col -->
|
||||
<div class="modal fade" id="modalFilter">
|
||||
<div class="modal-dialog" role="document">
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<h5 class="modal-title">Filter</h5>
|
||||
<a href="javascript:void(0);" class="close" data-bs-dismiss="modal" aria-label="Close">
|
||||
<em class="icon ni ni-cross"></em>
|
||||
</a>
|
||||
</div>
|
||||
<form action="{{route('dashboard.statistics.show', ['category' => $category])}}" class="form-validate is-alter" method="get">
|
||||
<div class="modal-body">
|
||||
<div class="form-group">
|
||||
<label class="form-label" for="year">Tahun</label>
|
||||
<div class="form-control-wrap">
|
||||
<input type="number" class="form-control" id="year" placeholder="Contoh: 2025" name="year" value="{{ old('year', $year ?? '') }}">
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="form-group col-md-6">
|
||||
<label class="form-label" for="from_month">Dari Bulan</label>
|
||||
<div class="form-control-wrap">
|
||||
<input type="month" class="form-control" id="from_month" placeholder="Data berita pada bulan dan tahun" name="from_month" value="{{ old('from_month', $from_month ?? '') }}">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group col-md-6">
|
||||
<label class="form-label" for="to_month">Sampai Bulan</label>
|
||||
<div class="form-control-wrap">
|
||||
<input type="month" class="form-control" id="to_month" placeholder="Data berita pada bulan dan tahun" name="to_month" value="{{ old('to_month', $to_month ?? '') }}">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="modal-footer bg-light">
|
||||
<span class="sub-text">
|
||||
<button type="submit" class="btn btn-sm btn-primary">Filter</button>
|
||||
</span>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{{-- <div class="col-xxl-3 col-md-12">
|
||||
<div class="card card-bordered card-preview">
|
||||
<div class="card-inner">
|
||||
<div class="nk-ck">
|
||||
<canvas class="bar-chart" id="barChartMultiple"></canvas>
|
||||
</div>
|
||||
</div>
|
||||
</div><!-- .card-preview -->
|
||||
</div><!-- .col --> --}}
|
||||
</div><!-- .row -->
|
||||
</div><!-- .nk-block -->
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- content @e -->
|
||||
@include('partials.dashboard.footer', ['statistic_chart' => 'cooperation-completion'])
|
||||
@ -0,0 +1,171 @@
|
||||
@include('partials.dashboard.head')
|
||||
@include('partials.dashboard.sidebar', ['page' => 'statistics'])
|
||||
@include('partials.dashboard.header')
|
||||
<!-- content @s -->
|
||||
<div class="nk-content ">
|
||||
<div class="container-fluid">
|
||||
<div class="nk-content-inner">
|
||||
<div class="nk-content-body">
|
||||
<div class="nk-block-head nk-block-head-sm">
|
||||
<div class="nk-block-between">
|
||||
<div class="nk-block-head-content">
|
||||
<h3 class="nk-block-title page-title">{{$title}}</h3>
|
||||
{{-- <div class="nk-block-des text-soft">
|
||||
<p>Data: Tahun {{$data_year}}</p>
|
||||
</div> --}}
|
||||
</div><!-- .nk-block-head-content -->
|
||||
{{-- {{dd($cooperationRequests)}} --}}
|
||||
<div class="nk-block-head-content">
|
||||
<div class="toggle-wrap nk-block-tools-toggle">
|
||||
<a href="#" class="btn btn-icon btn-trigger toggle-expand me-n1" data-target="pageMenu"><em class="icon ni ni-more-v"></em></a>
|
||||
<div class="toggle-expand-content" data-content="pageMenu">
|
||||
<ul class="nk-block-tools g-3">
|
||||
<li>
|
||||
<div>
|
||||
<a href="{{route('dashboard.statistics.index')}}" class="btn btn-white btn-dim btn-outline-light"><em class="icon ni ni-arrow-left"></em><span class="d-none d-md-inline">Kembali</a>
|
||||
</div>
|
||||
</li>
|
||||
<li>
|
||||
@if (filled($year) || filled($from_month) || filled($to_month))
|
||||
<span class="mx-1">
|
||||
<a href="{{route('dashboard.statistics.show', ['category' => $category])}}" class="text-secondary">
|
||||
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="currentColor" class="icon icon-tabler icons-tabler-filled icon-tabler-xbox-x"><path stroke="none" d="M0 0h24v24H0z" fill="none"/><path d="M12 2c5.523 0 10 4.477 10 10s-4.477 10 -10 10s-10 -4.477 -10 -10s4.477 -10 10 -10m3.6 5.2a1 1 0 0 0 -1.4 .2l-2.2 2.933l-2.2 -2.933a1 1 0 1 0 -1.6 1.2l2.55 3.4l-2.55 3.4a1 1 0 1 0 1.6 1.2l2.2 -2.933l2.2 2.933a1 1 0 0 0 1.6 -1.2l-2.55 -3.4l2.55 -3.4a1 1 0 0 0 -.2 -1.4" /></svg>
|
||||
</a>
|
||||
</span>
|
||||
@endif
|
||||
<div>
|
||||
<a href="javascript: void(0);" class="btn btn-primary" data-bs-toggle="modal" data-bs-target="#modalFilter"><em class="d-none d-sm-inline icon ni ni-filter"></em><span><span class="d-none d-md-inline">Filter</a>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</div><!-- .nk-block-head-content -->
|
||||
</div><!-- .nk-block-between -->
|
||||
</div><!-- .nk-block-head -->
|
||||
<div class="nk-block">
|
||||
<div class="row g-gs">
|
||||
@if (is_role(['1']))
|
||||
<div class="col-xxl-3 col-md-6">
|
||||
<div class="card card-full overflow-hidden">
|
||||
<div class="nk-ecwg nk-ecwg7 h-100">
|
||||
<div class="card-inner flex-grow-1">
|
||||
<div class="card-title-group mb-4">
|
||||
<div class="card-title">
|
||||
<h6 class="title">Status Kerjam Sama Media</h6>
|
||||
</div>
|
||||
</div>
|
||||
<div class="nk-ecwg7-ck">
|
||||
<canvas class="ecommerce-doughnut-s1" id="mediaCooperationStatus"></canvas>
|
||||
</div>
|
||||
<ul class="nk-ecwg7-legends">
|
||||
<li>
|
||||
<div class="title">
|
||||
<span class="dot dot-lg sq" data-bg="#FFCC00"></span>
|
||||
<span>Menunggu {{ '('.$mediaCooperationWaiting.')' }}</span>
|
||||
</div>
|
||||
</li>
|
||||
<li>
|
||||
<div class="title">
|
||||
<span class="dot dot-lg sq" data-bg="#0065F8"></span>
|
||||
<span>Diterima {{ '('.$mediaCooperationAccepted.')' }}</span>
|
||||
</div>
|
||||
</li>
|
||||
<li>
|
||||
<div class="title">
|
||||
<span class="dot dot-lg sq" data-bg="#CB0404"></span>
|
||||
<span>Ditolak {{ '('.$mediaCooperationRejected.')' }}</span>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
</div><!-- .card-inner -->
|
||||
</div>
|
||||
</div><!-- .card -->
|
||||
</div><!-- .col -->
|
||||
@endif
|
||||
<div class="col-xxl-3 col-md-12">
|
||||
<div class="card card-full overflow-hidden">
|
||||
<div class="nk-ecwg nk-ecwg7 h-100">
|
||||
<div class="card-inner flex-grow-1">
|
||||
<div class="card-title-group mb-4">
|
||||
<div class="card-title">
|
||||
<h6 class="title">Status Kerja Sama Media</h6>
|
||||
</div>
|
||||
</div>
|
||||
<div id="mediaCooperationStatusColumn" style="width: 100%; height: 350px !important;"></div>
|
||||
</div><!-- .card-inner -->
|
||||
</div>
|
||||
</div><!-- .card -->
|
||||
</div><!-- .col -->
|
||||
<div class="col-xxl-3 col-md-12">
|
||||
<div class="card card-full overflow-hidden">
|
||||
<div class="nk-ecwg nk-ecwg7 h-100">
|
||||
<div class="card-inner flex-grow-1">
|
||||
<div class="card-title-group mb-4">
|
||||
<div class="card-title">
|
||||
<h6 class="title">Data Kerja Sama Media</h6>
|
||||
</div>
|
||||
</div>
|
||||
<div id="mediaCooperationCreatedMonthlyColumn" style="width: 100%; height: 350px !important;"></div>
|
||||
</div><!-- .card-inner -->
|
||||
</div>
|
||||
</div><!-- .card -->
|
||||
</div><!-- .col -->
|
||||
<div class="modal fade" id="modalFilter">
|
||||
<div class="modal-dialog" role="document">
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<h5 class="modal-title">Filter</h5>
|
||||
<a href="javascript:void(0);" class="close" data-bs-dismiss="modal" aria-label="Close">
|
||||
<em class="icon ni ni-cross"></em>
|
||||
</a>
|
||||
</div>
|
||||
<form action="{{route('dashboard.statistics.show', ['category' => $category])}}" class="form-validate is-alter" method="get">
|
||||
<div class="modal-body">
|
||||
<div class="form-group">
|
||||
<label class="form-label" for="year">Tahun</label>
|
||||
<div class="form-control-wrap">
|
||||
<input type="number" class="form-control" id="year" placeholder="Contoh: 2025" name="year" value="{{ old('year', $year ?? '') }}">
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="form-group col-md-6">
|
||||
<label class="form-label" for="from_month">Dari Bulan</label>
|
||||
<div class="form-control-wrap">
|
||||
<input type="month" class="form-control" id="from_month" placeholder="Data berita pada bulan dan tahun" name="from_month" value="{{ old('from_month', $from_month ?? '') }}">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group col-md-6">
|
||||
<label class="form-label" for="to_month">Sampai Bulan</label>
|
||||
<div class="form-control-wrap">
|
||||
<input type="month" class="form-control" id="to_month" placeholder="Data berita pada bulan dan tahun" name="to_month" value="{{ old('to_month', $to_month ?? '') }}">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="modal-footer bg-light">
|
||||
<span class="sub-text">
|
||||
<button type="submit" class="btn btn-sm btn-primary">Filter</button>
|
||||
</span>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{{-- <div class="col-xxl-3 col-md-12">
|
||||
<div class="card card-bordered card-preview">
|
||||
<div class="card-inner">
|
||||
<div class="nk-ck">
|
||||
<canvas class="bar-chart" id="barChartMultiple"></canvas>
|
||||
</div>
|
||||
</div>
|
||||
</div><!-- .card-preview -->
|
||||
</div><!-- .col --> --}}
|
||||
</div><!-- .row -->
|
||||
</div><!-- .nk-block -->
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- content @e -->
|
||||
@include('partials.dashboard.footer', ['statistic_chart' => 'media-cooperation'])
|
||||
119
resources/views/dashboard/statistics/show/user.blade.php
Normal file
119
resources/views/dashboard/statistics/show/user.blade.php
Normal file
@ -0,0 +1,119 @@
|
||||
@include('partials.dashboard.head')
|
||||
@include('partials.dashboard.sidebar', ['page' => 'statistics'])
|
||||
@include('partials.dashboard.header')
|
||||
<!-- content @s -->
|
||||
<div class="nk-content ">
|
||||
<div class="container-fluid">
|
||||
<div class="nk-content-inner">
|
||||
<div class="nk-content-body">
|
||||
<div class="nk-block-head nk-block-head-sm">
|
||||
<div class="nk-block-between">
|
||||
<div class="nk-block-head-content">
|
||||
<h3 class="nk-block-title page-title">{{$title}}</h3>
|
||||
{{-- <div class="nk-block-des text-soft">
|
||||
<p>Data: Tahun {{$data_year}}</p>
|
||||
</div> --}}
|
||||
</div><!-- .nk-block-head-content -->
|
||||
{{-- {{dd($cooperationRequests)}} --}}
|
||||
<div class="nk-block-head-content">
|
||||
<div class="toggle-wrap nk-block-tools-toggle">
|
||||
<a href="#" class="btn btn-icon btn-trigger toggle-expand me-n1" data-target="pageMenu"><em class="icon ni ni-more-v"></em></a>
|
||||
<div class="toggle-expand-content" data-content="pageMenu">
|
||||
<ul class="nk-block-tools g-3">
|
||||
<li>
|
||||
<div>
|
||||
<a href="{{route('dashboard.statistics.index')}}" class="btn btn-white btn-dim btn-outline-light"><em class="icon ni ni-arrow-left"></em><span class="d-none d-md-inline">Kembali</a>
|
||||
</div>
|
||||
</li>
|
||||
<li>
|
||||
@if (filled($year) || filled($from_month) || filled($to_month))
|
||||
<span class="mx-1">
|
||||
<a href="{{route('dashboard.statistics.show', ['category' => $category])}}" class="text-secondary">
|
||||
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="currentColor" class="icon icon-tabler icons-tabler-filled icon-tabler-xbox-x"><path stroke="none" d="M0 0h24v24H0z" fill="none"/><path d="M12 2c5.523 0 10 4.477 10 10s-4.477 10 -10 10s-10 -4.477 -10 -10s4.477 -10 10 -10m3.6 5.2a1 1 0 0 0 -1.4 .2l-2.2 2.933l-2.2 -2.933a1 1 0 1 0 -1.6 1.2l2.55 3.4l-2.55 3.4a1 1 0 1 0 1.6 1.2l2.2 -2.933l2.2 2.933a1 1 0 0 0 1.6 -1.2l-2.55 -3.4l2.55 -3.4a1 1 0 0 0 -.2 -1.4" /></svg>
|
||||
</a>
|
||||
</span>
|
||||
@endif
|
||||
<div>
|
||||
<a href="javascript: void(0);" class="btn btn-primary" data-bs-toggle="modal" data-bs-target="#modalFilter"><em class="d-none d-sm-inline icon ni ni-filter"></em><span><span class="d-none d-md-inline">Filter</a>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</div><!-- .nk-block-head-content -->
|
||||
</div><!-- .nk-block-between -->
|
||||
</div><!-- .nk-block-head -->
|
||||
<div class="nk-block">
|
||||
<div class="row g-gs">
|
||||
<div class="col-xxl-3 col-md-12">
|
||||
<div class="card card-full overflow-hidden">
|
||||
<div class="nk-ecwg nk-ecwg7 h-100">
|
||||
<div class="card-inner flex-grow-1">
|
||||
<div class="card-title-group mb-4">
|
||||
<div class="card-title">
|
||||
<h6 class="title">Pendaftaran Akun</h6>
|
||||
</div>
|
||||
</div>
|
||||
<div id="registerUserMonth" style="width: 100%; height: 350px !important;"></div>
|
||||
</div><!-- .card-inner -->
|
||||
</div>
|
||||
</div><!-- .card -->
|
||||
</div><!-- .col -->
|
||||
<div class="modal fade" id="modalFilter">
|
||||
<div class="modal-dialog" role="document">
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<h5 class="modal-title">Filter</h5>
|
||||
<a href="javascript:void(0);" class="close" data-bs-dismiss="modal" aria-label="Close">
|
||||
<em class="icon ni ni-cross"></em>
|
||||
</a>
|
||||
</div>
|
||||
<form action="{{route('dashboard.statistics.show', ['category' => $category])}}" class="form-validate is-alter" method="get">
|
||||
<div class="modal-body">
|
||||
<div class="form-group">
|
||||
<label class="form-label" for="year">Tahun</label>
|
||||
<div class="form-control-wrap">
|
||||
<input type="number" class="form-control" id="year" placeholder="Contoh: 2025" name="year" value="{{ old('year', $year ?? '') }}">
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="form-group col-md-6">
|
||||
<label class="form-label" for="from_month">Dari Bulan</label>
|
||||
<div class="form-control-wrap">
|
||||
<input type="month" class="form-control" id="from_month" placeholder="Data berita pada bulan dan tahun" name="from_month" value="{{ old('from_month', $from_month ?? '') }}">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group col-md-6">
|
||||
<label class="form-label" for="to_month">Sampai Bulan</label>
|
||||
<div class="form-control-wrap">
|
||||
<input type="month" class="form-control" id="to_month" placeholder="Data berita pada bulan dan tahun" name="to_month" value="{{ old('to_month', $to_month ?? '') }}">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="modal-footer bg-light">
|
||||
<span class="sub-text">
|
||||
<button type="submit" class="btn btn-sm btn-primary">Filter</button>
|
||||
</span>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{{-- <div class="col-xxl-3 col-md-12">
|
||||
<div class="card card-bordered card-preview">
|
||||
<div class="card-inner">
|
||||
<div class="nk-ck">
|
||||
<canvas class="bar-chart" id="barChartMultiple"></canvas>
|
||||
</div>
|
||||
</div>
|
||||
</div><!-- .card-preview -->
|
||||
</div><!-- .col --> --}}
|
||||
</div><!-- .row -->
|
||||
</div><!-- .nk-block -->
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- content @e -->
|
||||
@include('partials.dashboard.footer', ['statistic_chart' => 'users'])
|
||||
@ -0,0 +1,119 @@
|
||||
@include('partials.dashboard.head')
|
||||
@include('partials.dashboard.sidebar', ['page' => 'statistics'])
|
||||
@include('partials.dashboard.header')
|
||||
<!-- content @s -->
|
||||
<div class="nk-content ">
|
||||
<div class="container-fluid">
|
||||
<div class="nk-content-inner">
|
||||
<div class="nk-content-body">
|
||||
<div class="nk-block-head nk-block-head-sm">
|
||||
<div class="nk-block-between">
|
||||
<div class="nk-block-head-content">
|
||||
<h3 class="nk-block-title page-title">{{$title}}</h3>
|
||||
{{-- <div class="nk-block-des text-soft">
|
||||
<p>Data: Tahun {{$data_year}}</p>
|
||||
</div> --}}
|
||||
</div><!-- .nk-block-head-content -->
|
||||
{{-- {{dd($cooperationRequests)}} --}}
|
||||
<div class="nk-block-head-content">
|
||||
<div class="toggle-wrap nk-block-tools-toggle">
|
||||
<a href="#" class="btn btn-icon btn-trigger toggle-expand me-n1" data-target="pageMenu"><em class="icon ni ni-more-v"></em></a>
|
||||
<div class="toggle-expand-content" data-content="pageMenu">
|
||||
<ul class="nk-block-tools g-3">
|
||||
<li>
|
||||
<div>
|
||||
<a href="{{route('dashboard.statistics.index')}}" class="btn btn-white btn-dim btn-outline-light"><em class="icon ni ni-arrow-left"></em><span class="d-none d-md-inline">Kembali</a>
|
||||
</div>
|
||||
</li>
|
||||
<li>
|
||||
@if (filled($year) || filled($from_month) || filled($to_month))
|
||||
<span class="mx-1">
|
||||
<a href="{{route('dashboard.statistics.show', ['category' => $category])}}" class="text-secondary">
|
||||
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="currentColor" class="icon icon-tabler icons-tabler-filled icon-tabler-xbox-x"><path stroke="none" d="M0 0h24v24H0z" fill="none"/><path d="M12 2c5.523 0 10 4.477 10 10s-4.477 10 -10 10s-10 -4.477 -10 -10s4.477 -10 10 -10m3.6 5.2a1 1 0 0 0 -1.4 .2l-2.2 2.933l-2.2 -2.933a1 1 0 1 0 -1.6 1.2l2.55 3.4l-2.55 3.4a1 1 0 1 0 1.6 1.2l2.2 -2.933l2.2 2.933a1 1 0 0 0 1.6 -1.2l-2.55 -3.4l2.55 -3.4a1 1 0 0 0 -.2 -1.4" /></svg>
|
||||
</a>
|
||||
</span>
|
||||
@endif
|
||||
<div>
|
||||
<a href="javascript: void(0);" class="btn btn-primary" data-bs-toggle="modal" data-bs-target="#modalFilter"><em class="d-none d-sm-inline icon ni ni-filter"></em><span><span class="d-none d-md-inline">Filter</a>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</div><!-- .nk-block-head-content -->
|
||||
</div><!-- .nk-block-between -->
|
||||
</div><!-- .nk-block-head -->
|
||||
<div class="nk-block">
|
||||
<div class="row g-gs">
|
||||
<div class="col-xxl-3 col-md-12">
|
||||
<div class="card card-full overflow-hidden">
|
||||
<div class="nk-ecwg nk-ecwg7 h-100">
|
||||
<div class="card-inner flex-grow-1">
|
||||
<div class="card-title-group mb-4">
|
||||
<div class="card-title">
|
||||
<h6 class="title">Pengunjung Website</h6>
|
||||
</div>
|
||||
</div>
|
||||
<div id="websiteVisitorMonth" style="width: 100%; height: 350px !important;"></div>
|
||||
</div><!-- .card-inner -->
|
||||
</div>
|
||||
</div><!-- .card -->
|
||||
</div><!-- .col -->
|
||||
<div class="modal fade" id="modalFilter">
|
||||
<div class="modal-dialog" role="document">
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<h5 class="modal-title">Filter</h5>
|
||||
<a href="javascript:void(0);" class="close" data-bs-dismiss="modal" aria-label="Close">
|
||||
<em class="icon ni ni-cross"></em>
|
||||
</a>
|
||||
</div>
|
||||
<form action="{{route('dashboard.statistics.show', ['category' => $category])}}" class="form-validate is-alter" method="get">
|
||||
<div class="modal-body">
|
||||
<div class="form-group">
|
||||
<label class="form-label" for="year">Tahun</label>
|
||||
<div class="form-control-wrap">
|
||||
<input type="number" class="form-control" id="year" placeholder="Contoh: 2025" name="year" value="{{ old('year', $year ?? '') }}">
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="form-group col-md-6">
|
||||
<label class="form-label" for="from_month">Dari Bulan</label>
|
||||
<div class="form-control-wrap">
|
||||
<input type="month" class="form-control" id="from_month" placeholder="Data berita pada bulan dan tahun" name="from_month" value="{{ old('from_month', $from_month ?? '') }}">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group col-md-6">
|
||||
<label class="form-label" for="to_month">Sampai Bulan</label>
|
||||
<div class="form-control-wrap">
|
||||
<input type="month" class="form-control" id="to_month" placeholder="Data berita pada bulan dan tahun" name="to_month" value="{{ old('to_month', $to_month ?? '') }}">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="modal-footer bg-light">
|
||||
<span class="sub-text">
|
||||
<button type="submit" class="btn btn-sm btn-primary">Filter</button>
|
||||
</span>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{{-- <div class="col-xxl-3 col-md-12">
|
||||
<div class="card card-bordered card-preview">
|
||||
<div class="card-inner">
|
||||
<div class="nk-ck">
|
||||
<canvas class="bar-chart" id="barChartMultiple"></canvas>
|
||||
</div>
|
||||
</div>
|
||||
</div><!-- .card-preview -->
|
||||
</div><!-- .col --> --}}
|
||||
</div><!-- .row -->
|
||||
</div><!-- .nk-block -->
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- content @e -->
|
||||
@include('partials.dashboard.footer', ['statistic_chart' => 'website-visitors'])
|
||||
@ -118,6 +118,21 @@
|
||||
@case('login-activities')
|
||||
@include('dashboard.statistics.chart.login-activity')
|
||||
@break
|
||||
@case('users')
|
||||
@include('dashboard.statistics.chart.user')
|
||||
@break
|
||||
@case('website-visitors')
|
||||
@include('dashboard.statistics.chart.website-visitor')
|
||||
@break
|
||||
@case('cooperation-completion')
|
||||
@include('dashboard.statistics.chart.cooperation-completion')
|
||||
@break
|
||||
@case('media-cooperation')
|
||||
@include('dashboard.statistics.chart.media-cooperation')
|
||||
@break
|
||||
@case('content-recap')
|
||||
@include('dashboard.statistics.chart.content-recap')
|
||||
@break
|
||||
@default
|
||||
|
||||
@endswitch
|
||||
|
||||
Loading…
Reference in New Issue
Block a user