function f_transkripakademik(nimnya, titleyy) { var titley = 'Transkrip Akademik'; var datax; p = new Ext.Panel({ border: true, frame: true, style: 'margin-left: 70px;margin-bottom: 30px', width: 120, height: 135, html: '

PHOTO

' }); var hiddencari; if (nimnya==''){ hiddencari = false; }else{ hiddencari = true; } var ds_jabatan_dekan = new Ext.data.JsonStore({ proxy: new Ext.data.HttpProxy({ url: BASE_URL + 'data_controller/get_jabatan_dekan', method: 'POST' }), autoLoad: true, root: 'data', fields: [ { name: "idjabatan", mapping: "idjabatan" } , { name: "nmjabatan", mapping: "nmjabatan" } ] }); var ds_ttd_dekan = new Ext.data.JsonStore({ //from database id: 'id_ds_ttd_dekan', proxy: new Ext.data.HttpProxy({ url: BASE_URL + 'data_controller/get_tandatangan', method: 'POST' }), autoLoad: true, root: 'data', fields: [ { name: "idpimpinan", mapping: "idpimpinan" } , { name: "nmpimpinan", mapping: "nmpimpinan" } , { name: "jabatan", mapping: "jabatan" } ] }); var tplDetail = new Ext.XTemplate( '
', '', '', '', '
', '


Nim:
', '  {nim}
', 'Nama Mahasiswa:
', '  {nmmhs}
', 'Fakultas:
', '  {nmfakultas}
', 'Program Studi:
', '  {nmprodi}
', 'Tahun Masuk / Angkatan:
', '  {tahunmsk}
', 'Tahun Akademik / Semester:
', '  {kdthnakademik}
', //'Status Aktivitas Mahasiswa:
', //'  {nmstaktivitasmhs}
', '
', '
', '
'); //======================================= //datax = { // nim:'001' // } var p2 = new Ext.Panel({ listeners:{ afterrender:function(){ // tplDetail.overwrite(p2.body, datax); // p2.body.highlight('#c3daf9', {block:true}); } } }); var mhsDispPanel = new Ext.form.FormPanel({ id: 'fp.mhsFDisp', border: false, bodyStyle: 'padding:5px 5px 0', frame: true, labelAlign: 'top', layout: 'anchor', forceFit:true, items: [ { layout: 'form', defaultType: 'textfield', defaults: { readOnly: true }, items: [ p , { id: 'frm.nim', fieldLabel: 'NPM', width: 250, height:24 } , { id: 'frm.nama', fieldLabel: 'Nama Mahasiswa' ,width: 250, height:24} , { id: 'frm.fakultas', fieldLabel: 'Fakultas' ,width: 250, height:24} , { id: 'frm.prodi', fieldLabel: 'Program Studi' ,width: 250, height:24} , { id: 'frm.thmasuk', fieldLabel: 'Tahun Masuk' ,width: 250, height:24} , { id: 'frm.staktiv', fieldLabel: 'Status Aktivitas Mahasiswa' ,width: 250, height:24} , { id: 'frm.stawal', fieldLabel: 'Status Awal Mahasiswa' ,width: 250, height:24} , { id: 'frm.foto', hidden:true, fieldLabel: '' , validator: function(value){ mhs_foto_ori(Ext.getCmp("frm.foto").getValue()); },width: 250, height:24 } , { id: 'frm.kdprodi', fieldLabel: '' ,width: 250, height:24, hidden:true} , { id: 'frm.kdfakultas', fieldLabel: '' ,width: 250, height:24, hidden:true} , { id: 'frm.nimhide', fieldLabel: '' ,width: 250, height:24, hidden:true, validator: function(value){ var a = value; if (a) { //if (grid_nya.getStore().getCount() == 0) { ds_nya.setBaseParam('nim', a); ds_nya.setBaseParam('kdprodi', Ext.getCmp('frm.kdprodi').getValue()); ds_nya.setBaseParam('thnmasuk', Ext.getCmp('frm.thmasuk').getValue()); ds_nya.load({ scope : this, callback: function(records, operation, success) { var jumlahsksmutu = 0; var jumlahmutu=0; var jumlahsksall=0; var jumlahsksselect=0; var nh = ["A", "B", "C", "D", "E"]; ds_nya.each(function (rec) { if (nh.indexOf(rec.get('nilaihuruf').substr(0,1)) != -1) { jumlahsksall += parseFloat(rec.get('jmlsks')); jumlahsksselect += parseFloat(rec.get('jmlsks')); jumlahsksmutu += parseFloat(rec.get('sm')); jumlahmutu += parseFloat(rec.get('mutu')); } }); Ext.getCmp('jmlskskalimutu').setValue(jumlahsksmutu); Ext.getCmp('jmlsksall').setValue(jumlahsksall); var ipeka=0; ipeka = jumlahmutu/jumlahsksselect; Ext.getCmp('ipeka').setValue(ipeka.toFixed(2)); } }); Ext.Ajax.request({ url: BASE_URL + 'c_transkripakademik/form_mhs', method: 'POST', params: { userid: a }, success: function(response) { var r = Ext.decode(response.responseText); Ext.getCmp("nomor").setValue(r.noijazah); Ext.getCmp("tanggal").setValue(r.tglijazah); Ext.getCmp("tanggallulus").setValue(r.tgllulus); Ext.getCmp("rektor").setValue(r.idpimpinan1); Ext.getCmp("dekan").setValue(r.idpimpinan2); Ext.getCmp("frm.kdfakultas").setValue(r.kdfakultas); Ext.getCmp("judulskripsi").setValue((r.jdlskripsiind == '-') ? "-":atob(r.jdlskripsiind)); Ext.getCmp("frm.foto").setValue(r.foto); } }); //} Ext.getCmp('cb.jabatan_dekan').setValue(null); Ext.getCmp('cb.ttd_dekan').setValue(null); Ext.getCmp("cb.ttd_dekan").disable(); //Ext.getCmp('ttdpencetak').setValue(null); } } } ] }] }); //======================================= function renderbulat(value) { return parseInt(value); } var ds_nya = new Ext.data.JsonStore({ proxy: new Ext.data.HttpProxy({ url: BASE_URL + 'c_transkripakademik/grid_detail', method: 'POST' }), root: 'data', totalProperty: 'results', //autoLoad: true, fields: [{ name: "kdmk", mapping: "kdmk" }, { name: "nmmk", mapping: "nmmk" }, { name: "jmlsks", mapping: "jmlsks" }, { name: "nilaihuruf", mapping: "nilaihuruf" }, { name: "bobotnilai", mapping: "bobotnilai" }, { name: "mutu", mapping: "mutu" }, { name: "sm", mapping: "sm" }, { name: "dsnpengampu", mapping: "dsnpengampu" }], listeners: { load: function(store, records, options) { // Ext.getCmp('jmlsks2').setValue(store.getAt(0)); // alert(store.getAt(0).data['kdmk']); } } }); var sm_nya = new Ext.grid.CheckboxSelectionModel({ listeners: { selectionchange: function(sm) { } } }); var vw = new Ext.grid.GridView({ emptyText: '< No Data To Display >' }); var cm = new Ext.grid.ColumnModel({ // specify any defaults for each column defaults: { sortable: true // columns are not sortable by default }, columns: [//sm_nya, new Ext.grid.RowNumberer({width: 40}), { header: '
Kode Mata Kuliah
', width: 120, dataIndex: 'kdmk', sortable: true }, { header: '
Nama Mata Kuliah (Bahasa Indonesia)
', width: 360, dataIndex: 'nmmk', sortable: true }, { header: '
HM
', width: 40, dataIndex: 'nilaihuruf', sortable: true }, { header: '
AM
', width: 50, dataIndex: 'bobotnilai', renderer: renderbulat, sortable: true }, { header: '
sks
', width: 50, dataIndex: 'jmlsks', sortable: true }, { header: '
M
', width: 100, dataIndex: 'mutu', renderer: renderbulat, sortable: true }] }); var grid_nya = new Ext.grid.EditorGridPanel({ store: ds_nya, vw: vw, sm: sm_nya, cm: cm, autoScroll: true, columnLines: true, clicksToEdit: 1, loadMask: true, frame: true, height: 280, id: 'grid_det_nya', // tbar: [ // { // text: "Tahun Akademik" // }, // { // xtype: 'combo', // id: 'thnakademik', // name: 'thnakademik', // width:100, // store: ds_thnakademik, // triggerAction: 'all', // editable: false, // valueField: 'idthnakademik', // displayField: 'kdthnakademik', // forceSelection: true, // submitValue: true, // hiddenName: 'h_thakademik', // listeners: { // select: function(c, r, i) { // search_grid(); // } // }, // typeAhead: true, // mode: 'local', // emptyText: 'Belum Dipilih...', // selectOnFocus: true // },{ // text: "Semester" // }, // { // xtype: 'combo', // id: 'semester', // name: 'semester', // width:100, // store: ['Genap', 'Ganjil'], // triggerAction: 'all', // editable: false, // valueField: 'idjnssemester', // displayField: 'nmjnssemester', // forceSelection: true, // submitValue: true, // hiddenName: 'h_stsemester', // listeners: { // select: function(c, r, i) { // search_grid(); // // } // }, // typeAhead: true, // mode: 'local', // emptyText: 'Belum Dipilih...', // selectOnFocus: true // },{ // text: "Dosen Wali" // }, // { // xtype: 'textfield', // id:'dosenwali', // name:'dosenwali', // readOnly:true // } // ], listeners: { rowclick: function rowClick(grid, rowIdx) { // var rec = ds_nya.getAt(rowIdx); // KDMK= rec.data['kdmk']; // NIDU= rec.data['nidu']; } } }); var form_bp_general = new Ext.form.FormPanel({ id: 'form_bp_general', forceFit: true, //title: titley, tbar: [ { text: 'Cari', id: 'tb.find-mhs', iconCls: 'silk-find', hidden:hiddencari, handler: function() { wGridMhs('Transkrip'); } }, { text: 'Cetak', iconCls: 'silk-printer', handler: function() { if (grid_nya.getStore().getCount() == 0) { Ext.MessageBox.alert("Informasi", "Data Kosong"); } else { if (Ext.getCmp('cb.ttd_dekan').getValue()) { Ext.MessageBox.show({ title: "Konfirmasi", msg: "Cetak Transkrip Sementara?
" + "1. Jika Yes, maka mencetak Transkrip Sementara
" + "2. Jika No, maka mencetak Transkrip Keseluruhan", buttons: Ext.MessageBox.YESNO, fn: function(btn) { var ists = ""; var parsing = ''; var win; if (btn == 'yes') { ists = "1"; parsing = parsing + Ext.getCmp('frm.nim').getValue() + '/' ; parsing = parsing + Ext.getCmp('frm.kdprodi').getValue() + '/' ; parsing = parsing + Ext.getCmp('frm.thmasuk').getValue() + '/' ; parsing = parsing + Ext.getCmp('tgltranskrip').getValue().format('Y-m-d') + '/' ; parsing = parsing + Ext.getCmp('cb.jabatan_dekan').getValue() + '/' ; parsing = parsing + Ext.getCmp('cb.ttd_dekan').getValue() + '/' ; parsing = parsing + ists + '/' ; parsing = parsing + Ext.getCmp('ttdpencetak').getValue().replace(",","00").replace(".,","99"); if (Ext.getCmp('ttdpencetak').getValue()) { win = window.open(); win.location.reload(); win.location = BASE_URL + 'rpt/rpt_transkrip/get_transkrip/'+parsing; } else { Ext.MessageBox.alert("Informasi", "Silahkan Isi " + Ext.getCmp('ttdpencetak').fieldLabel); } } else if (btn == 'no') { ists = "0"; parsing = parsing + Ext.getCmp('frm.nim').getValue() + '/' ; parsing = parsing + Ext.getCmp('frm.kdprodi').getValue() + '/' ; parsing = parsing + Ext.getCmp('frm.thmasuk').getValue() + '/' ; parsing = parsing + Ext.getCmp('tgltranskrip').getValue().format('Y-m-d') + '/' ; parsing = parsing + Ext.getCmp('cb.jabatan_dekan').getValue() + '/' ; parsing = parsing + Ext.getCmp('cb.ttd_dekan').getValue() + '/' ; parsing = parsing + ists; win = window.open(); win.location.reload(); win.location = BASE_URL + 'rpt/rpt_transkrip/get_transkrip/'+parsing; } else { return; } } }); } else { Ext.MessageBox.alert("Informasi", "Silahkan Tentukan Penandatangan " + Ext.getCmp('cb.jabatan_dekan').getRawValue()); } } } },'->',{ text: 'Tanggal Cetak' },{ xtype: 'datefield', id: 'tgltranskrip', value: new Date(), width: 100 }], layout: 'column', reader: new Ext.data.JsonReader({ root: 'data', totalProperty: 'results', id: 'id', fields: [{ name: "nim", mapping: "nim" }, { name: "nmmhs", mapping: "nmmhs" }, { name: "nmfakultas", mapping: "nmfakultas" }, { name: "kdprodi", mapping: "kdprodi" }, { name: "nmprodi", mapping: "nmprodi" }, { name: "tahunmsk", mapping: "tahunmsk" }, //1 { name: "persen", mapping: "persen" }, { name: "stbayar", mapping: "stbayar" }, { name: "foto", mapping: "foto" }, { name: "idjnssemester", mapping: "idjnssemester"//kdstsemester }, { name: "kdstsemester", mapping: "kdstsemester" }, { name: "kdthnakademik", mapping: "kdthnakademik" }, { name: "nmstaktivitasmhs", mapping: "nmstaktivitasmhs" }] }),// items: [{ columnWidth: 1, xtype: 'panel', border: false, bodyStyle: 'padding:0px 0px 0px 3px', items: [{ layout: 'form', border: false, items: [{ xtype: 'fieldset', title: 'Daftar Mata Kuliah', //height: 530, // labelAlign: 'top', items: [grid_nya] }, { xtype: 'fieldset', items: [{ layout: 'column', border: false, items: [{ columnWidth: .35, layout: 'form', border: false, items: [{ xtype: 'textfield', style: 'text-align: right;', labelStyle: 'width:200px;', fieldLabel: 'Jumlah sks x Mutu', id: 'jmlskskalimutu', name: 'jmlskskalimutu', width: 50, allowBlank: false, readOnly: true, listeners: {} }, { xtype: 'textfield', style: 'text-align: right;', labelStyle: 'width:200px;', fieldLabel: 'Jumlah sks Yang di Tempuh', id: 'jmlsksall', width: 50, allowBlank: false, readOnly: true, listeners: {} }, { xtype: 'textfield', style: 'text-align: right;', labelStyle: 'width:200px;', fieldLabel: 'IPK', id: 'ipeka', width: 50, allowBlank: false, readOnly: true, listeners: {} }] },{ columnWidth: .65, layout: 'form', border: false, items: [{ store: ds_jabatan_dekan, xtype: 'combo', id: 'cb.jabatan_dekan', fieldLabel: 'Jabatan Dekan', triggerAction: 'all', labelStyle: 'width:200px;', valueField: 'idjabatan', displayField: 'nmjabatan', forceSelection: true, submitValue: true, mode: 'local', emptyText:'Pilih...', width: 150, editable: false, allowBlank: true, listeners:{ select: function(combo, record) { var kdfakultas = Ext.getCmp("frm.kdfakultas").getValue(); ds_ttd_dekan.setBaseParam('kdfakultas', kdfakultas); ds_ttd_dekan.setBaseParam('jabatan', record.data.idjabatan); Ext.getCmp("cb.ttd_dekan").disable(); Ext.getCmp("cb.ttd_dekan").setValue(null); ds_ttd_dekan.load({ scope : this, callback: function(records, operation, success) { Ext.getCmp("cb.ttd_dekan").enable(); } }); } } }, { xtype: 'combo', id: 'cb.ttd_dekan', fieldLabel: 'Penandatangan', store: ds_ttd_dekan, disabled: true, triggerAction: 'all', labelStyle: 'width:200px;', valueField: 'idpimpinan', displayField: 'nmpimpinan', forceSelection: true, submitValue: true, mode: 'local', emptyText:'Pilih...', width: 250, allowBlank: true }, { xtype: 'textfield', fieldLabel: 'Pencetak Transkrip', name: 'ttdpencetak', id: 'ttdpencetak', labelStyle: 'width:200px;', width: 250, }] }] }] }, { xtype: 'fieldset', title: '', items: [{ xtype: 'textfield', fieldLabel: 'Judul Skripsi', name: 'judulskripsi', id: 'judulskripsi', readOnly: true, anchor: '100%' }] }, { xtype: 'fieldset', title: '', defaults: { labelWidth: 120, labelAlign: 'right' }, items: [{ layout: 'column', border: false, items: [{ columnWidth: .38, layout: 'form', border: false, items: [{ xtype: 'textfield', fieldLabel: 'Nomor', name: 'nomor', id: 'nomor', anchor: '95%' },{ xtype: 'textfield', fieldLabel: 'Tanggal', id: 'tanggal', name: 'tanggal', anchor: '95%' },{ xtype: 'textfield', fieldLabel: 'Tanggal Kelulusan', id: 'tanggallulus', name: 'tanggallulus', anchor: '95%' }] }, { columnWidth: .62, layout: 'form', border: false, items: [{ xtype: 'textfield', fieldLabel: 'Rektor', id: 'rektor', name: 'rektor', anchor: '95%' },{ xtype: 'textfield', fieldLabel: 'Dekan', id: 'dekan', name: 'dekan', anchor: '95%' }] }] }] }, { xtype: 'fieldset', hidden:true, title: 'Perwalian Online', height:100, items: [ { xtype: 'compositefield', //fieldLabel: 'Dosen Wali', //labelStyle: 'width:160px', items: [{ xtype: 'textfield', id: 'nidu', anchor: '100%', readOnly: true//, //allowBlank: false },{ xtype: 'textfield', id: 'dosenwalicc', anchor: '100%', readOnly: true//, //allowBlank: false },{ xtype: 'button', text: 'Pesan', //hidden:true, // iconCls: 'silk-find', id: 'btn_data_submenu', width: 3, handler: function() { f_pesan(NIDUZ,Ext.getCmp('nim').getValue()); } }] } ] }] }] }], listeners: { } }); var akhir = new Ext.Panel({ layout: 'border', // autoLoad :true, defaults: { autoScroll:true, collapsible: true, split: true, bodyStyle: 'padding:15px' }, items: [{ collapsible: false, bodyStyle: 'padding:0px', region: 'center', id: 'images-view', frame: true, title: titley, items: [form_bp_general] }, { bodyStyle: 'padding:0px', collapsible: true, region: 'east', minSize: 75, title: 'Informasi Mahasiswa', frame: true, width: 300, height:495, //autoHeight: true, id: 'images-view2', items: [mhsDispPanel] }] }); SET_PAGE_CONTENT(akhir); /* function search_grid(){ ds_nya.setBaseParam('nmjnssemester', Ext.getCmp('semester').getRawValue()); ds_nya.setBaseParam('kdthnakademik', Ext.getCmp('thnakademik').getRawValue()); ds_nya.setBaseParam('nim', USERID); ds_nya.load({ scope : this, callback: function(records, operation, success) { var jumlahsksmutu = 0; var jumlahmutu=0; var jumlahsksall=0; ds_nya.each(function (rec) { jumlahsksmutu += parseFloat(rec.get('sm')); jumlahmutu += parseFloat(rec.get('mutu')); jumlahsksall += parseFloat(rec.get('jmlsks')); }); Ext.getCmp('jmlskskalimutu').setValue(jumlahsksmutu); Ext.getCmp('jmlsksall').setValue(jumlahsksall); var ipeka=0; ipeka = jumlahmutu/jumlahsksall; Ext.getCmp('ipeka').setValue(ipeka.toFixed(2)); } }); } */ }