From 45dd55b1315ef7e7d1016560489291655dfe4934 Mon Sep 17 00:00:00 2001 From: amelrnt Date: Wed, 16 Oct 2019 18:06:33 +0700 Subject: [PATCH 1/5] add file --- application/controllers/usersiswa.php | 45 +++++++++++++++++++++++++++ 1 file changed, 45 insertions(+) create mode 100644 application/controllers/usersiswa.php diff --git a/application/controllers/usersiswa.php b/application/controllers/usersiswa.php new file mode 100644 index 0000000..f8d26f2 --- /dev/null +++ b/application/controllers/usersiswa.php @@ -0,0 +1,45 @@ +load->helper('url'); + $this->load->helper('form'); + $this->load->model('loginsiswa_model'); + $this->load->model('siswa_model'); + //$this->load->library('session'); + if ($this->session->userdata('level') != 'siswa' ) { + + redirect('loginsiswa','refresh'); + + } + + } + + public function index() + { + $data = array( + 'title'=>'data siswa', + 'siswa'=>$this->siswa_model->datatabels() + ); + $this->load->view('template/header_datatabels_users',$data); + $this->load->view('siswa/user'); + $this->load->view('template/footer_datatabels_users'); + } + + public function laporan_pdf() + { + $this->load->library('pdf'); + $this->load->model('cetaksiswa_model'); + $data['siswa']= $this->cetaksiswa_model->view(); + $this->load->library('pdf'); + + $this->pdf->setPaper('A4','potrait'); + $this->pdf->filename = "laporan-petanikode.pdf"; + $this->pdf->load_view('siswa/laporan',$data); + } +} +?> \ No newline at end of file From 05a86b9cf9999aaf0d0ec5c8b1c817fc3e928fdc Mon Sep 17 00:00:00 2001 From: amelrnt Date: Wed, 16 Oct 2019 18:13:48 +0700 Subject: [PATCH 2/5] new change --- application/controllers/mahasiswa.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/application/controllers/mahasiswa.php b/application/controllers/mahasiswa.php index 445e9e4..7e0355e 100644 --- a/application/controllers/mahasiswa.php +++ b/application/controllers/mahasiswa.php @@ -80,12 +80,13 @@ public function edit($id){ $this->load->view('template/header',$data); $this->load->view('mahasiswa/edit',$data); $this->load->view('template/footer'); + echo "masuk"; } else{ $this->mahasiswa_model->ubahdatamhs(); $this->session->set_flashdata('flash-data','diedit'); redirect('mahasiswa','refresh'); - + echo "keluar"; } } From 8d26a583d5b42e41fe03c0be6d5a752794e20005 Mon Sep 17 00:00:00 2001 From: amelrnt Date: Wed, 16 Oct 2019 18:23:51 +0700 Subject: [PATCH 3/5] laporan --- application/views/siswa/laporan.php | 65 +++++++++++++++++++++++++++++ 1 file changed, 65 insertions(+) create mode 100644 application/views/siswa/laporan.php diff --git a/application/views/siswa/laporan.php b/application/views/siswa/laporan.php new file mode 100644 index 0000000..412574d --- /dev/null +++ b/application/views/siswa/laporan.php @@ -0,0 +1,65 @@ + + + + Report Table + + + +
+ + + + + + + + + + + + + + + + + + + + + +
#NamaAlamatNIM
nama; ?>alamat; ?>nim; ?>
+
+ + \ No newline at end of file From ef18568164034409cf18b48c9c725093841d09ee Mon Sep 17 00:00:00 2001 From: amelrnt Date: Wed, 16 Oct 2019 22:33:20 +0700 Subject: [PATCH 4/5] tambah laporan --- application/views/mahasiswa/laporan.php | 65 +++++++++++++++++++++++++ 1 file changed, 65 insertions(+) create mode 100644 application/views/mahasiswa/laporan.php diff --git a/application/views/mahasiswa/laporan.php b/application/views/mahasiswa/laporan.php new file mode 100644 index 0000000..4950bc1 --- /dev/null +++ b/application/views/mahasiswa/laporan.php @@ -0,0 +1,65 @@ + + + + Report Table + + + +
+ + + + + + + + + + + + + + + + + + + + + +
#NamaEmailJurusan
nama; ?>email; ?>jurusan; ?>
+
+ + \ No newline at end of file From eef8269264f1ceeaafa56fd08fd8583928588b95 Mon Sep 17 00:00:00 2001 From: amelrnt Date: Wed, 16 Oct 2019 22:39:49 +0700 Subject: [PATCH 5/5] tambah login --- application/views/loginsiswa/index.php | 49 ++++++++++++++++++++++++++ 1 file changed, 49 insertions(+) create mode 100644 application/views/loginsiswa/index.php diff --git a/application/views/loginsiswa/index.php b/application/views/loginsiswa/index.php new file mode 100644 index 0000000..e0340d2 --- /dev/null +++ b/application/views/loginsiswa/index.php @@ -0,0 +1,49 @@ + + +
+
+
+
+
+
+
+

Login

+
+ +
+
+
+ + +
Oops, You missed this one
+
+
+ + +
Enter your password too!
+
+ + +
+
+ +
+
+
+
+
+
+ \ No newline at end of file