Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
S
sibiling
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
1
Issues
1
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Syaifur
sibiling
Commits
c4caaefb
Commit
c4caaefb
authored
Oct 23, 2024
by
syaifurplus
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
konferensi hapus
parent
04542b53
Changes
3
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
0 additions
and
553 deletions
+0
-553
KonferensiBeritaAcaraController.php
...in/Layanan/konferensi/KonferensiBeritaAcaraController.php
+0
-239
KonferensiKegiatanController.php
...Admin/Layanan/konferensi/KonferensiKegiatanController.php
+0
-180
KonferensiRPLController.php
...lers/Admin/Layanan/konferensi/KonferensiRPLController.php
+0
-134
No files found.
app/Http/Controllers/Admin/Layanan/konferensi/KonferensiBeritaAcaraController.php
deleted
100644 → 0
View file @
04542b53
This diff is collapsed.
Click to expand it.
app/Http/Controllers/Admin/Layanan/konferensi/KonferensiKegiatanController.php
deleted
100644 → 0
View file @
04542b53
<?php
namespace
App\Http\Controllers\Admin\Layanan\konferensi
;
use
App\Http\Controllers\Controller
;
use
Illuminate\Http\Request
;
use
App\Models\Master\PeriodeModel
;
use
App\Models\Perpus\SekolahModel
;
use
App\Models\Perpus\KelasModel
;
use
App\Models\Perpus\KelasKodeModel
;
use
App\Models\Perpus\JurusanModel
;
use
App\Models\Stakeholder\KepsekModel
;
use
App\Models\Stakeholder\KonselorModel
;
use
App\Models\Siswa\SiswaModel
;
use
App\Models\Layanan\Konferensi\KonKegiatanModel
;
use
App\Models\Layanan\Konferensi\KonRPLModel
;
use
App\Models\Layanan\Konferensi\KonBeritaAcaraModel
;
use
PhpOffice\PhpWord\TemplateProcessor
;
class
KonferensiKegiatanController
extends
Controller
{
private
$views
=
'admin/layanan/konferensi/konferensi_kegiatan'
;
private
$url
=
'admin/layanan/lainnya/konferensi/kegiatan'
;
private
$url2
=
'admin/layanan/lainnya/konferensi/rpl'
;
private
$url3
=
'admin/layanan/lainnya/konferensi/berita-acara'
;
private
$title
=
'Halaman Konferensi Kegiatan'
;
public
function
__construct
()
{
createLogActivity
();
// Di isi Construct
$this
->
mPeriode
=
new
PeriodeModel
();
$this
->
mPerpusSekolah
=
new
SekolahModel
();
$this
->
mPerpusJurusan
=
new
JurusanModel
();
$this
->
mPerpusKelas
=
new
KelasModel
();
$this
->
mPerpusKelasKode
=
new
KelasKodeModel
();
$this
->
mKepsek
=
new
KepsekModel
();
$this
->
mKonselor
=
new
KonselorModel
();
$this
->
mSiswa
=
new
SiswaModel
();
$this
->
mKonKegiatan
=
new
KonKegiatanModel
();
$this
->
mKonRPL
=
new
KonRPLModel
();
$this
->
mKonBeritaAcara
=
new
KonBeritaAcaraModel
();
}
public
function
index
()
{
$wherenyaa
=
[
'idPSekolah'
=>
session
()
->
get
(
'idPSekolah'
),
'idSKonselor'
=>
session
()
->
get
(
'idSKonselor'
),
];
$konkegiatan
=
$this
->
mKonKegiatan
->
where
(
$wherenyaa
)
->
get
();
$data
=
[
'title'
=>
$this
->
title
,
'url'
=>
$this
->
url
,
'page'
=>
'Data Konferensi Kegiatan'
,
'konkegiatan'
=>
$konkegiatan
,
];
return
view
(
$this
->
views
.
"/index"
,
$data
);
}
public
function
create
()
{
$periode
=
$this
->
mPeriode
->
get
();
$konselor
=
$this
->
mKonselor
->
where
(
'idPSekolah'
,
session
()
->
get
(
'idPSekolah'
))
->
get
();
// $kepsek = $this->mKepsek->where('idPSekolah', session()->get('idPSekolah'))->get();
$whereKep
=
[
'status'
=>
1
,
'idPSekolah'
=>
session
()
->
get
(
'idPSekolah'
)
];
$kepsek
=
$this
->
mKepsek
->
where
(
$whereKep
)
->
get
();
$data
=
[
'title'
=>
$this
->
title
,
'url'
=>
$this
->
url
,
'page'
=>
'Tambah Data Konferensi Kegiatan'
,
'periode'
=>
$periode
,
'konselor'
=>
$konselor
,
'kepsek'
=>
$kepsek
,
];
return
view
(
$this
->
views
.
"/create"
,
$data
);
}
public
function
show
(
$id
)
{
// Get Data
$konKegiatan
=
$this
->
mKonKegiatan
->
where
(
'kode_unik'
,
$id
)
->
first
();
$konrpl
=
$this
->
mKonRPL
->
where
(
'idLKKegiatan'
,
$konKegiatan
[
'id'
])
->
first
();
$data
=
[
'title'
=>
$this
->
title
,
'url'
=>
$this
->
url
,
'url2'
=>
$this
->
url2
,
'url3'
=>
$this
->
url3
,
'page'
=>
'Detail Data Konferensi Kegiatan'
,
'id'
=>
$id
,
'konrpl'
=>
$konrpl
,
'konkegiatan'
=>
$konKegiatan
,
];
if
(
$konKegiatan
[
'status'
]
==
2
){
// PANGGIL MODEL BERITA ACARA
$konberitaacara
=
$this
->
mKonBeritaAcara
->
where
(
'idLKKegiatan'
,
$konKegiatan
[
'id'
])
->
first
();
$data
[
'konberitaacara'
]
=
$konberitaacara
;
}
// echo json_encode($konrpl); die;
return
view
(
$this
->
views
.
"/show"
,
$data
);
}
public
function
store
(
Request
$request
)
{
$siswa
=
$this
->
mSiswa
->
where
(
'id'
,
$request
->
idSiswa
)
->
first
();
$whereKons
=
[
'id'
=>
$siswa
[
'idSKonselor'
],
'status'
=>
1
,
];
$konselor
=
$this
->
mKonselor
->
where
(
$whereKons
)
->
first
();
if
(
!
isset
(
$konselor
)){
return
redirect
(
"
$this->url
"
)
->
with
(
'gagal'
,
'Guru Konseling belum di set atau tidak aktif'
);
};
$whereKep
=
[
'idPSekolah'
=>
session
()
->
get
(
'idPSekolah'
),
'status'
=>
1
];
$kepsek
=
$this
->
mKepsek
->
where
(
$whereKep
)
->
first
();
if
(
!
isset
(
$kepsek
)){
return
redirect
(
"
$this->url
"
)
->
with
(
'gagal'
,
'Kepsek belum di set'
);
};
$suratWaktu
=
$request
->
surat_waktu
;
$suratWaktunew
=
date
(
"d-m-Y"
,
strtotime
(
$suratWaktu
));
$isianWaktu
=
$request
->
isian_waktu
;
$isianWaktunew
=
date
(
"d-m-Y"
,
strtotime
(
$isianWaktu
));
$dataKonKegiatan
=
[
'idPSekolah'
=>
session
()
->
get
(
'idPSekolah'
),
'idSKonselor'
=>
session
()
->
get
(
'idSKonselor'
),
'idPKKode'
=>
$request
->
idPKKode
,
'idPPeriode'
=>
session
()
->
get
(
'idPPeriode'
),
'idSiswa'
=>
$request
->
idSiswa
,
'kode_unik'
=>
strtoupper
(
bin2hex
(
random_bytes
(
3
))),
'status'
=>
1
];
$KonKegiatan
=
$this
->
mKonKegiatan
->
create
(
$dataKonKegiatan
);
$dataRPL
=
[
'idLKKegiatan'
=>
$KonKegiatan
[
'id'
],
// untuk mmebuat relasi yang baik
'idSKepsek'
=>
$kepsek
[
'id'
],
'idSKonselor'
=>
$konselor
[
'id'
],
'surat_tempat'
=>
$request
->
surat_tempat
,
'surat_waktu'
=>
$suratWaktunew
,
'isian_judul'
=>
$request
->
isian_judul
,
'isian_fungsi'
=>
$request
->
isian_fungsi
,
'isian_tujuan'
=>
$request
->
isian_tujuan
,
'isian_hasil'
=>
$request
->
isian_hasil
,
'isian_gambaran'
=>
$request
->
isian_gambaran
,
'isian_tempat'
=>
$request
->
isian_tempat
,
'isian_waktu'
=>
$isianWaktunew
,
'isian_tanggal'
=>
$request
->
isian_tanggal
,
'isian_semester'
=>
$request
->
isian_semester
,
'isian_penyelenggara'
=>
$request
->
isian_penyelenggara
,
'isian_pihak'
=>
$request
->
isian_pihak
,
'isian_bahan'
=>
$request
->
isian_bahan
,
'isian_penggunaan'
=>
$request
->
isian_penggunaan
,
'isian_rencana'
=>
$request
->
isian_rencana
,
'isian_catatan'
=>
$request
->
isian_catatan
,
];
$this
->
mKonRPL
->
create
(
$dataRPL
);
return
redirect
(
"
$this->url
"
)
->
with
(
'sukses'
,
'Data Konferensi Kegiatan berhasil di tambahkan'
);
}
}
app/Http/Controllers/Admin/Layanan/konferensi/KonferensiRPLController.php
deleted
100644 → 0
View file @
04542b53
<?php
namespace
App\Http\Controllers\Admin\Layanan\konferensi
;
use
App\Http\Controllers\Controller
;
use
Illuminate\Http\Request
;
use
App\Models\Master\PeriodeModel
;
use
App\Models\Perpus\SekolahModel
;
use
App\Models\Perpus\KelasModel
;
use
App\Models\Perpus\KelasKodeModel
;
use
App\Models\Perpus\JurusanModel
;
use
App\Models\Stakeholder\KepsekModel
;
use
App\Models\Stakeholder\KonselorModel
;
use
App\Models\Stakeholder\GuruModel
;
use
App\Models\Siswa\SiswaModel
;
use
App\Models\Layanan\Konferensi\KonKegiatanModel
;
use
App\Models\Layanan\Konferensi\KonRPLModel
;
use
PhpOffice\PhpWord\TemplateProcessor
;
class
KonferensiRPLController
extends
Controller
{
private
$views
=
'admin/layanan/konferensi/konferensi_RPL'
;
private
$url
=
'admin/layanan/lainnya/konferensi/rpl'
;
private
$url2
=
'admin/layanan/lainnya/konferensi/kegiatan'
;
private
$title
=
'Halaman Konferensi RPL'
;
public
function
__construct
()
{
createLogActivity
();
// Di isi Construct
$this
->
mPeriode
=
new
PeriodeModel
();
$this
->
mPerpusSekolah
=
new
SekolahModel
();
$this
->
mPerpusJurusan
=
new
JurusanModel
();
$this
->
mPerpusKelas
=
new
KelasModel
();
$this
->
mPerpusKelasKode
=
new
KelasKodeModel
();
$this
->
mKepsek
=
new
KepsekModel
();
$this
->
mGuru
=
new
GuruModel
();
$this
->
mSiswa
=
new
SiswaModel
();
$this
->
mKonKegiatan
=
new
KonKegiatanModel
();
$this
->
mKonselor
=
new
KonselorModel
();
$this
->
mKonRPL
=
new
KonRPLModel
();
}
public
function
show
(
$id
)
{
// Get Data
$konrpl
=
$this
->
mKonRPL
->
where
(
'id'
,
$id
)
->
first
();
$data
=
[
'title'
=>
$this
->
title
,
'url'
=>
$this
->
url
,
'url2'
=>
$this
->
url2
,
'page'
=>
'Data Konferensi RPL'
,
'konrpl'
=>
$konrpl
,
];
return
view
(
$this
->
views
.
"/show"
,
$data
);
}
public
function
download
(
$id
)
{
if
(
!
cekKopSurat
(
session
()
->
get
(
'idPSekolah'
)))
{
return
redirect
(
"admin/dashboard"
)
->
with
(
'gagal'
,
'Kop Surat tidak ditemukan, mohon upload ulang melalui login Admin Sekolah'
);
}
$sekolah
=
$this
->
mPerpusSekolah
->
where
(
'id'
,
session
()
->
get
(
'idPSekolah'
))
->
first
();
$konrpl
=
$this
->
mKonRPL
->
where
(
'id'
,
$id
)
->
first
();
// dd($mundur);
$datakonrpl
=
[
'KopSurat'
=>
$sekolah
->
logo
,
'surat_tempat'
=>
$konrpl
->
surat_tempat
,
'surat_waktu'
=>
$konrpl
->
surat_waktu
,
'namaKonselor'
=>
$konrpl
->
konselor
->
guru
->
nama
??
'Guru Konseling belum di SET'
,
'nipKonselor'
=>
$konrpl
->
konselor
->
guru
->
nip
??
'Guru Konseling belum di SET'
,
'namaKepsek'
=>
$konrpl
->
kepsek
->
guru
->
nama
??
'Kepsek belum di SET'
,
'nipKepsek'
=>
$konrpl
->
kepsek
->
guru
->
nip
??
'Kepsek belum di SET'
,
'isian_judul'
=>
$konrpl
->
isian_judul
,
'isian_fungsi'
=>
$konrpl
->
isian_fungsi
,
'isian_tujuan'
=>
$konrpl
->
isian_tujuan
,
'isian_hasil'
=>
$konrpl
->
isian_hasil
,
'idSiswa'
=>
$konrpl
->
konkegiatan
->
siswa
->
nama
,
'isian_gambaran'
=>
$konrpl
->
isian_gambaran
,
'isian_tempat'
=>
$konrpl
->
isian_tempat
,
'isian_waktu'
=>
$konrpl
->
isian_waktu
,
'isian_tanggal'
=>
$konrpl
->
isian_tanggal
,
'isian_semester'
=>
$konrpl
->
isian_semester
,
'isian_penyelenggara'
=>
$konrpl
->
isian_penyelenggara
,
'isian_pihak'
=>
$konrpl
->
isian_pihak
,
'isian_bahan'
=>
$konrpl
->
isian_bahan
,
'isian_penggunaan'
=>
$konrpl
->
isian_penggunaan
,
'isian_rencana'
=>
$konrpl
->
isian_rencana
,
'isian_catatan'
=>
$konrpl
->
isian_catatan
,
];
// pakai dari sini. sambil buka word coba.docx
$templateProcessor
=
new
TemplateProcessor
(
'word-template/konferensi_kasus/konferensikasus_kegiatan.docx'
);
// load template word
$templateProcessor
->
setImageValue
(
'KopSurat'
,
array
(
'path'
=>
"upload/logo_sekolah/"
.
$datakonrpl
[
'KopSurat'
],
'width'
=>
500
,
'height'
=>
200
,
'ratio'
=>
true
));
$templateProcessor
->
setValue
(
'surat_tempat'
,
$datakonrpl
[
'surat_tempat'
]);
$templateProcessor
->
setValue
(
'surat_waktu'
,
$datakonrpl
[
'surat_waktu'
]);
$templateProcessor
->
setValue
(
'namaKonselor'
,
$datakonrpl
[
'namaKonselor'
]);
$templateProcessor
->
setValue
(
'nipKonselor'
,
$datakonrpl
[
'nipKonselor'
]);
$templateProcessor
->
setValue
(
'namaKepsek'
,
$datakonrpl
[
'namaKepsek'
]);
$templateProcessor
->
setValue
(
'nipKepsek'
,
$datakonrpl
[
'nipKepsek'
]);
$templateProcessor
->
setValue
(
'isian_judul'
,
$datakonrpl
[
'isian_judul'
]);
$templateProcessor
->
setValue
(
'isian_fungsi'
,
$datakonrpl
[
'isian_fungsi'
]);
$templateProcessor
->
setValue
(
'isian_tujuan'
,
$datakonrpl
[
'isian_tujuan'
]);
$templateProcessor
->
setValue
(
'isian_hasil'
,
$datakonrpl
[
'isian_hasil'
]);
$templateProcessor
->
setValue
(
'idSiswa'
,
$datakonrpl
[
'idSiswa'
]);
$templateProcessor
->
setValue
(
'isian_gambaran'
,
$datakonrpl
[
'isian_gambaran'
]);
$templateProcessor
->
setValue
(
'isian_tempat'
,
$datakonrpl
[
'isian_tempat'
]);
$templateProcessor
->
setValue
(
'isian_waktu'
,
$datakonrpl
[
'isian_waktu'
]);
$templateProcessor
->
setValue
(
'isian_tanggal'
,
$datakonrpl
[
'isian_tanggal'
]);
$templateProcessor
->
setValue
(
'isian_semester'
,
$datakonrpl
[
'isian_semester'
]);
$templateProcessor
->
setValue
(
'isian_penyelenggara'
,
$datakonrpl
[
'isian_penyelenggara'
]);
$templateProcessor
->
setValue
(
'isian_pihak'
,
$datakonrpl
[
'isian_pihak'
]);
$templateProcessor
->
setValue
(
'isian_bahan'
,
$datakonrpl
[
'isian_bahan'
]);
$templateProcessor
->
setValue
(
'isian_penggunaan'
,
$datakonrpl
[
'isian_penggunaan'
]);
$templateProcessor
->
setValue
(
'isian_rencana'
,
$datakonrpl
[
'isian_rencana'
]);
$templateProcessor
->
setValue
(
'isian_catatan'
,
$datakonrpl
[
'isian_catatan'
]);
$fileName
=
'konferensikasus_kegiatan'
;
// nama filenya
// biar bisa dunlud
$templateProcessor
->
saveAs
(
'tempor/'
.
$fileName
.
'.docx'
);
return
response
()
->
download
(
'tempor/'
.
$fileName
.
'.docx'
)
->
deleteFileAfterSend
(
true
);
// dd($datamundur);
}
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment