<?php require_once MODDIR . 'fform/fform.php'; require_once MODDIR . 'control.php'; $opt = gpost('opt'); $cid = gpost('cid'); if ($cid == '') { $cid = 0; } appmod_use('aka/tahunajaran', 'aka/tingkat', 'aka/kelas'); $mtipe = gpost('mtipe'); if ($mtipe == '') { $mtipe = "1"; } // form Module $fmod = "siswakelas"; $fform = new fform($fmod, 'af', $cid, 'Cari siswa'); $fform->reg['title_af'] = '<idata>'; //$fform->reg['btnlabel_a_y']='Pilih yg ditandai'; $fform->reg['btnlabel_a_n'] = 'Tutup'; $fform->dimension(500); $fform->ptop = 50; $fform->head('Pilih Siswa', 0); echo '<tr><td><div id="data_member" style="height:350px;overflow:auto">'; if ($mtipe == "0" || $mtipe == "1") { require_once APPDIR . 'sirkulasi_member_get_siswa.php'; } echo '</div></td></tr>'; $fform->foot(0);
$r1=substr($r1['nama2'],0,3); $r['callnumber'].=" ".$r1; $jud=strtolower(substr($rk['judul'],0,1)); $r['callnumber'].=" ".$jud; $r['idbuku']=buku_makeid(); $r['barkode']=buku_makebarkode(); $r['urut']=buku_getlasturut()+1;; $r['tanggal']=date("Y-m-d"); $r['harga']=0; } $fform->dimension(450,120); $fform->ptop=20; $fform->head(); if($opt=='af' || $opt=='uf'){ require_once(MODDIR.'control.php'); // Add or Edit form $fform->fg('Data Koleksi'); $fform->fl('Judul','<b>'.buku_judul($rk['judul']).'</b>'); if($opt=='af'){ $fform->fi('Jumlah koleksi baru',iText('nbuku',1,'width:30px;text-align:center','','onblur="katalog_buku_getkode('.$cid.')"').' item'); hiddenval('tbarkode',$r['barkode']); hiddenval('tidbuku',$r['idbuku']); } else { hiddenval('nbuku',0); } $fform->fi('ID buku',iText('idbuku',$r['idbuku'],$fform->rwidths,'','','disabled')); //hiddenval('idbuku',$r['idbuku']);
$r['departemen'] = gpost('departemen'); $s = 'SELECT * FROM hrd_karyawan WHERE id=' . $r['pegawai'] . ' LIMIT 0,1'; // var_dump($s);exit(); $q = mysql_query($s); // $q=mysql_query("SELECT * FROM hrd_pegawai WHERE replid='".$r['pegawai']."' LIMIT 0,1"); if (mysql_num_rows($q) > 0) { $h = mysql_fetch_array($q); $r['nama'] = $h['nama']; } } else { // db operation for form : add $r = app_form_gpost('departemen', 'tahunajaran', 'pegawai', 'pelajaran', 'aktif', 'keterangan'); $r['pelajaran'] = gpost('spelajaran'); $r['aktif'] = '1'; } $fform->dimension(450); $fform->head(); if ($opt == 'af' || $opt == 'uf') { //$fform->fl('Departemen',departemen_name($r['departemen'])); //$fform->fl('Tahun ajaran',tahunajaran_name($r['tahunajaran'])); //$fform->fi('Status',iSelect('aktif',array('1'=>'Aktif','0'=>'Tidak aktif'),$r['aktif'])); //$fform->fa('Kode',iText('kode',$r['kode'],'width:40px')); require_once MODDIR . 'control.php'; // Add or Edit form $fform->fi('Mata Pelajaran', iSelect('pelajaran', pelajaran_opt(gpost('tahunajaran')), $r['pelajaran'])); $fform->fi('Pegawai', app_form_getpegawai('pegawai', $r)); $fform->fa('Keterangan', iTextarea('keterangan', $r['keterangan'], $fform->rwidths, 3)); hiddenval('aktif', 1); } else { if ($opt == 'df') { // Delete form
<?php require_once(MODDIR.'xform/xform.php'); require_once(MODDIR.'fform/fform.php'); require_once(MODDIR.'xtable/xtable.php'); require_once(MODDIR.'control.php'); $fmod="siswakelas"; $fform=new fform($fmod,'af',$cid,'Cari siswa'); $fform->globalkey='0'; $fform->reg['title_af']='<idata>'; $fform->reg['btnlabel_a_y']='Tutup'; //$fform->reg['btnlabel_a_n']='Tutup'; $fform->dimension(650); $fform->ptop=30; $fform->yes_act='close_fform()'; $fform->head('Daftar Pengecekan Item'); echo '<tr><td><div id="data_member" style="height:350px;overflow:auto">'; $tbl=stocktake_ctable(); $fmod='stocktake_daftar'; $xtable=new xtable($fmod,'item'); $xtable->noopt=true; $xtable->pageorder="cek,ts"; $xtable->search_box_pos('l'); $xtable->search_keyon('barkode=>'.$tbl.'.barkode:EQ-0'); // Query //$sql="SELECT * FROM ".$tbl." ORDER BY cek,ts"; $db=new xdb($tbl); $db->field($tbl.":*","josh.pus_katalog:judul"); $db->join("buku","josh.pus_buku"); $db->joinother("josh.pus_buku","katalog","josh.pus_katalog"); $db->where($xtable->search_sql_get()); $t=$db->query(); $xtable->ndata=mysql_num_rows($t);
if ($opt == 'd') { // delete $q = dbDel($dbtable, "replid='{$cid}'"); } } } $fform->notif($q); } else { $a = 0; if ($opt == 'uf' || $opt == 'df') { // Prepocessing form $r = dbSFA("*", $dbtable, "W/replid='{$cid}'"); $a = 0; } else { } $fform->dimension(400, 120); $fform->head(); if ($opt == 'af' || $opt == 'uf') { require_once MODDIR . 'control.php'; // Add or Edit form $fform->fi('Jumlah pembayaran', iTextC('nominal', $r['nominal'], 'width:120px')); $fform->fi('Besar cicilan', iTextC('cicilan', $r['cicilan'], 'width:120px')); $fform->fa('Keterangan perubahan', iTextarea('keterangan', $r['keterangan'], $fform->rwidths, 3)); } else { if ($opt == 'df') { // Delete form $fform->dlg_del($r['nama']); } } $fform->foot(); }
// delete $q = dbDel($dbtable, "replid='{$cid}'"); $q = dbDel("sar_peminjaman_barang", "peminjaman='{$cid}'"); } } } echo $cid; $fform->notif($q); } else { if ($opt == 'uf' || $opt == 'df') { // Prepocessing form $r = dbSFA("*", $dbtable, "W/replid='{$cid}'"); } else { $r = array(); } $fform->dimension(800); $fform->ptop = 10; $fform->title_style = 'background:#008aff;color:#fff;height:18px !important;padding:5px 10px 10px 10px !important;margin-bottom:5px'; $fform->head(); if ($opt == 'af' || $opt == 'uf') { echo '<tr><td>'; require_once APPDIR . 'sirkulasi_peminjaman_form.php'; echo '</td></tr>'; } else { if ($opt == 'df') { // Delete form $b = barang_get($r['barang']); $fform->dlg_del('[' . $b['kode'] . '] ' . $b['nama']); } } $fform->foot();
} } } $fform->notif($q); } else { if ($opt == 'uf' || $opt == 'df') { // Prepocessing form $r = dbSFA("*", $dbtable, "W/replid='{$cid}'"); } else { $r = farray('kode', 'nama', 'keterangan'); $r['kelompokbrg'] = gpost('kelompokbrg'); $r['tanggal'] = date("Y-m-d"); $r['unit'] = 1; $r['satuan'] = 'unit'; } $fform->dimension(400, 110); $fform->head(); if ($opt == 'af' || $opt == 'uf') { require_once MODDIR . 'control.php'; // Add or Edit form $fform->fl('Jenis barang', kelompokbrg_name($r['kelompokbrg'])); $fform->fi('Kode', iText('kode', $r['kode'], 'width:100px')); $fform->fi('Nama barang', iText('nama', $r['nama'], $fform->rwidths)); $fform->fi('Jumlah barang', iText('unit', $r['unit'], 'width:100px') . ' satuan: ' . iText('satuan', $r['satuan'], 'width:50px')); $fform->fi('Tanggal diperoleh', inputTanggal('tanggal', $r['tanggal'])); $fform->fa('Keterangan', iTextarea('keterangan', $r['keterangan'], $fform->rwidths, 3)); } else { if ($opt == 'df') { // Delete form $fform->dlg_del($r['nama']); }
$q &= dbDel("aka_siswa", "kelas='{$cid}'"); } } } //$fform->notif($q); } else { if ($opt == 'uf' || $opt == 'df') { // Prepocessing form $r = dbSFA("*", $dbtable, "W/replid='{$cid}'"); } else { $r = farray('kelas', 'tingkat', 'kapasitas', 'wali', 'keterangan'); $r['tahunajaran'] = gpost('tahunajaran'); $r['tingkat'] = gpost('tingkat'); $r['kapasitas'] = 1; } $fform->dimension(450, 100); $fform->head(); if ($opt == 'af' || $opt == 'uf') { require_once MODDIR . 'control.php'; // Add or Edit form $pelajaran = pelajaran_opt(gpost('tahunajaran')); $fform->fl('Kelas', kelas_name(gpost('sks_kelas'))); $fform->fi('Mata pelajaran', iSelect('pelajaran', $pelajaran, $r['kelas'])); $s = '<button title="Cari" class="btn" style="float:left" onclick="sks_guru_formlist()"><div class="bi_srcb"> </div></button>'; $fform->fi('Guru', iText('sguru', $r['sguru'], 'float:left;margin-right:4px;width:' . ($fform->rwidth - 40) . 'px', '', 'readonly', 'onclick="sks_guru_formlist()"') . $s); hiddenval('guru', $r['guru']); if ($opt == 'af') { $fform->fi('Jumlah jam', iText('njam', 1, 'width:40px;text-align:center')); $fform->fi('', '<div title="Cek opsi ini jika pengajar mata pelajaran untuk semua adalah sama." style="margin-top:10px">' . iCheckx('salin', 'Tambahkan juga ke semua kelas lainnya.', 0) . '</div>'); } else { hiddenval('njam', 1);
} } $fform->notif($q); } else { if ($opt == 'uf' || $opt == 'df') { // Prepocessing form $r = dbSFA("*", $dbtable, "W/replid='{$cid}'"); $jtrans = $r['jenis']; } else { $r = array('rekkas' => 0, 'budget' => 0); $r['tanggal'] = date("Y-m-d"); $jtrans = gpost('jenistransaksi', JT_UMUM); } if ($jtrans == JT_UMUM) { if ($opt != 'df') { $fform->dimension(500, 120); $fform->ptop = 50; } } else { if ($opt == 'af') { // af : add form $fform->dimension(760, 120); $fform->ptop = 50; } } //if($opt!='df') $fform->ptop=50; if ($opt != 'df') { if ($jtrans == JT_SISWA) { $fform->title_style = 'background:#00c804;color:#fff;height:18px !important;padding:5px 10px 10px 10px !important;margin-bottom:5px'; } if ($jtrans == JT_CALONSISWA) {
} $fform->notif($q); } else { if ($opt == 'uf' || $opt == 'df') { // Prepocessing form $r = dbSFA("*", $dbtable, "W/replid='{$cid}'"); } else { $r = farray('nis', 'nisn'); $r['departemen'] = gpost('departemen'); $r['tahunajaran'] = gpost('tahunajaran'); $r['kelas'] = gpost('kelas'); } $fform->reg['title_af'] = '<idata>'; $fform->reg['title_uf'] = 'Edit <idata>'; $fform->reg['title_df'] = 'Batalkan <idata>'; $fform->dimension(350); $fform->head(); if ($opt == 'af' || $opt == 'uf') { require_once MODDIR . 'control.php'; // Add or Edit form $pros = gpost('proses'); $tp = mysql_query("SELECT angkatan FROM psb_proses WHERE replid='{$pros}'"); $rp = mysql_fetch_array($tp); $fform->fl('Departemen', departemen_name($r['departemen'])); $fform->fl('Angkatan', angkatan_name($rp['angkatan'])); $fform->fl('Tahun ajaran', tahunajaran_name($r['tahunajaran'])); $fform->fl('Kelas', kelas_name($r['kelas'])); $fform->fi('No Induk', iText('nis', $r['nis'], 'width:120px')); $fform->fi('NISN', iText('nisn', $r['nisn'], $fform->rwidths)); } else { if ($opt == 'df') {
$keterangan = gpost('keterangan_' . $tgl); dbDel("aka_absen_guru", "guru='{$cid}' AND tanggal='{$tanggal}'"); $q = dbQSql("INSERT INTO aka_absen_guru SET absen='{$absen}',keterangan='{$keterangan}',guru='{$cid}',tanggal='{$tanggal}'"); //log_print("INSERT INTO aka_siswa_kelas SET kelas='$kls',siswa='$cid'"); } } } else { if ($opt == 'd') { // delete $kls = gpost('kelas'); $q = dbDel($dbtable, "guru='{$cid}' AND kelas='{$kls}'"); } else { if ($opt == 'af' || $opt == 'uf') { $fform = new fform($fmod, $opt, $cid, 'Data presensi guru'); $fform->reg['btnlabel_a_n'] = 'Batal'; $fform->dimension(600); $fform->ptop = 5; $fform->globalkey = '0'; $fform->reg['title_af'] = 'Edit <idata>'; $fform->head(); //$fform->fl('Departemen',departemen_name(gpost('departemen'))); //$fform->fl('Tingkat',tingkat_name(gpost('tingkat'))); //$fform->fl('Tahun ajaran',tahunajaran_name(gpost('tahunajaran'))); $fform->rheight = ''; if ($opt == 'af') { //$fform->fl('Kelas',kelas_name(gpost('kelas'))); $fform->fl('Tanggal', fftgl(gpost('tanggal'))); } else { $tanggal = gpost('tanggal'); $db = guru_db_byID($cid); $r = $db->gofetch();
if ($opt == 'd') { // delete $q = dbDel($dbtable, "replid='{$cid}'"); } } } //$fform->notif($q); } else { if ($opt == 'uf' || $opt == 'df') { // Prepocessing form $r = dbSFA("*", $dbtable, "W/replid='{$cid}'"); } else { $r = app_form_gpost('departemen', 'pelajaran'); $r['bobot'] = '1.0'; $r['keterangan'] = ''; } //$fform->ptop=50; $fform->dimension(400, 80); $fform->head(); if ($opt == 'af' || $opt == 'uf') { require_once MODDIR . 'control.php'; // Add or Edit form $fform->fa('Keterangan', iTextarea('komen', $r['komen'], $fform->rwidths, 3)); } else { if ($opt == 'df') { // Delete form $fform->dlg_del($r['nama']); } } $fform->foot(); }
// Prepocessing form $r = dbSFA("*", $dbtable, "W/replid='{$cid}'"); } else { $r = array(); $r['nama'] = gpost('snama'); $r['kategori'] = gpost('kategori'); $r['rek1'] = '-'; $r['rek2'] = '-'; $r['rek3'] = '-'; $r['nominal'] = 0; $r['cicilan'] = 0; $r['reftipe'] = gpost('reftipe'); $r['refid'] = gpost('refid'); } $rekening = rekening_opt(); $fform->dimension(440, 140); if ($opt != 'df') { $fform->ptop = 20; } $fform->head(); if ($opt == 'af' || $opt == 'uf') { require_once MODDIR . 'control.php'; // Add or Edit form hiddenval('mod_reftipe', $r['reftipe']); hiddenval('mod_refid', $r['refid']); $fform->fl('Kategori pembayaran', kategori_name($r['kategori'])); if ($r['reftipe'] == RT_SPP) { $fform->fl('Nama pembayaran', $r['nama']); hiddenval('nama', $r['nama']); $fform->fi('Rek. kas', iSelect('rek1', $rekening, $r['rek1'], $fform->rwidths)); $fform->fi('Rek. pendapatan', iSelect('rek2', $rekening, $r['rek2'], $fform->rwidths));
// delete $q = dbDel($dbtable, "replid='{$cid}'"); } } } $fform->notif($q); } else { if ($opt == 'uf' || $opt == 'df') { // Prepocessing form $r = dbSFA("*", $dbtable, "W/replid='{$cid}'"); } else { $r = app_form_gpost('departemen', 'pelajaran'); $r['bobot'] = '1.0'; $r['kkm'] = 70; } $fform->dimension(300, 250); $fform->ptop = 20; $fform->head(); if ($opt == 'af' || $opt == 'uf') { require_once MODDIR . 'control.php'; // Add or Edit form echo '<tr><td colspan="2"><div style="background:#fafafa;border:1px solid #d2d2d2;padding:5px;margin-bottom:10px;text-align:justify;line-height:130%"><p><b>Tips:</b></p><p>Untuk memperoleh nilai akhir sama dengan nilai rata-rata set semua penilaian dengan bobot yang sama.</p><p>Set bobot penilaian menjadi 0 jika penilaian tersebut tidak masuk dalam perhitungan nilai rapor.</p></div></td></tr>'; $allid = ''; $t1 = dbSel("*", "aka_penilaian", "W/guru='{$gid}' AND pelajaran='{$pel}' AND kelas='{$kls}'"); while ($r1 = dbFA($t1)) { $fform->fi($r1['nama'] . ' (' . $r1['kode'] . ')', iText('bobot_' . $r1['replid'], $r1['bobot'], 'width:50px;text-align:center')); str_append($allid, $r1['replid']); } hiddenval('allid', $allid); } else { if ($opt == 'df') {
} } } $fform->notif($q); } else { if ($opt == 'uf' || $opt == 'df') { // Prepocessing form $r = dbSFA("*", $dbtable, "W/replid='{$cid}'"); $r['departemen'] = gpost('departemen'); } else { $r = app_form_gpost('departemen', 'semester', 'tingkat', 'pelajaran'); } if ($opt == 'af' || $opt == 'uf') { require_once MODDIR . 'control.php'; // Add or Edit form $fform->dimension(700, 100, 20); $fform->head(); /*$fform->rheight='24px'; $fform->fl('Departemen',departemen_name($r)); $fform->fl('Semester',semester_name($r)); $fform->fl('Tingkat',tingkat_name($r)); $fform->fl('Pelajaran',pelajaran_name($r['pelajaran'])); $fform->rheight='30px';*/ $fform->fi('Unit', iText('unit', $r['unit'], $fform->rwidths)); //$fform->fa('Standar',iTextArea('standar',$r,$fform->rwidths,3)); //$fform->fa('Standar',iTexteditLite('standar',$r,$fform->rwidth.'px',5)); //$fform->fa('Obyektif',iTexteditLite('tujuan',$r,$fform->rwidth.'px',5)); //$fform->fa('Obyektif',iTextArea('tujuan',$r,$fform->rwidths,5)); //$fform->fi('Kode',iText('kode',$r,'width:150px')); echo '<tr><td colspan="2">'; echo iTextedit('deskripsi', $r['deskripsi'], $fform->fwidth - 8 . 'px', 25);
} else { if ($opt == 'd') { // delete $q = dbDel($dbtable, "replid='{$cid}'"); } } } $fform->notif($q); } else { if ($opt == 'uf' || $opt == 'df') { // Prepocessing form $r = dbSFA("*", $dbtable, "W/replid='{$cid}'"); } else { $r['departemen'] = $inp['departemen']; } $fform->dimension(400, 100); $fform->head(); if ($opt == 'af' || $opt == 'uf') { require_once MODDIR . 'control.php'; // Add or Edit form $fform->fl('Departemen', departemen_name($r['departemen'])); $fform->fi('Tahun kelulusan', iText('nama', $r['nama'], $fform->rwidths)); //$fform->fa('Keterangan',iTextarea('keterangan',$r['keterangan'],$fform->rwidths,3)); } else { if ($opt == 'df') { // Delete form $fform->dlg_del($r[$fmod]); } } $fform->foot(); }