Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
simas-blitar
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
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
Deddy Vita Kurniawan
simas-blitar
Commits
523f401e
Commit
523f401e
authored
Aug 16, 2024
by
Deddy Vita Kurniawan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
* tampilan dashboard
parent
65adc9f3
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
42 additions
and
0 deletions
+42
-0
home.php
application/controllers/home.php
+1
-0
format_helper.php
application/helpers/format_helper.php
+15
-0
home_model.php
application/models/home_model.php
+26
-0
v_home.php
application/views/v_home.php
+0
-0
No files found.
application/controllers/home.php
View file @
523f401e
...
...
@@ -29,6 +29,7 @@ class Home extends Userpage_Controller
$data
[
'jml_tidak'
]
=
$this
->
home_model
->
jumlah_tidak
();
$data
[
'jml_belum'
]
=
$this
->
home_model
->
jumlah_belum
();
$data
[
'jml_sesuai'
]
=
$this
->
home_model
->
jumlah_sesuai
();
$data
[
'data'
]
=
$this
->
home_model
->
perhitungan_data
();
$data
[
'title'
]
=
get_title
();
$data
[
'main_content'
]
=
'v_home'
;
//$data['unit'] = $unit;
...
...
application/helpers/format_helper.php
View file @
523f401e
...
...
@@ -225,6 +225,21 @@ if ( ! function_exists('format_rupiah'))
}
}
if
(
!
function_exists
(
'format_numeric'
))
{
function
format_numeric
(
$value
)
{
if
(
$value
<
0
)
{
return
'( '
.
number_format
(
abs
(
$value
),
0
,
','
,
'.'
)
.
' )'
;
}
else
{
return
' '
.
number_format
(
$value
,
0
,
','
,
'.'
)
.
' '
;
}
}
}
if
(
!
function_exists
(
'prepare_numeric'
))
{
function
prepare_numeric
(
$value
,
$default
=
null
)
...
...
application/models/home_model.php
View file @
523f401e
...
...
@@ -141,4 +141,30 @@ class Home_model extends CI_Model
$jumlah
=
$this
->
db
->
get
();
return
$jumlah
->
num_rows
();
}
function
perhitungan_data
()
{
$this
->
db
->
select
(
"
count(a.id_surat) st_terbit,
count(if(b.kode = 'Ad',1,NULL)) audit,
count(if(b.kode = 'A',1,NULL)) pdtt,
count(if(b.kode = 'M',1,NULL)) monev,
count(if(b.kode = 'E',1,NULL)) evaluasi,
count(if(b.kode = 'F',1,NULL)) verifikasi,
count(if(b.kode = 'V',1,NULL)) review,
count(if(b.kode = 'D',1,NULL)) pendampingan,
count(if(b.kode = 'G',1,NULL)) penilaian,
count(if(b.kode = 'Mo',1,NULL)) monitoring,
count(if(b.kode = 'G',1,NULL)) penilaian,
count(if(b.kode = 'Y',1,NULL)) penyusunan,
count(if(b.kode = 'P',1,NULL)) persiapan,
count(if(b.kode = 'S',1,NULL)) pemeriksaan_mendadak,
count(if(b.kode = 'Kj',1,NULL)) kinerja
"
,
FALSE
);
$this
->
db
->
from
(
'surat_penugasan a'
);
$this
->
db
->
join
(
'ref_jns_pemeriksaan b'
,
'b.id_jns=a.id_jns_pemeriksaan'
,
'left'
);
$this
->
db
->
where
(
'a.tahun'
,
$this
->
tahun
);
$result
=
$this
->
db
->
get
()
->
row_array
();
return
$result
;
}
}
application/views/v_home.php
View file @
523f401e
This diff is collapsed.
Click to expand it.
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