Commit 431428a3 authored by Syaifur Rohman's avatar Syaifur Rohman

fix index sekolah wali show

parent f0c64929
...@@ -20,7 +20,7 @@ public function __construct() ...@@ -20,7 +20,7 @@ public function __construct()
$this->mSiswa = new SiswaModel(); $this->mSiswa = new SiswaModel();
$this->mSekolahWali = new SekolahWaliModel(); $this->mSekolahWali = new SekolahWaliModel();
$this->mGuru = new GuruModel(); $this->mGuru = new GuruModel();
$this->mPerpusKelasKode = new KelasKodeModel(); $this->mPerpusKelasKode = new KelasKodeModel();
} }
function getSekolahWali($idPKelas = null) function getSekolahWali($idPKelas = null)
...@@ -36,8 +36,8 @@ public function __construct() ...@@ -36,8 +36,8 @@ public function __construct()
{ {
$tbody = []; $tbody = [];
$tbody[] = $i++; $tbody[] = $i++;
$tbody[] = $row->kelas->nama.' '.$row->jurusan->nama.' '.$row->nama; $tbody[] = $row->kelas->nama.' '.$row->kelas->jurusan->nama.' '.$row->nama;
if ($row->idSWali == 0) { if ($row->idSWali == 0) {
$tbody[] ='<span class="text-warning">Belum Diset</span>'; $tbody[] ='<span class="text-warning">Belum Diset</span>';
...@@ -52,13 +52,13 @@ public function __construct() ...@@ -52,13 +52,13 @@ public function __construct()
$btnDetail = "<a href='".url($this->url."/wali-kelas/".$row['id'])."'><button type='button' class='btn btn-primary btn-sm' title='Detail Data'>Detail</button></a>"; $btnDetail = "<a href='".url($this->url."/wali-kelas/".$row['id'])."'><button type='button' class='btn btn-primary btn-sm' title='Detail Data'>Detail</button></a>";
$btnEdit = "<button type='button' class='btn btn-primary btn-sm set-wali' title='Detail Data' data-bs-toggle='modal' data-bs-target='#modalPilihWali' data-id='".$row['id']."'>".$textWali."</button>"; $btnEdit = "<button type='button' class='btn btn-primary btn-sm set-wali' title='Detail Data' data-bs-toggle='modal' data-bs-target='#modalPilihWali' data-id='".$row['id']."'>".$textWali."</button>";
$btn = $btnDetail.' '.$btnEdit; $btn = $btnDetail.' '.$btnEdit;
$tbody[] = $btn; $tbody[] = $btn;
$data[] = $tbody; $data[] = $tbody;
}; };
if (count($kelaskode) > 0) if (count($kelaskode) > 0)
{ {
$response = [ $response = [
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment