Hi All,
I failed to implemented setAutocomplete…
|
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 |
require_once '../jq-config.php'; $grid = new jqGridRender($conn); $table = 'LEMBUR'; $grid->SelectCommand ='SELECT a.LEMBURID, a.PERIODE, a.KARYAWANID, k.nama, a.JAMLEMBUR, a.JMLSPECIAL, a.JMLDINAS FROM LEMBUR a left join karyawan k on a.karyawanid = k.karyawanid left join divisi d on k.divisi = d.divisiid '; // set the ouput format to XML $grid->dataType = 'json'; // Let the grid create the model $grid->setPrimaryKeyId("LEMBURID"); $grid->setColModel(); $grid->table = $table; // set labels in the header $grid->setColProperty("LEMBURID", array("label"=>"ID", "hidden"=>true)); $grid->setColProperty("PRIODE", array("label"=>"Periode")); $grid->setColProperty("KARYAWANID", array("label"=>"KaryawanId")); $grid->setAutocomplete("NAMA","#KARYAWANID","SELECT NAMA, KARYAWANID FROM karyawan WHERE nama LIKE ? ORDER BY nama ",null, true, true); $grid->setColProperty("JAMLEMBUR", array("label"=>"Jam Lembur")); $grid->setColProperty("JMLSPECIAL", array("label"=>"Special Day")); $grid->setColProperty("JMLDINAS", array("label"=>"Dinas Luar")); $grid->setUrl('newEntryLembur_.php'); $grid->setGridOptions(array("rowNum"=>99999,"rowList"=>array(10,20,30),"sortname"=>"KARYAWANID", "width"=>"1000")); $grid->toolbarfilter = true; $grid->navigator = true; $grid->setNavOptions('navigator', array("excel"=>true,"add"=>true,"edit"=>true,"del"=>true,"view"=>true)); $grid->setFilterOptions(array("stringResult"=>true)); $grid->renderGrid('#grid','#pager',true, null, null, true,true); |
when start typing on column “NAMA”, 404:error. Status : error …
I’m using : jqGridAdoDB
Best Regards,
Copyright 2014 TriRand LtdAll Rights ReservedRSS
Back to Top